Rule Matching
In Membrane API Gateway, rule matching is the process of selecting a rule that will handle an incoming HTTP request.
The list of rules is defined in Membrane's configuration file, proxies.xml, as a list of <proxys, serviceProxys or soapProxys, or any combination of them. A rule typically defines a list of transformations (interceptors), which are to be applied to the request, as well as a target (host and/or port), where the request is to be forwarded to.
For an incoming HTTP request, the first api, proxy, serviceProxy or soapProxy matching the request will be selected. Whether a proxy is selected, is defined by its filter criteria. The filter criteria are a subset of
- incoming TCP port
- local IP address
- hostname (the HTTP request's Host header)
- request path (matched by a path prefix or a Java regular expression)
Standalone Deployment
For example, if proxies.xml looks like
Figure1:
Figure2: