Maximo Anywhere

  • 1.  Device Log in Issues

    Posted Wed July 01, 2020 10:05 AM
    Hi,

    We are experiencing log in issues with a specific device zebra TC70 with anywhere 7.6.4 where it would say loading for at least 4-5 minutes before successfully logging in. We have tested other android devices and we don't experience this issue at all. unfortunately we can only use the zebra TC70's at this time. We have also tried adding the IBM technician app from the play store and it says device incompatible, any ideas as to why this might be happening ? are there any specific device requirements for the Anywhere IBM Technician app for android ?

    Thanks.

    ------------------------------
    Jefferson Odongo
    ------------------------------


  • 2.  RE: Device Log in Issues

    IBM Select
    Posted Wed July 01, 2020 03:01 PM
    Further info:  looking at the cursor outputs in the adb logs of a samsung s8 connected vs the zebra connected it seems that the sqlite read/writes are slower on the zebra than on the samsung.  This is supported by the fact that just every operation that would require db read/writes seem to be on the same magnitude slower when comparing the two devices (synchs, lookup data download, login, etc).  I am by no means a true android app developer so I may not be on the right track, but this is our current theory.  
    Any ideas as to things to explore/try or ideas as to why there would be a significant performance difference with sqlite between the two devices?  Or just ways to further confirm the theory?  


    ------------------------------
    Victor Chin
    ------------------------------



  • 3.  RE: Device Log in Issues

    IBM Select
    Posted Wed July 08, 2020 12:32 PM
    Update: IBM has a fix that will significantly speed up the login time.  However we are still experiencing performance discrepencies between our zebra and android devices but now we dont have anything that we cant live with (1 second action delayed to 5 seconds is much different than 20 seconds delayed to minutes).   

    WIth that said we are still investigating the device performance discrepency.

    ------------------------------
    Victor Chin
    ------------------------------



  • 4.  RE: Device Log in Issues

    IBM Select
    Posted Thu July 09, 2020 02:43 PM
    Update:  we suspected that the performance issue on our zebra device was due to performance issues with the sqlcipher database.  To prove out that theory we updated the databaseaccessorimpl class to add the PRAGMA cipher_memory_security = OFF statement on creation of the db. tested the new apk against the old apk on the zebra and other android devices and there is significant performance boost on the zebra.  As expected the other android devices pretty much function the same with both.  Compared performance for various actions (system data download, lookup download, login) and the zebra with the new apk performs in line with the other androids.  So this setting seems to get the zebra performing in line with other android devices.  

    ------------------------------
    Victor Chin
    ------------------------------



  • 5.  RE: Device Log in Issues

    Posted Tue July 27, 2021 12:28 PM
    Hi Victor,

    Could you please share your steps for updating databaseaccessorimpl class? We're facing same performance problems with Zebra devices.

    Regards,
    Muhammed Zahid Soluk 


    ------------------------------
    Muhammed Zahid Soluk
    ------------------------------



  • 6.  RE: Device Log in Issues

    Posted Wed July 28, 2021 07:47 AM
    Hi Muhammed zahid Soluk,

    Have you tried disabling encryption property in the build properties? I would like to believe the database cipher property could have been set to ON when the encryption property is set to true.

    Thanks,
    Biplab

    ------------------------------
    Biplab Choudhury
    Maximo Consultant
    Tata Consultancy Services
    Melbourne
    ------------------------------



  • 7.  RE: Device Log in Issues

    IBM Select
    Posted Thu July 29, 2021 02:40 PM
    In order to prove this theory we had to first verify that anywhere is indeed built on top of the sqlcipher library.  To do this we had to identify where IBM puts all the database generation code for anywhere eventually determining that this is in the ibmmobilefirstplatformfoundationjsonstore.jar file.   We opened that up and were eventually able to identify that the databaseaccessorimpl.class  does indeed utilize the sqlcipher package.   Thus, to then test that the sqlcipher database management setting does indeed impact the performance of anywhere on the zebra devices we updated the databaseaccessorimpl class to add the PRAGMA cipher_memory_security = OFF statement on creation of the db. 

    public void createTable(JSONStoreSyncPolicy syncpolicy)
    {
    String name = this.schema.getName();

    logger.logTrace("creating database \"" + name + "\"");
    if (syncpolicy != JSONStoreSyncPolicy.SYNC_NONE) {
    execSQL("CREATE TABLE {0} ({1} INTEGER PRIMARY KEY AUTOINCREMENT, {2} {3} TEXT, {4} REAL DEFAULT 0, {5} INTEGER DEFAULT 0, {6} TEXT, {7} TEXT, {8} TEXT);", new Object[] { name, "_id", formatSchemaColumns(), "json", "_dirty", "_deleted", "_operation", "_cloudant_id", "_cloudant_rev" });
    } else {
    execSQL("CREATE TABLE {0} ({1} INTEGER PRIMARY KEY AUTOINCREMENT, {2} {3} TEXT, {4} REAL DEFAULT 0, {5} INTEGER DEFAULT 0, {6} TEXT);", new Object[] { name, "_id", formatSchemaColumns(), "json", "_dirty", "_deleted", "_operation" });
    }
    execSQL("PRAGMA cipher_memory_security = OFF", new Object[]{});
    }

    We rebuilt the anywhere apk and tested the new apk against the old apk on the zebra and samsung devices and found that there is a significant performance boost on the zebra.  As expected the samsung pretty much functioned the same with both apks.  We then compared performance for various actions (system data download, lookup download, login) with the zebra with the new apk and found that it performs in line with the Samsung devices.  Thus, this setting was confirmed to get the zebra performing in line with other android devices and remove the latency we were experiencing. 

    Thus, 
    - update databaseaccessorimpl.class with PRAGMA cipher_memory_security = OFF
    - add new class to ibmmobilefirstplatformfoundationjsonstore.jar  (if I recall the build uses this jar in a speciffic location in the directory so make sure you are updating the correct one)
    - build new apk  (you can check the directory that gets updated with the new build, forget the exact directory name, to validate that the jar in the newly built apk is indeed the new jar)    
    - test new apk

    ------------------------------
    Victor Chin
    ------------------------------