Seen in an exception stack trace: we are wrapping `ApiFilteringActionFilter` around itself many times, once per filtered action, so effectively every action is doing a linear scan of the filtered actions, implemented recursively. I'm pretty sure a hashmap would be more efficient, and would avoid inflating the stack so much too.

```
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:86) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.action.support.ActionFilter$Simple.apply(ActionFilter.java:53) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at co.elastic.elasticsearch.api.validation.PublicSettingsValidationActionFilter.apply(PublicSettingsValidationActionFilter.java:101) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.core.api.filtering.ApiFilteringActionFilter.apply(ApiFilteringActionFilter.java:53) ~[?:?]
    at org.elasticsearch.action.support.TransportAction$RequestFilterChain.proceed(TransportAction.java:84) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
    at org.elasticsearch.xpack.security.action.filter.SecurityActionFilter.lambda$applyInternal$3(SecurityActionFilter.java:163) ~[?:?]
    at org.elasticsearch.action.ActionListenerImplementations$DelegatingFailureActionListener.onResponse(ActionListenerImplementations.java:212) ~[elasticsearch-8.11.0-SNAPSHOT.jar:?]
```
server/src/main/java/org/elasticsearch/action/ActionModule.java
import org.elasticsearch.persistent.RemovePersistentTaskAction;
import org.elasticsearch.persistent.StartPersistentTaskAction;
import org.elasticsearch.persistent.UpdatePersistentTaskStatusAction;
import org.elasticsearch.plugins.ActionPlugin;
import org.elasticsearch.plugins.ActionPlugin.ActionHandler;
import org.elasticsearch.plugins.interceptor.RestServerActionPlugin;
import org.elasticsearch.plugins.internal.RestExtension;
import org.elasticsearch.reservedstate.ReservedClusterStateHandler;
import org.elasticsearch.reservedstate.service.ReservedClusterStateService;
import org.elasticsearch.rest.RestController;
import org.elasticsearch.rest.RestHandler;
import org.elasticsearch.rest.RestHeaderDefinition;
import org.elasticsearch.rest.RestUtils;
import org.elasticsearch.rest.action.RestFieldCapabilitiesAction;
import org.elasticsearch.rest.action.admin.cluster.RestAddVotingConfigExclusionAction;
import org.elasticsearch.rest.action.admin.cluster.RestCancelTasksAction;
import org.elasticsearch.rest.action.admin.cluster.RestCleanupRepositoryAction;
import org.elasticsearch.rest.action.admin.cluster.RestClearVotingConfigExclusionsAction;
import org.elasticsearch.rest.action.admin.cluster.RestCloneSnapshotAction;
import org.elasticsearch.rest.action.admin.cluster.RestClusterAllocationExplainAction;
import org.elasticsearch.rest.action.admin.cluster.RestClusterGetSettingsAction;
import org.elasticsearch.rest.action.admin.cluster.RestClusterHealthAction;
import org.elasticsearch.rest.action.admin.cluster.RestClusterRerouteAction;
import org.elasticsearch.rest.action.admin.cluster.RestClusterSearchShardsAction;
import org.elasticsearch.rest.action.admin.cluster.RestClusterStateAction;
import org.elasticsearch.rest.action.admin.cluster.RestClusterStatsAction;
import org.elasticsearch.rest.action.admin.cluster.RestClusterUpdateSettingsAction;
import org.elasticsearch.rest.action.admin.cluster.RestCreateSnapshotAction;
import org.elasticsearch.rest.action.admin.cluster.RestDeleteDesiredBalanceAction;
import org.elasticsearch.rest.action.admin.cluster.RestDeleteDesiredNodesAction;