public class HttpServiceDownstreamRequestEvent extends ServiceDownstreamRequestEvent
ServiceEvent.Typedata, origin| Constructor and Description |
|---|
HttpServiceDownstreamRequestEvent(java.lang.String origin,
java.lang.String service,
java.lang.String operation)
Construct a new HttpServiceDownstreamRequestEvent
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getMethod()
Get the HTTP method from the event
|
java.lang.String |
getUri()
Get the URI from the event
|
boolean |
replaceHeader(java.lang.String name,
java.lang.String value)
This method is deprecated.
|
HttpServiceDownstreamRequestEvent |
withMethod(java.lang.String method)
Set the HTTP method in this event
|
HttpServiceDownstreamRequestEvent |
withUri(java.lang.String uri)
Set the URI in this event
|
getTypegetRequest, withRequestgetOperation, getService, getServiceEventIdgetData, getOrigin, withDataclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetOperation, getService, getServiceEventIdpublic HttpServiceDownstreamRequestEvent(java.lang.String origin,
java.lang.String service,
java.lang.String operation)
origin - the origin of the downstream call e.g. 'Web' or 'gRPC'service - the service name e.g. 'WeatherService'operation - the operation name e.g. 'getWeather'public HttpServiceDownstreamRequestEvent withMethod(java.lang.String method)
method - the method e.g. GET, POST etcpublic HttpServiceDownstreamRequestEvent withUri(java.lang.String uri)
uri - the URIpublic java.lang.String getMethod()
public java.lang.String getUri()
public boolean replaceHeader(java.lang.String name,
java.lang.String value)
HeaderReplaceable instead. If you are invoking replaceHeader, you should invoke it from its
implementing event class or by casting to HeaderReplaceable instead of invoking it from this class.name - the header namevalue - the header value