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

CASSANDRA-19158 #3288

Open
wants to merge 6 commits into
base: trunk
Choose a base branch
from
Open

CASSANDRA-19158 #3288

wants to merge 6 commits into from

Conversation

ifesdjeen
Copy link
Contributor

No description provided.

Copy link
Contributor

@beobal beobal left a comment

Choose a reason for hiding this comment

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

LGTM, just a handful of minor comments. There are some test failures in relevant places too that we should investigate.

}
else
{
throw new IllegalStateException(String.format("Queried for epoch %s, but could not catch up", awaitAtleast));
Copy link
Contributor

Choose a reason for hiding this comment

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

do we want to throw here, or let the caller decide how to handle a failure to catch up? In some cases, this is purely a background task, so perhaps we should log but allow the caller to proceed? (I know we are certain that remote should be able to satisfy the request as we call this in response to seeing awaitAtLeast in some message from it).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Right now, we will log this (rare) exception, which ji think is a reasonable behaviour.

On the other hand, if we have a listener, it will have to deal with exception one way or the other: this seems ok, too.

Copy link
Contributor

Choose a reason for hiding this comment

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

ok, seems reasonable

return fetchLogAndWaitInternal(remoteRequest, candidateIterator, log);
try
{
return fetchLogAndWaitInternal(candidateIterator, log).awaitUninterruptibly().get();
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we awaitThrowUncheckedOnInterrupt, or even just await here? I'm thinking of tests really where the origin implementation (before CASSANDRA-19514) could cause occasional timeouts.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Do you mean await with a timeout, or without? My logic for doing it this way was that we will rely on messaging service timeouts now to time this one out, so it should never be indefinite.

Copy link
Contributor

Choose a reason for hiding this comment

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

fair enough, I was concerned about in-flight requests preventing a timely shutdown, but this will now be bounded by new Retry.Backoff(TCMMetrics.instance.fetchLogRetries));, right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants