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

[Cookbook][Security] usage of a non-default entity manager in an entity user provider #4023

Merged
merged 1 commit into from
Aug 4, 2014

Conversation

xabbuh
Copy link
Member

@xabbuh xabbuh commented Jul 14, 2014

Q A
Doc fix? yes
New docs? no
Applies to all
Fixed tickets #4021

The cookbook on entity user providers for the Security component only
describes how to create an entity provider using the default entity
manager. This may not be sufficient enough if you have multiple entity
managers and therefore be eplicit with the entity manager to use in
the user provider.

@xabbuh xabbuh changed the title usage of a non-default entity manager in an entity user provider [Cookbook][Security] usage of a non-default entity manager in an entity user provider Jul 20, 2014
user information from the database. If you, for example,
:doc:`use multiple entity managers </cookbook/doctrine/multiple_entity_managers>`,
you may have to specify the manager that should be used by the entity
provider. Use the ``manager_name`` option to achieve this:
Copy link
Member

Choose a reason for hiding this comment

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

Love this note! Do you think we can shorten it a little?

If you use multiple entity managers, you can specify which manager
to use with the manager_name option:

What do you think?

Copy link
Member Author

Choose a reason for hiding this comment

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

I would like to keep the reference to the multiple entity managers chapter:

If you use multiple entity managers (for example when using
:doc:`use multiple entity managers </cookbook/doctrine/multiple_entity_managers>`),
you can specify which manager
to use with the manager_name option:

What do you think?

Copy link
Member

Choose a reason for hiding this comment

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

how about this compromise :)

If you :doc:`use multiple entity managers </cookbook/doctrine/multiple_entity_managers>`,
you can specify which manager to use with the manager_name option:

Copy link
Member Author

Choose a reason for hiding this comment

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

I like it. It's updated.

@wouterj
Copy link
Member

wouterj commented Jul 31, 2014

@xabbuh this needs a rebase

The cookbook on entity user providers for the Security component only
describes how to create an entity provider using the default entity
manager. This may not be sufficient enough if you have multiple entity
managers and therefore be eplicit with the entity manager to use in
the user provider.
@xabbuh
Copy link
Member Author

xabbuh commented Jul 31, 2014

Done.

@weaverryan
Copy link
Member

Love it! Thanks!

@weaverryan weaverryan merged commit 9eb9117 into symfony:2.3 Aug 4, 2014
weaverryan added a commit that referenced this pull request Aug 4, 2014
…r in an entity user provider (xabbuh)

This PR was merged into the 2.3 branch.

Discussion
----------

[Cookbook][Security] usage of a non-default entity manager in an entity user provider

| Q             | A
| ------------- | ---
| Doc fix?      | yes
| New docs?     | no
| Applies to    | all
| Fixed tickets | #4021

The cookbook on entity user providers for the Security component only
describes how to create an entity provider using the default entity
manager. This may not be sufficient enough if you have multiple entity
managers and therefore be eplicit with the entity manager to use in
the user provider.

Commits
-------

9eb9117 usage of a non-default entity manager in an entity user provider
@xabbuh xabbuh deleted the issue-4021 branch August 7, 2014 07:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants