Thanks for your reply. If I republish the API, then it works. But if I have 100s of API, then it seems a quite a work.
I wish this can be auto registered when using export/import.
FYI, I noticed an old exception (which did not occur in 1.3.1) version when loading the custom plugin. It looks like it is related to snapshot versions.
I shall check further.
2018-09-24 16:16:57,376 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool -- 82) MSC000001: Failed to start service jboss.undertow.deployment.default-server.default-h
ost./apiman-gateway-api: org.jboss.msc.service.StartException in service jboss.undertow.deployment.default-server.default-host./apiman-gateway-api: java.lang.RuntimeException: ja
va.lang.RuntimeException: java.lang.Exception: Invalid plugin file at: /data/wildfly-11.0.0.Final/standalone/data/apiman/plugins/org.test/apiman-custom-failure/0.0.1-SNAPSHO
T/apimancustom-failure.war/plugin.war
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:84)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
at org.jboss.threads.JBossThread.run(JBossThread.java:320)
Caused by: java.lang.RuntimeException: java.lang.RuntimeException: java.lang.Exception: Invalid plugin file at: /data/wildfly-11.0.0.Final/standalone/data/apiman/plugins/org.test/apiman-custom-failure/0.0.1-SNAPSHOT/apiman-custom-failure.war/plugin.war
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:241)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.startContext(UndertowDeploymentService.java:99)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:81)
... 6 more
Caused by: java.lang.RuntimeException: java.lang.Exception: Invalid plugin file at: /data/wildfly-11.0.0.Final/standalone/data/apiman/plugins/org.test/apiman-custom-failure/
0.0.1-SNAPSHOT/apiman-custom-failure.war/plugin.war
at io.apiman.gateway.platforms.war.WarEngineConfig.loadConfigClass(WarEngineConfig.java:314)
at io.apiman.gateway.platforms.war.WarEngineConfig.getPolicyFailureWriterClass(WarEngineConfig.java:212)
at io.apiman.gateway.platforms.war.WarGateway.loadFailureFormatter(WarGateway.java:70)
at io.apiman.gateway.platforms.war.WarGateway.init(WarGateway.java:56)
at io.apiman.gateway.platforms.war.listeners.WarGatewayBootstrapper.contextInitialized(WarGatewayBootstrapper.java:42)
at io.undertow.servlet.core.ApplicationListeners.contextInitialized(ApplicationListeners.java:187)
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:205)
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:174)
at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:42)
at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)
at org.wildfly.extension.undertow.security.SecurityContextThreadSetupAction.lambda$create$0(SecurityContextThreadSetupAction.java:105)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:239)
... 8 more
Caused by: java.lang.Exception: Invalid plugin file at: /data/wildfly-11.0.0.Final/standalone/data/apiman/plugins/org.test/apiman-custom-failure/0.0.1-SNAPSHOT/apiman-custom
-failure.war/plugin.war
at io.apiman.gateway.engine.impl.DefaultPluginRegistry.readPluginFile(DefaultPluginRegistry.java:309)
at io.apiman.gateway.engine.impl.DefaultPluginRegistry.loadPlugin(DefaultPluginRegistry.java:246)
at io.apiman.gateway.platforms.war.WarEngineConfig.loadConfigClass(WarEngineConfig.java:311)
... 23 more