B4J Question [RESOLVED] Timers under JRE NOT JDK dont seem to fire ...

Jmu5667

Well-Known Member
Licensed User
Longtime User
Hello

I have a console app that connects to an MS SQL Database, this is ok, and a single class that polls the DB every 1 second. Under JDK the timer fires and all is normal. When I run the same app under JRE the timer does not fire.

I moved the timer out of the class and put it in the main and call the query function in the class. This works fine in the JDK but not in the JRE.

Under the JRE task manger show the JRE VM using 50% CPU.

JRE Version is 8 Update 202 (build 1.8.0_202-b08)
B4J Version is 7.51

Anyone else experiencing this ?

Regards

John.
 

Jmu5667

Well-Known Member
Licensed User
Longtime User
This is still open, there seems to be an issue with this. JRE 8 212 (build 1.8.0_212-b10) works on one VM server and not on another ....
 
Upvote 0

jmon

Well-Known Member
Licensed User
Longtime User
I have never encountered this problem, but i'll try to help.
  • Can you post part of your code?
  • When you say that it works under the JDK, do you mean that it works in the B4J IDE? And when you double click the jar it doesn't work?
  • Can you run your app with "java -jar myapp.jar" in CMD and see the log? Maybe you'll have some errors written there.
  • Are you using the ConnectionPool from the server library?
 
Upvote 0

Jmu5667

Well-Known Member
Licensed User
Longtime User
I have never encountered this problem, but i'll try to help.
  • Can you post part of your code?
  • When you say that it works under the JDK, do you mean that it works in the B4J IDE? And when you double click the jar it doesn't work?
  • Can you run your app with "java -jar myapp.jar" in CMD and see the log? Maybe you'll have some errors written there.
  • Are you using the ConnectionPool from the server library?
Hey Jmon

1. I am using a connection pool, set to three
2. The app starts in java -jar myapp.jar and the console window shows
3. The JDK/JRE may be a red herring, I just tried it on the VM box it fails on with JDK installed and the sames result.
4. I will do a sample of the app as this is a commercial product.- Be a bout 10 mins :)

Regards

John.
 
Upvote 0
Top