Avatar

Please consider registering
guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_TopicIcon
Logging error from Stack utils
August 11, 2023
10:33, EEST
Avatar
iivanov
Member
Members
Forum Posts: 6
Member Since:
August 11, 2023
sp_UserOfflineSmall Offline

Hi there!

In the logs we receive an error every couple of seconds:
2023-08-11 07:12:19.177 ERROR 1 — [Executor-107540] com.prosysopc.ua.stack.utils.StackUtils : Uncaught Exception in Thread: Thread[OPC-UA-Stack-Non-Blocking-Work-Executor-107540,5,main]
2023-08-11 10:12:19.177
java.lang.ArrayIndexOutOfBoundsException: null

That’s all the info we have and we could not troubleshoot any further. We are using the latest version and this is only happening in our prod environment. We did not see it happening in dev and stage.

August 11, 2023
11:10, EEST
Avatar
Bjarne Boström
Moderator
Moderators
Forum Posts: 1032
Member Since:
April 3, 2012
sp_UserOfflineSmall Offline

Hi,

Was there a stacktrace as well?

The default UncaughtExceptionHandler can be overridden by static com.prosysopc.ua.stack.utils.StackUtils.setUncaughtExceptionHandler(UncaughtExceptionHandler), but the default one by us already does (only) “logger.error(“Uncaught Exception in Thread: {}”, thread, ex);”, which should have resulted in a stacktrace as part of the log.

Anyway, if that fails to produce it, maybe you could override it and obtain it more manually? Or that override could anyway provide an entry point for e.g. profiler/debugger etc. (if possible in your prod environment).

August 11, 2023
11:41, EEST
Avatar
iivanov
Member
Members
Forum Posts: 6
Member Since:
August 11, 2023
sp_UserOfflineSmall Offline

Hi Bjarne,

No, unfortunately no stacktrace.
The main question is what can we check to figure out with what it is related and why can it be happening only on this environment.
The other strange part was that yesterday it was happening every 2 seconds and today it is more rare – like once every couple of minutes.

That’s all the info we get:
2023-08-11 08:40:01.024 ERROR 1 — [Executor-107577] com.prosysopc.ua.stack.utils.StackUtils : Uncaught Exception in Thread: Thread[OPC-UA-Stack-Non-Blocking-Work-Executor-107577,5,main]

java.lang.ArrayIndexOutOfBoundsException: null

August 11, 2023
12:40, EEST
Avatar
Bjarne Boström
Moderator
Moderators
Forum Posts: 1032
Member Since:
April 3, 2012
sp_UserOfflineSmall Offline

Is this the client or the server side? If client are there any different servers vs. other environments. And the same for the clients if the server side?

It is a bit hard to say anything without the stacktrace I’m afraid, sorry. But I was able to find: https://stackoverflow.com/questions/12582370/getting-arrayindexoutofboundsexception-null-with-no-stack-trace and https://bugs.openjdk.org/browse/JDK-8273392 , it would seem there might be an optimization by the JVM so that only the first exception shows the stacktrace. Is it possible to find the first instance where it happened? Alternative you could try to do the -XX:-OmitStackTraceInFastThrow mentioned in the link.

P.S.
Also I’m assuming by latest SDK version you mean https://downloads.prosysopc.com/opcua/Prosys_OPC_UA_SDK_for_Java_4_Release_Notes.html#version-4-10-6

Forum Timezone: Europe/Helsinki

Most Users Ever Online: 1919

Currently Online:
28 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

Heikki Tahvanainen: 402

hbrackel: 144

rocket science: 88

pramanj: 86

Francesco Zambon: 83

Ibrahim: 78

Sabari: 62

kapsl: 57

gjevremovic: 49

Xavier: 43

Member Stats:

Guest Posters: 0

Members: 726

Moderators: 7

Admins: 1

Forum Stats:

Groups: 3

Forums: 15

Topics: 1529

Posts: 6471

Newest Members:

gabriellabachus, Deakin, KTP25Zof, Wojciech Kubala, efrennowell431, wilfredostuart, caitlynfajardo, jeromechubb7, franciscagrimwad, adult_gallery

Moderators: Jouni Aro: 1026, Pyry: 1, Petri: 0, Bjarne Boström: 1032, Jimmy Ni: 26, Matti Siponen: 349, Lusetti: 0

Administrators: admin: 1