Source:
<code>public Object visitRemoveCommand(InvocationContext ctx, RemoveCommand command) throws Throwable { if (ctx.isOriginLocal()) { if (!(command.getKey() instanceof String)) { throw new CacheException("The key must be a string"); } String key = (String) command.getKey(); if (shouldIntercept(key)) { long flagsBitSet = copyFlags(command); LockControlCommand lockCommand = commandsFactory.buildLockControlCommand(ERRORS_KEY_SUFFIX, flagsBitSet, null); lockCommand.setTopologyId(command.getTopologyId()); invoker.invoke(ctx, lockCommand); WriteCommand writeCommand = commandsFactory.buildRemoveCommand(key + ERRORS_KEY_SUFFIX, null, flagsBitSet); writeCommand.setTopologyId(command.getTopologyId()); invoker.invoke(ctx, writeCommand); if (serializationContext.getFileDescriptors().containsKey(key)) { serializationContext.unregisterProtoFile(key); } <START> StringBuilder sb = new StringBuilder(); <END> for (FileDescriptor fd : serializationContext.getFileDescriptors().values()) { if (fd.isResolved()) { writeCommand = commandsFactory.buildRemoveCommand(fd.getName() + ERRORS_KEY_SUFFIX, null, flagsBitSet); invoker.invoke(ctx, writeCommand); } else { if (sb.length() > 0) { sb.append('\n'); } sb.append(fd.getName()); PutKeyValueCommand put = commandsFactory.buildPutKeyValueCommand(fd.getName() + ERRORS_KEY_SUFFIX, "One of the imported files is missing or has errors", DEFAULT_METADATA, flagsBitSet); put.setPutIfAbsent(true); invoker.invoke(ctx, put); } } if (sb.length() > 0) { writeCommand = commandsFactory.buildPutKeyValueCommand(ERRORS_KEY_SUFFIX, sb.toString(), DEFAULT_METADATA, flagsBitSet); } else { writeCommand = commandsFactory.buildRemoveCommand(ERRORS_KEY_SUFFIX, null, flagsBitSet); } writeCommand.setTopologyId(command.getTopologyId()); invoker.invoke(ctx, writeCommand); } } return invokeNext(ctx, command); }</code><technical_language>set topology</technical_language>

Target:
public Object visitRemoveCommand(InvocationContext ctx, RemoveCommand command) throws Throwable { if (ctx.isOriginLocal()) { if (!(command.getKey() instanceof String)) { throw new CacheException("The key must be a string"); } String key = (String) command.getKey(); if (shouldIntercept(key)) { long flagsBitSet = copyFlags(command); LockControlCommand lockCommand = commandsFactory.buildLockControlCommand(ERRORS_KEY_SUFFIX, flagsBitSet, null); invoker.invoke(ctx, lockCommand); WriteCommand writeCommand = commandsFactory.buildRemoveCommand(key + ERRORS_KEY_SUFFIX, null, flagsBitSet); invoker.invoke(ctx, writeCommand); if (serializationContext.getFileDescriptors().containsKey(key)) { serializationContext.unregisterProtoFile(key); } StringBuilder sb = new StringBuilder(); for (FileDescriptor fd : serializationContext.getFileDescriptors().values()) { if (fd.isResolved()) { writeCommand = commandsFactory.buildRemoveCommand(fd.getName() + ERRORS_KEY_SUFFIX, null, flagsBitSet); invoker.invoke(ctx, writeCommand); } else { if (sb.length() > 0) { sb.append('\n'); } sb.append(fd.getName()); PutKeyValueCommand put = commandsFactory.buildPutKeyValueCommand(fd.getName() + ERRORS_KEY_SUFFIX, "One of the imported files is missing or has errors", DEFAULT_METADATA, flagsBitSet); put.setPutIfAbsent(true); invoker.invoke(ctx, put); } } if (sb.length() > 0) { writeCommand = commandsFactory.buildPutKeyValueCommand(ERRORS_KEY_SUFFIX, sb.toString(), DEFAULT_METADATA, flagsBitSet); } else { writeCommand = commandsFactory.buildRemoveCommand(ERRORS_KEY_SUFFIX, null, flagsBitSet); } invoker.invoke(ctx, writeCommand); } } return invokeNext(ctx, command); }