dcapwell commented on code in PR #38:
URL: https://github.com/apache/cassandra-accord/pull/38#discussion_r1154812681
##########
accord-core/src/main/java/accord/topology/TopologyManager.java:
##########
@@ -399,7 +399,10 @@ public boolean hasEpoch(long epoch)
public Topology localForEpoch(long epoch)
{
- return epochs.get(epoch).local();
+ EpochState epochState = epochs.get(epoch);
+ if (epochState == null)
+ throw new IllegalStateException("Unknown epoch " + epoch);
+ return epochState.local();
Review Comment:
here is the exception I am changing this to add more details
```
java.lang.NullPointerException
at
accord.topology.TopologyManager.localForEpoch(TopologyManager.java:402)
at accord.local.Node.trySelectProgressKey(Node.java:467)
at accord.messages.TxnRequest.progressKey(TxnRequest.java:151)
at accord.messages.TxnRequest.process(TxnRequest.java:143)
at
org.apache.cassandra.service.accord.AccordVerbHandler.doVerb(AccordVerbHandler.java:46)
at
org.apache.cassandra.net.InboundSink.lambda$new$0(InboundSink.java:78)
at org.apache.cassandra.net.InboundSink.accept(InboundSink.java:97)
at org.apache.cassandra.net.InboundSink.accept(InboundSink.java:45)
at
org.apache.cassandra.net.InboundMessageHandler$ProcessMessage.run(InboundMessageHandler.java:430)
at
org.apache.cassandra.concurrent.ImmediateExecutor.execute(ImmediateExecutor.java:87)
at org.apache.cassandra.concurrent.Stage.execute(Stage.java:125)
at
org.apache.cassandra.net.InboundMessageHandler.dispatch(InboundMessageHandler.java:399)
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]