Skip to content

Commit

Permalink
[Java] Warnings cleanup.
Browse files Browse the repository at this point in the history
  • Loading branch information
mjpt777 committed Dec 29, 2021
1 parent 21b280b commit 746e20e
Show file tree
Hide file tree
Showing 22 changed files with 40 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@
*/
public class ArchiveEvent extends AeronEvent
{
private static final long serialVersionUID = 6814756736866124884L;

/**
* Archive event with provided message and {@link io.aeron.exceptions.AeronException.Category#WARN}.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ public class ArchiveException extends AeronException
*/
public static final int UNAUTHORISED_ACTION = 13;

private static final long serialVersionUID = 386758252787901080L;

private final int errorCode;
private final long correlationId;

Expand Down
1 change: 1 addition & 0 deletions aeron-client/src/main/java/io/aeron/Aeron.java
Original file line number Diff line number Diff line change
Expand Up @@ -1576,6 +1576,7 @@ private void connectToDriver()
}
}

@SuppressWarnings("try")
private static MappedByteBuffer waitForFileMapping(final File file, final EpochClock clock, final long deadlineMs)
{
while (true)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
public class AeronEvent extends AeronException
{
private static final StackTraceElement[] EMPTY_STACK = new StackTraceElement[0];
private static final long serialVersionUID = 2520658673245952222L;

/**
* Aeron event with provided message and {@link AeronException.Category#WARN}.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
*/
public class AeronException extends RuntimeException
{
private static final long serialVersionUID = -8399166154162189622L;

/**
* Category of {@link Exception}.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
*/
public class ChannelEndpointException extends AeronException
{
private static final long serialVersionUID = 6810249167217382358L;

/**
* Counter id for the status indicator of the channel.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
*/
public class ClientTimeoutException extends TimeoutException
{
private static final long serialVersionUID = 4085394356371474876L;

/**
* Construct the client timeout exception with detail message.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,5 @@
*/
public class ConcurrentConcludeException extends AeronException
{
private static final long serialVersionUID = 684839776662091577L;
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
*/
public class ConductorServiceTimeoutException extends TimeoutException
{
private static final long serialVersionUID = 4289404220974757441L;

/**
* Construct the exception for the service interval timeout with detailed message.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
*/
public class ConfigurationException extends AeronException
{
private static final long serialVersionUID = 2545086690221965112L;

/**
* Construct an exception with detail for the configuration error.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
*/
public class ControlProtocolException extends AeronException
{
private static final long serialVersionUID = -6491010363479568113L;

/**
* The {@link ErrorCode} indicating more specific issue experienced by the media driver.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
*/
public class DriverTimeoutException extends TimeoutException
{
private static final long serialVersionUID = -334819963402642904L;

/**
* Construct the exception for driver timeout due to lack of heartbeat.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
*/
public class RegistrationException extends AeronException
{
private static final long serialVersionUID = 9076689715024983035L;

/**
* The correlation id of the command to register the resource action.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
*/
public class TimeoutException extends AeronException
{
private static final long serialVersionUID = 339608646881678251L;

/**
* Default timeout exception as {@link AeronException.Category#ERROR}.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ public static boolean unblock(
{
case UNBLOCKED_TO_END:
rotateLog(logMetaDataBuffer, blockedTermCount, termId);
// fall through
return true;

case UNBLOCKED:
return true;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
*/
public class AuthenticationException extends AeronException
{
private static final long serialVersionUID = -3205449285259494699L;

/**
* Default exception as {@link io.aeron.exceptions.AeronException.Category#ERROR}.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@
*/
public class ClusterEvent extends AeronEvent
{
private static final long serialVersionUID = -3787117048989508866L;

/**
* Cluster event with provided message and {@link io.aeron.exceptions.AeronException.Category#WARN}.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
*/
public class ClusterException extends AeronException
{
private static final long serialVersionUID = -2688245045186545277L;

/**
* Default Cluster exception as {@link io.aeron.exceptions.AeronException.Category#ERROR}.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@
*/
public class ClusterTerminationException extends AgentTerminationException
{
private static final long serialVersionUID = -2705156056823180407L;
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
*/
public class ActiveDriverException extends AeronException
{
private static final long serialVersionUID = 2539364003811295552L;

/**
* Exception with provided message and {@link io.aeron.exceptions.AeronException.Category#ERROR}.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
*/
public class InvalidChannelException extends ControlProtocolException
{
private static final long serialVersionUID = 8395688431913848255L;

/**
* Exception with provided message and {@link io.aeron.exceptions.AeronException.Category#ERROR} and
* {@link ErrorCode#INVALID_CHANNEL}.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
*/
public class UnknownSubscriptionException extends AeronException
{
private static final long serialVersionUID = 8934006869519172332L;

/**
* Exception with provided message and {@link io.aeron.exceptions.AeronException.Category#ERROR}.
*
Expand Down

0 comments on commit 746e20e

Please sign in to comment.