Skip to content

Commit

Permalink
[Java] Provide error message in the absence of sessionMessageListener
Browse files Browse the repository at this point in the history
  • Loading branch information
JPWatson committed Jun 22, 2018
1 parent 66268a5 commit d79759c
Showing 1 changed file with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -837,6 +837,16 @@ public void conclude()
{
credentialsSupplier = new NullCredentialsSupplier();
}

if (null == sessionMessageListener)
{
sessionMessageListener =
(correlationId, clusterSessionId, timestamp, buffer, offset, length, header) ->
{
throw new IllegalStateException(
"sessionMessageListener must be specified on AeronCluster.Context");
};
}
}

/**
Expand Down

0 comments on commit d79759c

Please sign in to comment.