Skip to content

Make MEDI implemention registrations idempotent - #134

Open
JMolenkamp wants to merge 1 commit into
autofac:developfrom
JMolenkamp:change-idempotent-medi-registrations
Open

JMolenkamp wants to merge 1 commit into
autofac:developfrom
JMolenkamp:change-idempotent-medi-registrations

Conversation

@JMolenkamp

Copy link
Copy Markdown

Proposed Changes

  • Make MEDI implementation registrations in AutofacRegistration.Populate calls idempotent. Allowing for multiple calls to Populate without duplicating registrations and callback.

@tillig

tillig commented Sep 9, 2026

Copy link
Copy Markdown
Member

Is this a problem you've run into that you're trying to solve? The PR explains what was changed, but the why is more important. This package has been out for years and we've had no issue reports about this; and adding it now is a potential breaking behavior change.

@JMolenkamp

Copy link
Copy Markdown
Author

No, it's more of a correctness thing that I stumbled upon. I can't really see how this would become a breaking change, but obviously I can't foresee every usage.

@tillig

tillig commented Sep 10, 2026

Copy link
Copy Markdown
Member

I see what you're saying, and I think you're generally right. I can just never be sure what stuff people start counting on, even if it seems like it's not something to be counted on. One person's 0.0.1 bug fix is another's 1.0.0 "why did you break my app?" behavior change sometimes. Let me think about it a bit. I lean toward the correctness side, just want to be cautious about "if it ain't broke, don't fix it."

@JMolenkamp

Copy link
Copy Markdown
Author

Understandable, easy for me to say from where I'm standing.

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.

2 participants