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

SMS: avoid copy in OnNextAsync if user has specified immutable data optimization #3058

Merged
merged 1 commit into from
May 26, 2017

Conversation

ReubenBond
Copy link
Member

Fixes a minor test breakage introduced in #3048.

A test was relying on data not being copied if the optimization for immutable data was set. In reality this isn't an issue, since we don't guarantee consumers and producers are on the same silo, but the fix is trivial. I didn't realize previously that this field was available, my mistake.

{
// In order to avoid potential concurrency errors, synchronously copy the input before yielding the
// thread. DeliverItem below must also be take care to avoid yielding before copying for non-immutable objects.
item = (T) this.serializationManager.DeepCopy(item);
Copy link
Contributor

Choose a reason for hiding this comment

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

@jason-bragg you are correct after all. 💃

@jdom
Copy link
Member

jdom commented May 26, 2017

@jason-bragg please review asap so this goes in, since the current code is failing a test in most of our unrelated PRs

@jason-bragg jason-bragg merged commit c0b56b9 into dotnet:master May 26, 2017
@ReubenBond ReubenBond deleted the fix-sms-fix branch May 27, 2017 01:49
sergeybykov pushed a commit to sergeybykov/orleans that referenced this pull request May 31, 2017
jdom pushed a commit that referenced this pull request May 31, 2017
@github-actions github-actions bot locked and limited conversation to collaborators Dec 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants