public static GremlinError wrongSerializer(Exception ex) {
        final String message = String.format("Error during serialization: %s", ExceptionHelper.getMessageFromExceptionOrCause(ex));
        return new GremlinError(HttpResponseStatus.INTERNAL_SERVER_ERROR, message, "ServerSerializationException");
    }
Exception utility class that generates exceptions in the form expected in a {@code ResponseStatus} for different
issues that the server can encounter.
gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/util/GremlinError.java