HTTPUTILS Download Issue

Bill Norris

Active Member
Licensed User
Longtime User
Am sending push message to 10 devices with one single batch file. The code that executes after the message is to download a new database file from server, then send an email confirmation, which also includes the file size of the new database in the subject line. I do this so I can see that all devices have updated successfully. Most of the time, everything works fine. Occasionally, one of the devices will report a file size that is incorrect (not always the same device, I might add). The app will then crash on that device due to a database error. I am perplexed.
 

Bill Norris

Active Member
Licensed User
Longtime User
RE:

Not sure how to add that waiting period in the batch file. Here is the batch file.

B4X:
java -cp b4a_c2dm.jar anywheresoftware.b4a.c2dm.C2DM send psstab1 "GET_DB"
java -cp b4a_c2dm.jar anywheresoftware.b4a.c2dm.C2DM send psstab2 "GET_DB"
java -cp b4a_c2dm.jar anywheresoftware.b4a.c2dm.C2DM send psstab3 "GET_DB"
java -cp b4a_c2dm.jar anywheresoftware.b4a.c2dm.C2DM send psstab4 "GET_DB"
java -cp b4a_c2dm.jar anywheresoftware.b4a.c2dm.C2DM send psstab5 "GET_DB"
java -cp b4a_c2dm.jar anywheresoftware.b4a.c2dm.C2DM send psstab6 "GET_DB"
java -cp b4a_c2dm.jar anywheresoftware.b4a.c2dm.C2DM send psstab7 "GET_DB"
java -cp b4a_c2dm.jar anywheresoftware.b4a.c2dm.C2DM send psstab8 "GET_DB"
 
Upvote 0

mc73

Well-Known Member
Licensed User
Longtime User
You don't really have to put this period in your batch file. You can, for example, program your devices to wait for a n-multiple of a predefined period, based on their 'id', using a timer at the client's side. For e.g. psstab1 no wait, psstab2 wait 1x5secs (period can be similar to the estimated download time) and so on.
 
Upvote 0
Top