Android Question Problem with JRDC2 / java and "Object should first be initialized"

Rodrigo Vargas

Member
Licensed User
Hello,

I'm facing a big problem with an app developed in B4A already on production, that is driving me crazy.

The problem started this morning with no reason. I was working yesterday and sent an update to customer to check everything was ok before upload it to google play. until this morning.

All requests to mysql get an error "Object should be initialized"...even simple ones. The app is on production already, so the code was tested before. The backups in both sides: B4A IDE / Server don't work eather and the Apps already in the phones of the users stoped working. So.. seems that is not related with a last change in code, but something at server level.

Some facts:
- The app was working fine until today morning. The problem was not due a modification, It happens suddenly
- Tested Previous versions of the code (backups) not work either
- Tested Previous versions of the JRDC2 config file. Doesn't work
- I have successful connection with MySQL data base when testing : http://127.0.0.1:17178/test OK
- The only different thing I did AFTER many tests is that I allowed a java update go trough. (server). But this was AFTER all this problem happen.
Java 8 update 181 (build 1.8.0_181_B13)

This is the error I get in the logs:
-------------------------------------

ResponseError. Reason: java.lang.RuntimeException: Object should first be initialized (JavaObject)., Response: <html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>
<title>Error 500 java.lang.RuntimeException: Object should first be initialized (JavaObject).</title>
</head>
<body><h2>HTTP ERROR 500</h2>
<p>Problem accessing /rdc. Reason:
<pre> java.lang.RuntimeException: Object should first be initialized (JavaObject).</pre></p><hr><a href="http://eclipse.org/jetty">Powered by Jetty:// 9.4.z-SNAPSHOT</a><hr/>
</body>
</html>

This is the error in server side JRDC2 logs
----------------------------------------------
(RuntimeException) java.lang.RuntimeException: Object should first be initialized (JavaObject).
Command: , took: 31ms, client=(My IP)
 
Last edited:

Rodrigo Vargas

Member
Licensed User
OK, just found the problem

There was one field in the database added recently that was causing the whole app not to work. The connection, code, java and JRDC2 were all ok, but the change in the number of columns of that table raised the problem.

The message was not clear...seems to be related with connection, or initialización, but not with a database field. (Pointer out of range I guess or getting the wrong data).

Anyways... It was a long journey this morning before I found this very little detail.

Thanks
 
Upvote 0
Top