/** * @return String that represents the filter execution history for the current request */ public StringBuilder getFilterExecutionSummary() { return (StringBuilder) get(KEY_FILTER_EXECS); }
public int getOriginReportedDuration() { Object value = get("_originReportedDuration"); if (value != null) { return (Integer) value; } return -1; }
/** * returns the routeVIP; that is the Eureka "vip" of registered instances * * @return */ public String getRouteVIP() { return (String) get(KEY_VIP); }
/** * @return "routeHost" URL */ public URL getRouteHost() { return (URL) get("routeHost"); }
public String getString(String key) { return (String) get(key); }
static RequestStat getFromSessionContext(SessionContext context) { return (RequestStat) context.get(SESSION_CONTEXT_KEY); }
public String getEndpoint() { return (String) get(KEY_ENDPOINT); }
public static RequestAttempts getFromSessionContext(SessionContext ctx) { return (RequestAttempts) ctx.get(CommonContextKeys.REQUEST_ATTEMPTS); }
public String getErrorEndpoint() { return (String) get("_error-endpoint"); } public void setErrorEndpoint(String name) {
/** * * @return Returns the list of routiong debug messages */ public static List<String> getRoutingDebug(SessionContext ctx) { List<String> rd = (List<String>) ctx.get("routingDebug"); if (rd == null) { rd = new ArrayList<String>(); ctx.set("routingDebug", rd); } return rd; }
/** * * @return returns the list of request debug messages */ public static List<String> getRequestDebug(SessionContext ctx) { List<String> rd = (List<String>) ctx.get("requestDebug"); if (rd == null) { rd = new ArrayList<String>(); ctx.set("requestDebug", rd); } return rd; }
public int getOriginReportedDuration() { Object value = get("_originReportedDuration"); if (value != null) { return (Integer) value; } return -1; }
public String getErrorEndpoint() { return (String) get("_error-endpoint"); } public void setErrorEndpoint(String name) {
static RequestStat getFromSessionContext(SessionContext context) { return (RequestStat) context.get(SESSION_CONTEXT_KEY); }
protected final AtomicInteger getRunningFilterIndex(I zuulMesg) { final SessionContext ctx = zuulMesg.getContext(); return (AtomicInteger) Preconditions.checkNotNull(ctx.get(RUNNING_FILTER_IDX_SESSION_CTX_KEY), "runningFilterIndex"); }
public static ZuulFilter<HttpRequestMessage, HttpResponseMessage> getEndpoint(final HttpRequestMessage zuulReq) { if (zuulReq != null) { return (ZuulFilter<HttpRequestMessage, HttpResponseMessage>) zuulReq.getContext().get(ZUUL_ENDPOINT); } return null; }
/** * * @return Returns the list of routiong debug messages */ public static List<String> getRoutingDebug(SessionContext ctx) { List<String> rd = (List<String>) ctx.get("routingDebug"); if (rd == null) { rd = new ArrayList<String>(); ctx.set("routingDebug", rd); } return rd; }
public static void storeStatusCategoryIfNotAlreadyFailure(final SessionContext context, final StatusCategory statusCategory) { if (statusCategory != null) { final StatusCategory nfs = (StatusCategory) context.get(CommonContextKeys.STATUS_CATGEORY); if (nfs == null || nfs.getGroup().getId() == ZuulStatusCategoryGroup.SUCCESS.getId()) { context.set(CommonContextKeys.STATUS_CATGEORY, statusCategory); } } } }
protected final AtomicInteger getRunningFilterIndex(I zuulMesg) { final SessionContext ctx = zuulMesg.getContext(); return (AtomicInteger) Preconditions.checkNotNull(ctx.get(RUNNING_FILTER_IDX_SESSION_CTX_KEY), "runningFilterIndex"); }
public static void storeStatusCategoryIfNotAlreadyFailure(final SessionContext context, final StatusCategory statusCategory) { if (statusCategory != null) { final StatusCategory nfs = (StatusCategory) context.get(CommonContextKeys.STATUS_CATGEORY); if (nfs == null || nfs.getGroup().getId() == ZuulStatusCategoryGroup.SUCCESS.getId()) { context.set(CommonContextKeys.STATUS_CATGEORY, statusCategory); } } } }