Merge branch 'cassandra-4.0' into cassandra-4.1

This commit is contained in:
Stefan Miklosovic 2024-08-05 12:16:01 +02:00
commit aa7afeabce
No known key found for this signature in database
GPG Key ID: 32F35CB2F546D93E
3 changed files with 11 additions and 3 deletions

View File

@ -6,6 +6,7 @@
* Reduce info logging from automatic paxos repair (CASSANDRA-19445)
* Support legacy plain_text_auth section in credentials file removed unintentionally (CASSANDRA-19498)
Merged from 4.0:
* Do not spam log with SSLExceptions (CASSANDRA-18839)
* Fix schema.cql created by a snapshot after dropping more than one column (CASSANDRA-19747)
* UnsupportedOperationException when reducing scope for LCS compactions (CASSANDRA-19704)
* Make LWT conditions behavior on frozen and non-frozen columns consistent for null column values (CASSANDRA-19637)

View File

@ -23,6 +23,8 @@ import java.net.SocketAddress;
import java.util.Set;
import java.util.concurrent.TimeUnit;
import javax.net.ssl.SSLException;
import com.google.common.base.Predicate;
import com.google.common.collect.ImmutableSet;
@ -100,7 +102,7 @@ public class ExceptionHandlers
logger.debug("Excluding client exception for {}; address contained in client_error_reporting_exclusions", ctx.channel().remoteAddress(), cause);
return;
}
logClientNetworkingExceptions(cause);
logClientNetworkingExceptions(cause, ctx.channel().remoteAddress());
}
private static boolean isFatal(Throwable cause)
@ -110,7 +112,7 @@ public class ExceptionHandlers
}
}
static void logClientNetworkingExceptions(Throwable cause)
static void logClientNetworkingExceptions(Throwable cause, SocketAddress clientAddress)
{
if (Throwables.anyCauseMatches(cause, t -> t instanceof ProtocolException))
{
@ -133,6 +135,10 @@ public class ExceptionHandlers
ClientMetrics.instance.markUnknownException();
logger.trace("Native exception in client networking", cause);
}
else if (Throwables.anyCauseMatches(cause, t -> t instanceof SSLException))
{
NoSpamLogger.log(logger, NoSpamLogger.Level.WARN, 1, TimeUnit.MINUTES, "SSLException in client networking with peer {} {}", clientAddress, cause.getMessage());
}
else
{
ClientMetrics.instance.markUnknownException();

View File

@ -366,7 +366,8 @@ public class PreV5Handlers
logger.debug("Excluding client exception for {}; address contained in client_error_reporting_exclusions", ctx.channel().remoteAddress(), cause);
return;
}
ExceptionHandlers.logClientNetworkingExceptions(cause);
ExceptionHandlers.logClientNetworkingExceptions(cause, ctx.channel().remoteAddress());
JVMStabilityInspector.inspectThrowable(cause);
}