Пример #1
0
 private String execute(BeanstalkProtocol.Command command, byte[] data) {
   try {
     this.init();
     connection.write(data);
     String response = connection.readControlResponse();
     command.check(response);
     return response;
   } catch (BeanstalkDisconnectedException e) {
     this.active = false;
     throw e;
   }
 }