= Update the undertow Subsystem

In addition to migrating the *web* subsystem to {server-target-productName}, the JBoss Server Migration Tool adds the following functionality provided by the new *undertow* subsystem, which is configured in the {server-target-productName} default server configurations.

* Sets the default `HTTP Listener` redirect socket.
* Adds support for Java EE 7 `Websockets`.
* Sets the default `HTTPS` listener.
* Adds support for `HTTP2`.
* Sets the default `Server` response header.
* Sets the default `X-Powered-By` response header.
* Sets the default `HTTP Invoker`.

By default, the tool automatically updates any *undertow* subsystem configuration to include these changes.
If you prefer, you can configure the environment properties to customize the process of updating the *undertow* subsystem configuration.

|===
| Property Name |Property Description

| `subsystem.undertow.update.skip` | If set to `true`, the tool skips the update of the *undertow* subsystem.
| `subsystem.undertow.update.set-default-http-listener-redirect-socket.skip` | If set to `true`, the tool does not set the default `HTTP Listener` redirect socket.
| `subsystem.undertow.update.add-undertow-websockets.skip` | If set to `true`, the tool does not add support for WebSockets.
| `subsystem.undertow.update.add-undertow-https-listener.skip` | If set to `true`, the tool does not sets the default `HTTPS` listener.
| `subsystem.undertow.update.enable-http2.skip` | If set to `true`, the tool does not add support for `HTTP2`.
| `subsystem.undertow.update.add-response-header.server-header.skip` | If set to `true`, the tool does not set the default `Server` response header.
| `subsystem.undertow.update.add-response-header.x-powered-by-header.skip` | If set to `true`, the tool does not set the default `X-Powered-By` response header.
| `subsystem.undertow.update.add-http-invoker.skip` | If set to `true`, the tool does not sets the default `HTTP Invoker`.
|===

Upon successful migration of a *undertow* subsystem configuration, you should see messages in the console such as:

[source,options="nowrap"]
----
INFO  [ServerMigrationTask#33] Undertow's default HTTP listener 'http' redirect-socket set as 'https'.
INFO  [ServerMigrationTask#34] Undertow's default Servlet Container configured to support Websockets.
INFO  [ServerMigrationTask#35] Default HTTPS listener added to server '/subsystem=undertow/server=default-server', in Undertow's config /subsystem=undertow
INFO  [ServerMigrationTask#36] HTTP2 enabled for Undertow's HTTP Listener /subsystem=undertow/server=default-server/http-listener=http.
INFO  [ServerMigrationTask#36] HTTP2 enabled for Undertow's HTTPS Listener /subsystem=undertow/server=default-server/https-listener=https.
INFO  [ServerMigrationTask#37] Response header 'server-header' set as 'Server: JBoss-EAP/7' in Undertow's config /subsystem=undertow
INFO  [ServerMigrationTask#38] Response header 'x-powered-by-header' set as 'X-Powered-By: Undertow/1' in Undertow's config /subsystem=undertow
INFO  [ServerMigrationTask#39] Undertow's default host http-invoker configured.
----
