Skip to content

Property to enable SPDY / HTTP2.0 in Undertow server #3350

Closed
@cbelleza

Description

@cbelleza

Hi,

It would be nice to have a property to enable SPDY / HTTP2.0 for Undertow server in application.properties.

I mean something like:

server.undertow.options=ENABLE_SPDY    # (ENABLE_HTTP2 or ENABLE_SPDY)

That would reflect into embedded web server the following code:

    @Bean
    public UndertowEmbeddedServletContainerFactory embeddedServletContainerFactory() {
        final UndertowEmbeddedServletContainerFactory undertowEmbeddedServletContainerFactory = new UndertowEmbeddedServletContainerFactory();
        undertowEmbeddedServletContainerFactory.addBuilderCustomizers(new UndertowBuilderCustomizer() {
            @Override
            public void customize(final Builder builder) {
                builder.setServerOption(UndertowOptions.ENABLE_SPDY, true);
            }
        });

        return undertowEmbeddedServletContainerFactory;
    }

Keeping in mind I should also add to java execution the ALPN library by all means:
-Xbootclasspath/p:C:\bin\alpn-boot-8.1.3.v20150130.jar

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions