Class RouterExceptionAndTrackingUtils


  • public class RouterExceptionAndTrackingUtils
    extends java.lang.Object
    Right now, there is no simple way to capture all the exception cases with DDS Router. So we temporarily track all the error cases when throwing a exception. TODO: If later on DDS router could support a better way to register a handler to handle the exceptional cases, we should update the logic here. TODO: Remove all Optional from this class.
    • Constructor Detail

      • RouterExceptionAndTrackingUtils

        public RouterExceptionAndTrackingUtils()
    • Method Detail

      • newRouterExceptionAndTracking

        public static RouterException newRouterExceptionAndTracking​(java.util.Optional<java.lang.String> storeName,
                                                                    java.util.Optional<RequestType> requestType,
                                                                    io.netty.handler.codec.http.HttpResponseStatus responseStatus,
                                                                    java.lang.String msg)
      • newRouterExceptionAndTrackingResourceNotFound

        public static RouterException newRouterExceptionAndTrackingResourceNotFound​(java.util.Optional<java.lang.String> storeName,
                                                                                    java.util.Optional<RequestType> requestType,
                                                                                    io.netty.handler.codec.http.HttpResponseStatus responseStatus,
                                                                                    java.lang.String msg)
      • newVeniceExceptionAndTracking

        @Deprecated
        public static VeniceException newVeniceExceptionAndTracking​(java.util.Optional<java.lang.String> storeName,
                                                                    java.util.Optional<RequestType> requestType,
                                                                    io.netty.handler.codec.http.HttpResponseStatus responseStatus,
                                                                    java.lang.String msg,
                                                                    RouterExceptionAndTrackingUtils.FailureType failureType)
        Deprecated.
      • newVeniceExceptionAndTracking

        @Deprecated
        public static VeniceException newVeniceExceptionAndTracking​(java.util.Optional<java.lang.String> storeName,
                                                                    java.util.Optional<RequestType> requestType,
                                                                    io.netty.handler.codec.http.HttpResponseStatus responseStatus,
                                                                    java.lang.String msg)
        Deprecated.
      • recordUnavailableReplicaStreamingRequest

        public static void recordUnavailableReplicaStreamingRequest​(java.lang.String storeName,
                                                                    RequestType requestType)