Hi, Did anyone look into this - is it already fixed? If not we should have a JIRA at least to investigate.
Colm. On Tue, Feb 7, 2023 at 1:08 PM Thomas Matthijs <[email protected]> wrote: > > Hello, > > There is a difference in behavior between java 11 and java 17. When you throw > and exception from a service, the message is lost. > > I modified one of the example projects to throw an exception: > > https://github.com/selckin/cxf-exception/blob/master/src/main/java/demo/hw/server/HelloWorldImpl.java#L50 > > With java 11 on the client you will get: > demo.hw.server.AccessDeniedException: foobar123 > at > java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native > Method) > > On java 17, the message "foobar123" is missing > demo.hw.server.AccessDeniedException > at > java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native > Method) > > Believe this is because the message of the exception is retrieved using > reflection that is not allowed on java 17: > https://github.com/apache/cxf/blob/b6e3ab83a37cfb777d6eebf9711e552027bde37a/core/src/main/java/org/apache/cxf/interceptor/ClientFaultConverter.java#L197 > > This code is still there even in 4.0.0 which claims to support java 17. > > Is this a known issue or should I report it as a bug? Or is it accepted that > it won't work under java 17+ ? > > Are there any other known issues with java 17? > > Thanks
