- public Command toCommand(String message) throws IOException {
- Command command = mapper.readValue(message, Command.class);
- LOG.info("{}: {}", command.getAction(), command.getVorgangId());
- return command;
- }
-
- public void dlzSaveReceived(Command command) throws InterruptedException {
- try
- {
- String result =
- service.bearbeiteVorgang(
- command.getVorgangId(),
- command.getVbId(),
- command.getData());
- reply(command, result);
- }
- catch (Exception e) {
- LOG.error("Exception during processing!", e);
- }
- }
-
- public void reply(Command command, String message) {
- String vorgangId = command.getVorgangId();
- String vbId = command.getVbId();
- Event event = new Event(DLZ_SAVED, vorgangId, vbId);
- event.getZustand().put(Event.DLZ, message);
- sender.send(event);
- }
-