Smack Android with openfire performance

somehow the android multi threading and synchronized functions makes the XMPP life cycle to complete login in 20 seconds or more in android,

I tried AsyncTask which took around 77 seconds

I tried background service with multi threading which is taking 30 seconds

is it not possible to reduce this,

Strophe.js only takes 7 seconds or lesser than that in a Cordova hybrid android project.

I am using BOSH

You are aware that Smack’s BOSH code is not maintained? Only use it if you are able to debug, analyze and solve such problems yourself (ideally sending patches upstream ).

private final Lock lock = new ReentrantLock();

I am stuck with thread locking system, too much, some times the authentication itself is not happening even after 10 minutes in android