12:36, EEST
August 14, 2018
Hello,
I have integrated an OPC Client into Anylogic to allow data exchange between Anylogic and an OPC UA Server. For that i am using the Prosys OPC UA Java SDK (v2.3.2-781).
The server and Anylogic are running on the same computer.
On my computer the whole system works fine.
My problem is the following:
I have installed the System on another computer. When i am starting the simulation, the following error occurs in Anylogic:
https://drive.google.com/drive/folders/1g2Tzz1T3NcC9qQhVkv8KXWapokKiFI2X?usp=sharing
Although I use the same
– Prosys OPC UA Java SDK
– Version of Anylogic
– Java-SDK (jdk-9.0.4 – i also tried other jdk-versions)
– UA SDK C++ bundle (v1.5.5-355)
it does not work.
What could be the reason for the error?
I would appreciate any help. Thank you!
12:53, EEST
April 3, 2012
Hi,
At the moment our Prosys OPC UA Java SDK is tested and works on java versions 6,7,8. Therefore please install and use a Java 8 runtime (or older). After java 11 is released in next month we hope to support it as it has options for LTS (long term support), i.e. 9 is already out-of-support with java 10 and 10 will be after 11 is released (next month).
In practice this issue happens because Java 9 changed on how reflection works (see e.g. https://stackoverflow.com/questions/41265266/how-to-solve-inaccessibleobjectexception-unable-to-make-member-accessible-m).
If possible, could you tell what operating system where this fails? Because I have run some tests on java 10 on windows 10 where the defaults allowed the reflection; it could be that this is platform specific.
13:59, EEST
August 14, 2018
Hello Bjarne,
thanks for your quick reply!
That was my thought, too.
So I tried to run the model with Java versions 8 and 10 (jdk-8u181, jdk-10.0.2), but it still does not work and I get the same error.
Do you know anything else that could be responsible for causing the issue?
I am running Windows 10, too.
14:25, EEST
April 3, 2012
Hi,
Could you please doublecheck that it is actually 8 that is used to run. In practice it should be impossible at least to get the same exception on 8, as the class InaccessibleObjectException is added in Java 9.. https://docs.oracle.com/javase/9/docs/api/java/lang/reflect/InaccessibleObjectException.html
12:40, EEST
August 14, 2018
14:48, EEST
April 17, 2013
Hello,
This does sound very interesting. Could you change the SDK logging level to DEBUG and provide the full resulting log file to us? From this file, we can see the exact Java runtime version.
With log4j logging, you can set the log level with
log4j.logger.com.prosysopc.ua=DEBUG
The log file can become very large; if you have problems pasting it here to the forum, you may also send it by email to us at uajava-support prosysopc.com.
Most Users Ever Online: 1919
Currently Online:
25 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_galleryModerators: Jouni Aro: 1026, Pyry: 1, Petri: 0, Bjarne Boström: 1032, Jimmy Ni: 26, Matti Siponen: 349, Lusetti: 0
Administrators: admin: 1