@Override
    public OpenApi after(Context<? extends Trait> context, OpenApi openapi) {
        if (context.getConfig().getKeepUnusedComponents()) {
            return openapi;
        }

        OpenApi current;
        OpenApi result = openapi;

        do {
            current = result;
            result = removalRound(context, current);
        } while (!result.equals(current));

        result = removeUnusedSecuritySchemes(result);
        return result;
    }
Removes unused components from the OpenAPI model.

<p>This plugin will take effect by default, but can be disabled by setting
"openapi.keepUnusedComponents" to true. Refs are removed in rounds until
a round of removals has no effect.

<p>TODO: This plugin currently only supports the removal of schemas and security schemes.
smithy-openapi/src/main/java/software/amazon/smithy/openapi/fromsmithy/mappers/RemoveUnusedComponents.java