Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

[-10204] Communication with the server failed with status code: 404-Android Offline store


I am trying to open offline store in my Android Native app, But i couldn't do it successfully. I am getting " Unknown network error occured". The callback for setofflinelistener is called, and offlinestore state changes from "offlinestore" opening then Initializing then populating, atlast offlineStoreOpenFailed is called. But, I can open onine store successfully, Can anyone help me to resolve this issue. I have given the code snippet below for offline store.


private boolean OpenOfflineStore() throws OfflineODataStoreException


  if (offlineStore==null){

  try {

  //This instantiate the native UDB libraries which are located in the

   // file


          LogonCoreContext lgCtx = LogonCore.getInstance().getLogonContext();

          String endPointURL = lgCtx.getAppEndPointUrl();

          URL url = null;

          try {

              url = new URL(endPointURL);

          } catch (MalformedURLException e) {





          ODataOfflineStoreOptions options = new ODataOfflineStoreOptions();

 = url.getHost();

          options.port = String.valueOf(url.getPort());



          options.enableHTTPS = lgCtx.isHttps();

          options.serviceRoot= endPointURL;

          Log.e("Connection id", "" + lgCtx.getConnId());



          String appConnID = lgCtx.getConnId();

          options.customHeaders.put("X-SMP-APPCID", appConnID);


          CredentialsProvider credProvider = CredentialsProvider.getInstance(lgCtx);

          HttpConversationManager manager = new CommonAuthFlowsConfigurator(this).

                  supportBasicAuthUsing(credProvider).configure(new HttpConversationManager(this));

          options.conversationManager = manager;



          options.enableRepeatableRequests = false;

          options.storeName="store name";






          offlineStore = new ODataOfflineStore(this);




          try {

              Log.e("","OpenOfflineStore: open");



      catch(Exception e)




  return true;

  } catch (Exception e) {

  throw new OfflineODataStoreException(e);


  } else {

  return true;




Not what you were looking for? View more on this topic or Ask a question