- last update
about 1 year ago Custom Commands Failed - @achap opened merge request.
- last update
about 1 year ago Custom Commands Failed - last update
about 1 year ago 29,959 pass - achap π¦πΊ
While this approach allows migrations to run concurrently the status becomes useless because the value is stored in key value storage with the id of the migration as the key. So even if you instantiated a migration for each individual item the status would just keep being overridden and not be very helpful. I wonder if there is a way to have a uuid for each instance returned by createInstance?
In the
Migration
plugin class these two methods use the plugin id:/** * {@inheritdoc} */ public function setStatus($status) { \Drupal::keyValue('migrate_status')->set($this->id(), $status); } /** * {@inheritdoc} */ public function getStatus() { return \Drupal::keyValue('migrate_status')->get($this->id(), static::STATUS_IDLE); }
- Status changed to Closed: works as designed
about 1 year ago 7:12am 17 August 2023 - achap π¦πΊ
So I quickly realized that this wasn't going to work/be very difficult and the way I was going about it was sending me down a rabbit hole. Stepping back... I realized that I can achieve the same result by using the deriver key in my migration and then passing the product ids I need to generate migration plugins for using the MemoryCache service. That way, each product id has a migration plugin created for it which can be added to a queue. The queue can then process migrations concurrently!
- achap π¦πΊ
Discovered another issue with the derivative approach. It creates a mapping table for each derivative migration, so I think that also won't work as I will have thousands of new tables...