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

Nonoptimal database query #1302

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

thefrozenfruit
Copy link

Describe the change
#1169

.ThenInclude(ep => ep.ExtensionAttributes)
.Include(wf => wf.ExecutionPointers)
.AsSplitQuery()
.FirstAsync(x => x.InstanceId == uid, cancellationToken);

Choose a reason for hiding this comment

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

Suggested change
.FirstAsync(x => x.InstanceId == uid, cancellationToken);
.FirstOrDefaultAsync(x => x.InstanceId == uid, cancellationToken);

because it seems you're checking for raw being not null

@@ -32,7 +32,7 @@ public async Task<string> CreateEventSubscription(EventSubscription subscription
{
subscription.Id = Guid.NewGuid().ToString();
var persistable = subscription.ToPersistable();
var result = db.Set<PersistedSubscription>().Add(persistable);
_ = db.Set<PersistedSubscription>().Add(persistable);
Copy link
Owner

Choose a reason for hiding this comment

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

Could we put non-related changes in their own PR?

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