Class Origin


public class Origin extends Object

Class that groups the elements that uniquely identify a destination.

The elements are scheme, host, port, a Origin.Protocol and a tag object that further distinguishes destinations that have the same origin and protocol.

In general it is possible that, for the same origin, the server can speak different protocols (for example, clear-text HTTP/1.1 and clear-text HTTP/2), so the Origin.Protocol makes that distinction.

Furthermore, it may be desirable to have different destinations for the same origin and protocol (for example, when using the PROXY protocol in a reverse proxy server, you want to be able to map the client ip:port to the destination tag, so that all the connections to the server associated to that destination can specify the PROXY protocol bytes for that particular client connection.