Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 9076

Re: Synchronization Exception while synchronizing DB on SUP Server

$
0
0

Hi Mithun,

 

  This is the code which I am using for connection and synchronization :

 

 

  Application application = ((MyApplication) getApplication()).getApp();

  ConnectionProperties connectionProperties = application.getConnectionProperties();

  connectionProperties.setServerName("192.168.2.9");

  connectionProperties.setPortNumber(5001);

 

 

  LoginCredentials credentials = new LoginCredentials("supAdmin", "supadmin05");

  connectionProperties.setLoginCredentials(credentials);

 

 

  ConnectionProfile syncProfile =  XXXXXXDB.getSynchronizationProfile();

  syncProfile.setServerName("192.168.2.9");

  syncProfile.setPortNumber(2489);

  syncProfile.setNetworkProtocol("http");

  syncProfile.setCacheSize(102400);

  syncProfile.setAsyncReplay(true);

  syncProfile.save();

 

  if (application.getRegistrationStatus() != RegistrationStatus.REGISTERED)

  {

   application.registerApplication(600);

   XXXXXXDB.onlineLogin("supAdmin", "supadmin05");

   XXXXXXDB.synchronize();

  }

  else

  {

  if (! XXXXXXDB.offlineLogin("supAdmin", "supadmin05"))

  {

   XXXXXXDB.onlineLogin("supAdmin", "supadmin05");

   Log.d("MainActivity", "***done with online login.");

  }

  }

 

 

The device on SCC is shown Online and I m not using any relay server.


Viewing all articles
Browse latest Browse all 9076

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>