ziti-sdk-jvm icon indicating copy to clipboard operation
ziti-sdk-jvm copied to clipboard

The org.openziti.springboot.ZitiProtocolCustomizer does not recover from service failures

Open ahazeltonNF opened this issue 1 year ago • 0 comments

Using the ZitiProtocolCustomizer to configure a spring boot application to listen on a ziti service.

On application start, the application behaves as expected but if a Ziti service interruption occurs and the bind fails, the connection is never recovered and an application restart is required.

On failure the exception below is generated (expected, as the result of the service interruption)

Exception in thread "http-ziti-app-exec-3" java.nio.channels.ClosedChannelException
    at org.openziti.net.ZitiServerSocketChannel.accept(ZitiServerSocketChannel.kt:174)
    at org.openziti.springboot.ZitiEndpoint$ZitiAcceptor.run(ZitiEndpoint.kt:47)
    at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191)
    at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.base/java.lang.Thread.run(Thread.java:1583)

The ZitiProtocolCustomizer should re-attempt the bind at some future time when the service is restored

ahazeltonNF avatar Mar 15 '24 13:03 ahazeltonNF