@Test public void onMessageReadFailure() { final Connector connector = createConnector(); newConnection( connector ); safeAction( () -> connector.setState( ConnectorState.CONNECTED ) ); pauseScheduler(); connector.onMessageReadFailure(); assertEquals( connector.getState(), ConnectorState.DISCONNECTING ); }
@Action( verifyRequired = false ) void onMessageReadFailure() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy() .reportSpyEvent( new MessageReadFailureEvent( getSchema().getId(), getSchema().getName() ) ); } disconnectIfPossible(); }
Connector extends ReplicantService { @Action( verifyRequired = false ) void onMessageReadFailure() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy() .reportSpyEvent( new MessageReadFailureEvent( getSchema().getId(), getSchema().getName() ) ); } disconnectIfPossible(); } }
Connector extends ReplicantService { @Action( verifyRequired = false ) void onMessageReadFailure() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy() .reportSpyEvent( new MessageReadFailureEvent( getSchema().getId(), getSchema().getName() ) ); } disconnectIfPossible(); } Connector( @Nullable final ReplicantContext context,
             @Nonnull final SystemSchema schema,
             @Nonnull final Transport transport ); }
Connector extends ReplicantService { @Action( verifyRequired = false ) void onMessageReadFailure() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy() .reportSpyEvent( new MessageReadFailureEvent( getSchema().getId(), getSchema().getName() ) ); } disconnectIfPossible(); } Connector( @Nullable final ReplicantContext context,
             @Nonnull final SystemSchema schema,
             @Nonnull final Transport transport ); @Override String toString(); }
Connector extends ReplicantService { @Action( verifyRequired = false ) void onMessageReadFailure() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy() .reportSpyEvent( new MessageReadFailureEvent( getSchema().getId(), getSchema().getName() ) ); } disconnectIfPossible(); } Connector( @Nullable final ReplicantContext context,
             @Nonnull final SystemSchema schema,
             @Nonnull final Transport transport ); @Override String toString();  }