Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add priority to DataMapper, Merger and NormalizeEnhancer service definitions #108

Merged

Conversation

niklasnatter
Copy link
Contributor

This makes it possible to influence the position of a custom DataMapper/Merger/NormalizeEnhancer

@@ -8,18 +8,18 @@
<argument type="service" id="sulu_page.structure.factory"/>
<argument>%sulu.content.structure.default_types%</argument>

<tag name="sulu_content.data_mapper"/>
<tag name="sulu_content.data_mapper" priority="3072"/>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand the usage of this high numbers.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i dont care about the specific numbers, just used the same pattern that sulu uses 🙂 what would you use?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should follow the rule what symfony does they have internal priorites only between -255 to 255.

Would go in this case with:

Template: 128
Workflow: 64
Excerpt: 32
Seo: 16
Routeable: -32

@alexander-schranz alexander-schranz added the DX Only affecting the end developer label Mar 8, 2020
@niklasnatter niklasnatter force-pushed the enhancement/service-priorities branch from 1649d5f to 93f2631 Compare March 10, 2020 12:33
@alexander-schranz alexander-schranz merged commit 322cee2 into sulu:master Mar 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DX Only affecting the end developer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants