Skip to content

Needs an uninstall #121

@trajano

Description

@trajano

When starting this up using a ServletContextListener and terminating the application it says that there are ThreadLocals that are still remaining.

Calling Security.removeProvider doesn't resolve the threadlocal issues

public class InstallCorretto implements ServletContextListener {

    /**
     * Servlet context attribute key.
     */
    public static final String CONTEXT = "useCorretto";

    @Override
    public void contextDestroyed(@NotNull final ServletContextEvent sce) {

        Security.removeProvider(AmazonCorrettoCryptoProvider.PROVIDER_NAME);
        sce.getServletContext().removeAttribute(CONTEXT);

    }

    @Override
    public void contextInitialized(@NotNull final ServletContextEvent sce) {

        AmazonCorrettoCryptoProvider.install();
        sce.getServletContext().setAttribute(CONTEXT, true);

    }
}

Here's the output when terminating.
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions