Hi everyone, I have been trying to figure out an issue I am having with a project i've been working on at work, the project consists of many dependencies, but the issue I am seeing is that if I run the project in Debug mode the project runs fine, but when I try to run it in Release Mode, then I get the following error:
I have been doing some research online but so far this link is the only one I have found so far describing something similar to what I am seeing.
Due to this project being for work I can not share more than what I am providing here, but I would really like to get some help with this, I feel like either I am missing a dependency file or something else is not compatible.
I wish B4J had a way to add a Dependency file similar to a Maven pom.xml file and that it could add or find any dependencies automatically without having to go through all this.
Just FYI, I have created the same project in Eclipse and I am able to run the project just fine, but I'm not sure if Eclipse runs the file in debug mode or release mode, so I really can't compare apples to apples.
Any hints, or advice you guys may have will be very much appreciated, I have been banging my head with this issue for a few weeks without being able to figure out what the root cause of this issue is.
Cheeers,
Walter
Essentially this project makes a call to an internal service to retrieve a list of firmware updates, a jwt token is generated and passed to the gRPC call to authenticate, all of this is working as it should, the problem is when trying to run in Release mode.io.grpc.StatusRuntimeException: UNKNOWN
at anywheresoftware.b4a.BA.checkAndRunWaitForEvent(BA.java:156)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:105)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:98)
at anywheresoftware.b4a.keywords.Common$3.run(Common.java:1118)
at javafx.graphics/com.sun.javafx.application.PlatformImpl.lambda$runLater$10(PlatformImpl.java:428)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
at javafx.graphics/com.sun.javafx.application.PlatformImpl.lambda$runLater$11(PlatformImpl.java:427)
at javafx.graphics/com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:96)
at javafx.graphics/com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at javafx.graphics/com.sun.glass.ui.win.WinApplication.lambda$runLoop$3(WinApplication.java:174)
at java.base/java.lang.Thread.run(Thread.java:832)
Caused by: java.nio.channels.UnsupportedAddressTypeException
at java.base/sun.nio.ch.Net.checkAddress(Net.java:136)
at java.base/sun.nio.ch.SocketChannelImpl.checkRemote(SocketChannelImpl.java:727)
at java.base/sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:741)
at io.netty.util.internal.SocketUtils$3.run(SocketUtils.java:91)
at io.netty.util.internal.SocketUtils$3.run(SocketUtils.java:88)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:554)
at io.netty.util.internal.SocketUtils.connect(SocketUtils.java:88)
at io.netty.channel.socket.nio.NioSocketChannel.doConnect(NioSocketChannel.java:322)
at io.netty.channel.nio.AbstractNioChannel$AbstractNioUnsafe.connect(AbstractNioChannel.java:248)
at io.netty.channel.DefaultChannelPipeline$HeadContext.connect(DefaultChannelPipeline.java:1342)
at io.netty.channel.AbstractChannelHandlerContext.invokeConnect(AbstractChannelHandlerContext.java:653)
at io.netty.channel.AbstractChannelHandlerContext.connect(AbstractChannelHandlerContext.java:632)
at io.netty.channel.ChannelDuplexHandler.connect(ChannelDuplexHandler.java:54)
at io.grpc.netty.WriteBufferingAndExceptionHandler.connect(WriteBufferingAndExceptionHandler.java:157)
at io.netty.channel.AbstractChannelHandlerContext.invokeConnect(AbstractChannelHandlerContext.java:655)
at io.netty.channel.AbstractChannelHandlerContext.access$1000(AbstractChannelHandlerContext.java:61)
at io.netty.channel.AbstractChannelHandlerContext$9.run(AbstractChannelHandlerContext.java:637)
at io.netty.util.concurrent.AbstractEventExecutor.runTask(AbstractEventExecutor.java:174)
at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:167)
at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:470)
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:569)
at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997)
at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
I have been doing some research online but so far this link is the only one I have found so far describing something similar to what I am seeing.
Here's the list of dependencies I am using
#AdditionalJar: google-http-client-gson-1.42.1.jar
#AdditionalJar: google-api-client-2.0.0.jar
#AdditionalJar: google-http-client-1.42.3.jar
#AdditionalJar: jackson-annotations-2.14.3.jar
#AdditionalJar: jackson-core-2.14.3.jar
#AdditionalJar: jackson-databind-2.14.3.jar
#AdditionalJar: google-auth-library-oauth2-http-1.23.0.jar
#AdditionalJar: google-api-services-iamcredentials-v1-rev20210813-1.32.1.jar
#AdditionalJar: google-oauth-client-1.34.1.jar
#AdditionalJar: netty-handler-4.1.87.Final.jar
#AdditionalJar: netty-common-4.1.87.Final.jar
#AdditionalJar: netty-buffer-4.1.87.Final.jar
#AdditionalJar: netty-transport-4.1.87.Final.jar
#AdditionalJar: netty-codec-http2-4.1.87.Final.jar
#AdditionalJar: netty-codec-4.1.87.Final.jar
#AdditionalJar: netty-codec-http-4.1.87.Final.jar
#AdditionalJar: netty-resolver-4.1.87.Final.jar
#AdditionalJar: grpc-netty-1.54.1.jar
#AdditionalJar: grpc-api-1.54.1.jar
#AdditionalJar: grpc-context-1.54.1.jar
#AdditionalJar: grpc-core-1.54.1.jar
#AdditionalJar: grpc-stub-1.54.1.jar
#AdditionalJar: grpc-protobuf-1.54.1.jar
#AdditionalJar: grpc-protobuf-lite-1.54.1.jar
#AdditionalJar: protobuf-java-3.22.2.jar
#AdditionalJar: guava-31.1-jre.jar
#AdditionalJar: failureaccess-1.0.1.jar
#AdditionalJar: perfmark-api-0.26.0.jar
#AdditionalJar: netty-transport-native-unix-common-4.1.87.Final.jar
#AdditionalJar: gson-2.9.0.jar
#AdditionalJar: java-jwt-4.0.0.jar
Due to this project being for work I can not share more than what I am providing here, but I would really like to get some help with this, I feel like either I am missing a dependency file or something else is not compatible.
I wish B4J had a way to add a Dependency file similar to a Maven pom.xml file and that it could add or find any dependencies automatically without having to go through all this.
Just FYI, I have created the same project in Eclipse and I am able to run the project just fine, but I'm not sure if Eclipse runs the file in debug mode or release mode, so I really can't compare apples to apples.
Any hints, or advice you guys may have will be very much appreciated, I have been banging my head with this issue for a few weeks without being able to figure out what the root cause of this issue is.
Cheeers,
Walter