AnsweredAssumed Answered

SugarMoble Search reliance on Cache

Question asked by Ross Peetoom on Sep 7, 2018
Latest reply on Sep 10, 2018 by Ross Peetoom

I have a client that has 100+ users all working 99% of their day on the SugarMobile application, often working in rural areas with not great crrier coverage.  Finding records by searching and using saved filters in Mobile is very important to them, unfortunatley they were getting inconsistant results with those search results when Offline Mode was ENABLED.

 

In our testing we confirmed that searches on Sugar Mobile appear to rely to an extent on data cached on the mobile device when Offline Mode is ENABLED despite the device having a current connection to the Sugar DB.  Perhaps that was done in an effort to speed up search results by looking at the cached data first and then looking for changes on the Sugar DB but in my clients case where data (and therefore search results) can change regularly this causes a lot of issues. 

 

An example might be that I have a list of open cases, a colleague of mine does me a favor and closes some of those but when I refresh my list of open cases on mobile the now closed cases are all still there in my filtered search results based on what I have cached.  That might seem a minor issue in isolation but once you account for other automations in Sugar designed to update records to make life easier for users it soon results in some serious issues when searches are not being conducted against the most up-to-date versions of the records despite having a connection available to do so.  Making Offline Mode DISABLED resolves all these issues, effectively confirming the reliance sugar searches have on cached data but of course we'd prefer to not have to give up offline mode entirely because of this.

 

MY QUESTIONS THEN: 

 

  • Is it possible to adjust the way that the Sugar Mobile app behaves when perforing a search so that if a connection to the internet exists it does not rely on its cached data?
  • Has anyone encountered this issue and managed to address this and how?
  • Can you think of any pitfalls with changing the way the Sugar Mobile search works while Offline Mode is Enabled?

 

REPLICATING THE ISSUE:

In case you are interested to replicate an example of this issue you can follow the steps below in a stock version of SugarCRM 8.1:

  • 1) Mark 5 accounts as Favorites in Sugar Desktop
  • 2) Login to Sugar Mobile and make sure youhave Offline mode enabled
  • 3) Run the "My Favorites" saved filter on the Accounts module, this will return all 5 results correctly
  • 4) Back in Sugar Desktop remove (un-favorite) 2 of the 5 accounts
  • 5) Return to Sugar Mobile and refresh the "My Favorite" accounts filter
  • EXPECTED: mobile retrieves info from Sugar and shows only the remaining 3 favorite accounts
  • ACTUAL: mobile retrieves info from Sugar but continues to show all 5 accounts

 

In the above scenario if the user marks a new record as a favorite and refreshes the search results in Mobile it DOES show the new account but it still fails to remove the account records that were un-starred earlier, it is relying on its cached info over what is on the Sugar DB. The same can be viewed int his short video: https://www.screencast.com/t/UVKc4d2Fex


NOTE: this same issue occurs with other standard saved searches as well, I also tested and confirmed the issue with a saved search of Accounts in the City of Chicago or Accounts with an Industry of X, etc.

Outcomes