If Gluer did not find any application matching with incoming request, it will try a resource resolution then will forward the request to the first matching backend in the Site configuration.
backend-rules
which are matching criterias to route to a Backend
application.
Resource resolution
Before forwarding the request to a backend, Gluer will try to find a resource matching with the incoming path.
Path resolution should result in the following cases
Status 200, resource found
If a resource was found by url resolution, Gluer will find the first configured backend rule matching depending host-pattern
, path-pattern
, handle-resource-types
and handle-resource-status
.
host-pattern
must match with the input domain namepath-pattern
must match with the pathhandle-resource-types
must be missing (not configured) or containing resource type resolved by url resolutionhandle-resource-status
must be missing (not configured) or containing status 200 resolved by url resolution
Request will be forwarded to the first backend matching the four criterias.
Status 301 or 302, resource found but must be accessed with an other path.
If resource resolution result in a redirect 301 or 302, Gluer will immediately send a redirect to the client and will not forward the request to a backend.
Status 404 or 410, resource not found or gone
If resource resolution result in a not found or gone resource, Gluer will find the first configured backend rule matching depending host-pattern
, path-pattern
and handle-resource-status
.
host-pattern
must match with the input domain namepath-pattern
must match with the pathhandle-resource-status
must be missing (not configured) or containing status 404 (or 410) resolved by url resolution
Even if resource resolution result in a not found or gone resource, request is sent to a backend, usualy Shaper Web, that is able to identify the Page configured with the Designer to display a dynamic error page. For instance, this will allow you to include header and footer in your page.
Status 500, error while resolving resource
If resource resolution result in an error (resource resolution has failed due to technical problem), Gluer will send to the client the error 500 page configured for the current site.
Backend request
When a backend is identified, Gluer will build the proxy request depending on url
of the chosen application version for this backend rule and the path from the incoming request.
It will then forward incoming headers except Host
, Connection
and Accept-Encoding
headers and send some other headers
Host
header with- Domain name from
src
in configuration ifuse-host-header
is missing or set as false (Cloud configuration with an haproxy) - Domain name from incoming request if
use-host-header
is set as true (Direct host configuration)
- Domain name from
X-Forwarded-Proto
sheme of the incoming request (http or https)X-Forwarded-Host
domain name from incoming requestX-Kobi-Device
the device id identified by GluerX-Kobi-Site-Id
the site id identified by GluerX-Kobi-Site-App-Url
the base url of the micro application handling site templatesX-Kobi-Navigation-Mode
the navigation mode LIVE, EDIT or PREVIEW (EDIT and PREVIEW are used with KOBI Designer)X-Kobi-Preview-Mode
the preview mode LIVE or DRAFT for preview with KOBI DesignerX-Kobi-Preview-Date
the preview date for preview with KOBI DesignerX-Kobi-Page-Variation-Id
the page variation to edit with KOBI DesignerX-Kobi-Page-Model-Id
the page model to edit with KOBI DesignerX-Kobi-Resource-Status
the status from url resolutionX-Kobi-Resource-Type
the resource type from url resolutionX-Kobi-Resource-Id
the resource id from url resolutionX-Kobi-Resource-Scope
the resource scope from url resolutionX-Kobi-Resource-Path
the path of the resource (may be different from the input path if an internal redirect is done by url resolution, should be used as canonical path).X-CSRF-TOKEN
the CSRF token if CSRF is implementedX-Kobi-Application-Context
the application context, only in application modeVia: Kobi Gluer
a fixed headerConnection: keep-alive
a fixed header to keep alive connections