The HttpService implementation comes with support for HTTP/2 protocol. To enable it for Bosch IoT Gateway Software the requirements for running HTTP/2 are:
ALPN Providers
There are three available providers for ALPN support:
Bosch IoT Gateway Software comes with startup options for all these three providers:
server http2-conscrypt
server http2-jdk9
server http2-jdk8
The http2-jdk8 startup script uses Jetty ALPN Agent, which automatically selects the appropriate alpn-boot.jar based on the JVM version.
On Java 1.8.0u252 and above no alpn-boot JAR is required and the ALPN_BOOT environment variable should be set to the special value "none".
– On Windows:
set ALPN_BOOT=..\..\..\lib\alpn-boot.jar
server.bat http2-jdk8
– On Linux:
export ALPN_BOOT=../../../lib/alpn-boot.jar
./server.sh http2-jdk8
You can also edit http2-jdk8.bat/http2-jdk8.sh in bin/vms/jdk directory and set the ALPN_BOOT environment variable there.
Enabling HTTP/2 Protocol
After the gateway is started with ALPN support, HTTP/2 can be enabled by setting http2Enabled property to true in HttpService configuration – factory configuration with PID mbs.http.config.
To be able to use HTTP/2 protocol with browsers, HTTPS should also be configured – all major browsers support HTTP/2 only over secure connections. However browser support for Websockets over HTTP/2 is currently limited. As of 02/2020 only Firefox is known to support it.
For mote details refer to Migrating from Bosch HttpService implementation and the Setup Guide.