akeneo / pim-community-dev

[Community Development Repository] The open source Product Information Management (PIM)
http://www.akeneo.com
Other
949 stars 512 forks source link

Job names on different connectors are unique #3326

Closed linslin closed 7 years ago

linslin commented 8 years ago

While configure a job in "batch_jobs.yml", a error comes up. Job names are unique. In that way you can override other jobs by default, example:

Connector1:
   jobs:
        my_sweet_export:
Connector2:
   jobs:
     my_sweet_export:

So, while creating a new export or Import job by choosing Connector2 - my_sweet_export it will create a job based on Connector1 - my_sweet_export.

phaseinducer commented 8 years ago

Hi linslin,

This bug has been reported internally, thanks for your feedback ! In the meantime I suggest that you give different names to your jobs if you don't want this overriding behavior.

Kind regards, Yohan

nidup commented 7 years ago

Hi @linslin

You should not encounter anymore this issue in the upcoming 1.6.0, we re-worked the JobRegistry and it now raises an exception if the job name is already defined https://github.com/akeneo/pim-community-dev/blob/master/src/Akeneo/Component/Batch/Job/JobRegistry.php#L33

Have a good day,