Examples of ServiceException


Examples of com.google.protobuf.ServiceException

            resultDataType = info.getField().getType();
            break;
          }
        }
      } catch (Throwable throwable) {
        throw new ServiceException(throwable);
      }

      ClientProtos.QueryResultProto.Builder builder = ClientProtos.QueryResultProto.newBuilder();
            builder.addResult(ProtobufUtil.toStringBytesPair(new KeyValue(Bytes.toBytes(type.getMethodName()),
                Bytes.toBytes(info.getField().getFamily()), Bytes.toBytes(type.getMethodName()), value)));

Examples of com.google.protobuf.ServiceException

            return id;
        }

        public void checkForFailure() throws ServiceException {
            if (isDead) {
                throw new ServiceException("Simulated server shutdown");
            }
        }

Examples of com.google.protobuf.ServiceException

    try {
      List<String> argList = request.getArgsList();
      String[] args = argList.toArray(new String[argList.size()]);

      if (!request.hasIdentifier()) {
        throw new ServiceException("Request must contain identifier");
      }

      Collection<RefreshResponse> results = impl.refresh(request.getIdentifier(), args);

      return pack(results);
    } catch (IOException e) {
      throw new ServiceException(e);
    }
  }

Examples of com.googlecode.sonic.exception.ServiceException

  protected Entity selectForcibly(Long id) throws ServiceException {
    AssertionUtil.assertIsValid(ID, id);
    try {
      return datastoreService.get(KeyFactory.createKey(kindOfEntity, id));
    } catch (EntityNotFoundException e) {
      throw new ServiceException(e);
    }
  }

Examples of com.gwtplatform.dispatch.rpc.shared.ServiceException

        if (action.isSecured() && !cookieMatch(cookieSentByRPC)) {
            String message = xsrfAttackMessage + " While executing action: " + action.getClass().getName();

            logger.severe(message);
            throw new ServiceException(message);
        }

        try {
            return dispatch.execute(action);
        } catch (ActionException e) {
            if (logger.isLoggable(Level.WARNING)) {
                String newMessage = "Action exception while executing " + action.getClass().getName() + ": " +
                        e.getMessage();
                logger.log(Level.WARNING, newMessage, e);
            }

            removeStacktraces(e);

            throw e;
        } catch (ServiceException e) {
            if (logger.isLoggable(Level.WARNING)) {
                logger.log(Level.WARNING, "Service exception while executing " + action.getClass().getName() + ": " +
                        e.getMessage(), e);
            }

            throw new ServiceException(e.getMessage());
        } catch (RuntimeException e) {
            if (logger.isLoggable(Level.WARNING)) {
                logger.log(Level.WARNING, "Unexpected exception while executing " + action.getClass().getName() + ": " +
                        "" + e.getMessage(), e);
            }

            throw new ServiceException(e.getMessage());
        }
    }

Examples of com.gwtplatform.dispatch.shared.ServiceException

        try {
            if (actionValidator.isValid(action)) {
                return handler.execute(action, ctx);
            } else {
                throw new ServiceException(actionValidator.getClass().getName() + actionValidatorMessage + action
                        .getClass().getName());
            }
        } catch (ActionException e) {
            throw e;
        } catch (Exception e) {
            String newMessage = "Service exception executing action \"" + action.getClass().getSimpleName() + "\", " +
                    "" + e.toString();
            throw new ServiceException(newMessage, e);
        }
    }

Examples of com.microsoft.windowsazure.exception.ServiceException

            if (shouldTrace) {
                CloudTracing.receiveResponse(invocationId, httpResponse);
            }
            int statusCode = httpResponse.getStatusLine().getStatusCode();
            if (statusCode != HttpStatus.SC_CREATED) {
                ServiceException ex = ServiceException.createFromXml(httpRequest, requestContent, httpResponse, httpResponse.getEntity());
                if (shouldTrace) {
                    CloudTracing.error(invocationId, ex);
                }
                throw ex;
            }

Examples of com.mockey.ServiceException

        ValidateResponse.SCHEMA, ValidateResponse.INVALID_SCHEMA,
        rawSchema);
    final boolean invalidData = fillWithData(ret, ValidateResponse.DATA,
        ValidateResponse.INVALID_DATA, rawData);
    if (invalidSchema || invalidData) {
      throw new ServiceException("Schema valid? " + invalidSchema
          + " Data valid?" + invalidData);
    }
    final JsonNode schemaNode = ret.remove(ValidateResponse.SCHEMA);
    final JsonNode data = ret.remove(ValidateResponse.DATA);
    final JsonValidator validator = JsonValidators.withOptions(useV3, useId);

Examples of com.nagarro.jsag.fjt.commons.exceptions.ServiceException

            flights = this.flightDAO.performSearch(flightSearch);
            System.out.println(flights);
            System.out.println("in search mode not here");
        } catch (final DAOException exception) {
            StandardFlightSearchService.LOG.error(MethodUtils.errorMessage(exception));
            throw new ServiceException(ServiceException.DEFAULT_MESSAGE, exception);
        }
        return flights;
    }

Examples of com.structis.fichesst.shared.exception.ServiceException

  protected void doUnexpectedFailure(Throwable e) {
    // logger les erreurs
    logger.error("Erreur inattendu", e);

    if( e != null && e.getCause() instanceof ServiceException ) {
      ServiceException serviceException = (ServiceException) e.getCause();

      try {
        getThreadLocalResponse().reset();
      }
      catch( IllegalStateException ex ) {
        throw new RuntimeException("Unable to report failure", serviceException);
      }
      ServletContext servletContext = getServletContext();
      HttpServletResponse response = getThreadLocalResponse();
      try {
        response.setContentType("text/plain");
        response.setStatus(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
        try {
          response.getOutputStream().write(serviceException.getCode().getBytes());
        }
        catch( IllegalStateException ex ) {
          response.getWriter().write(serviceException.getCode());
        }
      }
      catch( IOException ex ) {
        servletContext.log(
            "respondWithUnexpectedFailure failed while sending the previous failure to the client", ex);
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.