ExpireDisconnectedClientTransactionsMessage extends HighPriorityDistributionMessage { @Override protected void process(ClusterDistributionManager dm) { InternalCache cache = dm.getCache(); InternalDistributedMember sender = getSender(); if (cache != null) { TXManagerImpl mgr = cache.getTXMgr(); if (sender.getVersion().isNotOlderThan(KnownVersion.GEODE_1_7_0)) { mgr.expireDisconnectedClientTransactions(this.txIds, false); } else { mgr.removeExpiredClientTransactions(this.txIds); } } } ExpireDisconnectedClientTransactionsMessage(); @Override void toData(DataOutput out,
      SerializationContext context); @Override void fromData(DataInput in,
      DeserializationContext context); @Override int getDSFID();  }
@Test public void processMessageFromServerOfGeode170AndLaterVersionWillExpireDisconnectedClientTransactions() { when(version.compareTo(KnownVersion.GEODE_1_7_0)).thenReturn(1); message.process(dm); verify(txManager, times(1)).expireDisconnectedClientTransactions(any(), eq(false)); }
@Test public void processMessageFromServerOfPriorGeode170VersionWillRemoveExpiredClientTransactions() { when(version.compareTo(KnownVersion.GEODE_1_7_0)).thenReturn(-1); message.process(dm); verify(txManager, times(1)).removeExpiredClientTransactions(any()); }