Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Regular Contributor
tushar886
Posts: 52
Registered: ‎08-15-2013
My Carrier: Airtel

Problem starting MDS server Blackberry Messenger

Hi All,

 

I am facing issues in starting MDS server located inside Blackberrt Messenger SDK.

 

I have done set up of MDS server from URL :-

 

http://developer.blackberry.com/bbos/java/documentation/running_your_application_1391638_11.html

 

When i click on run.bat file the exception which is coming is as follows:-

 

 

<2013-08-23 21:40:29.783 IST>:[32]:<BBM_MDS>:<WARNG>:<LAYER = SCM, OS: Windows 7>
<2013-08-23 21:40:29.784 IST>:[33]:<BBM_MDS>:<WARNG>:<LAYER = SCM, OS Arch: amd64>
<2013-08-23 21:40:29.784 IST>:[34]:<BBM_MDS>:<WARNG>:<LAYER = SCM, OS Version: 6.1>
<2013-08-23 21:40:29.876 IST>:[35]:<BBM_MDS>:<ERROR>:<LAYER = SCM, EVENT = Exception, net.rim.application.ipproxyservice.b.a:
Initialize failed>
<2013-08-23 21:40:29.876 IST>:[35]:<BBM_MDS>:<ERROR>:<LAYER = SCM, EVENT = Exception, at net.rim.application.ipproxyservice
.IPProxyServiceApplication.start(Unknown Source)>
<2013-08-23 21:40:29.876 IST>:[35]:<BBM_MDS>:<ERROR>:<LAYER = SCM, EVENT = Exception, at net.rim.application.ipproxyservice
.IPProxyServiceApplication.main(Unknown Source)>
<2013-08-23 21:40:29.876 IST>:[35]:<BBM_MDS>:<ERROR>:<LAYER = SCM, EVENT = Exception, Caused by: java.lang.Exception: java.la
ng.Exception: java.lang.SecurityException>
<2013-08-23 21:40:29.876 IST>:[35]:<BBM_MDS>:<ERROR>:<LAYER = SCM, EVENT = Exception, at net.rim.protocol.bbm.BBMProtocol.i
nitialize(Unknown Source)>
<2013-08-23 21:40:29.876 IST>:[35]:<BBM_MDS>:<ERROR>:<LAYER = SCM, EVENT = Exception, at net.rim.protocol.bbm.BBMProtocol.s
tart(Unknown Source)>
<2013-08-23 21:40:29.876 IST>:[35]:<BBM_MDS>:<ERROR>:<LAYER = SCM, EVENT = Exception, at net.rim.service.c.start(Unknown So
urce)>
<2013-08-23 21:40:29.876 IST>:[35]:<BBM_MDS>:<ERROR>:<LAYER = SCM, EVENT = Exception, ... 2 more>

 

PLease help me in resolving this issue.

 

Thanks & Regards,

Tushar

Please use plain text.
Developer
peter_strange
Posts: 19,513
Registered: ‎07-14-2008

Re: Problem starting MDS server Blackberry Messenger

The page you referenced has the following additional link:

 

To learn how to install the MDS Simulator package, view......

 

A direct link to the MDS page follows:

http://developer.blackberry.com/bbos/java/documentation/configuring_your_system_for_bbm_support_orga...

 

Please review that page.

 

I would be confident that you have not set the encryption policy.  If you have multiple levels of java installed on your PC, be careful about putting this in the correct one. 

Please use plain text.
Regular Contributor
tushar886
Posts: 52
Registered: ‎08-15-2013
My Carrier: Airtel

Re: Problem starting MDS server Blackberry Messenger

Thanks a lot Peter.

 

actually for MDS i was using jdk 6 encryption policy whereas i had jdk 7 .

 

The MDS server is now working fine.

 

But again i encountered a new problem while developing a BBM app.

 

Its showing 

 

UncaughtException:- No Permission from Module

 


When the application tried to register itself this exception is thrown . I saw it in debug perspective

BBMException.JPG

 

 

Well the code snippet is as below:-

 

public BBMConnectionManager () {

		try {
			this.platformContext = BBMPlatformManager.register(new MyBBMAppPlugin(UUID));
		}
		catch (ControlledAccessException exp) {
			Dialog.alert(exp.getMessage());
			exp.printStackTrace();
		}
	    boolean allowed = platformContext.isAccessAllowed();
        System.out.println("BBMPlatformContext.isAccessAllowed()");
        if (!allowed) {
            int error = platformContext.getAccessErrorCode();
            // Ask if the user chose not to connect the app to BBM.
            if (error == BBMPlatformContext.ACCESS_BLOCKED_BY_USER) {
                Dialog.alert("Blocked BY User");
            }

		if (platformContext != null) 
		{

			platformContextListener = new MyBBMPlatformContextListener();
			this.platformContext.setListener(platformContextListener);
		}
        }
	}

 

 

Exception is coming at the time of  BBMPlatformManager.register .....

 

Please help me this BBM is very painful its taking a lot of time and still i am not able to achieve 10% of project what i am supposed to do.

 

Thanks & Regards,

Tushar

Please use plain text.
Developer
peter_strange
Posts: 19,513
Registered: ‎07-14-2008

Re: Problem starting MDS server Blackberry Messenger

Sorry I can't be of much help here.

 

Working with BBM is tricky, as there are a few hoops to go through that are used to make BBM secure.  I also think that RIM (as they were then) made the BBM interface complicated, because

1) They wanted BBM to be optional on the phones

2) they were trying to fit as much functionality in as they could, and

3) They wanted to ensure that users could upgrade their applications and RIM could update BBM independently. 

 

The best way to develop your first BBM application, I think, is to take one of the standard BBM applications and follow the same process.   And this approach makes it a lot easier to test too, because if your code fails, you can look at the sample application for a lead.  I still have applications that have a BBMBridge class in them that looks a lot like the one from tictactoe. 

 

Regarding your specific problem, I think it would be impossible for anyone to tell you what is wrong just given the snippet that you have shown.  It is possibly something as simple as the fact you are not running this process in a Thread, or you haven't delayed the process a fraction to give your Application's UI time to start.  Something like this is what I would look at since it appears your application has not even started.  You will notice that tictactoe is at pains to start a separate Thread for the BBM initializations. 

Please use plain text.
Regular Contributor
tushar886
Posts: 52
Registered: ‎08-15-2013
My Carrier: Airtel

Re: Problem starting MDS server Blackberry Messenger

Hi Peter,

 

Thanks a lot for ur suggestions. I have started progressing that manner only using BBMBridge.java class.

and make sure that all implementations in that remain intact and in given order only.

 

Well when i am running Tic Tac Toe application on simulator its showing there is insufficent network coverage to connect. At that time my laptop is connected to internet but still i cant get why its showing that.

The screenshot  is as Capture.JPG

 

Any idea why is this happening despite of the fact that the system is connected to internet.

The logs are as follows:-

 

0:03:51.631: VM:+CR
0:03:51.633: VM:-CR t=1
0:03:51.634: THRTL: Out: 0 bytes
0:03:51.635: THRTL: In: 0 bytes
0:03:51.637: SmplT: stSun Aug 25 17:27:00 GMT 2013
0:03:51.682: BBM: O E=TXst L=0 I=1233423548 A=RIM_IM/BBM_P2P l=15 v=0x10 t=0x5c len=10
0:03:52.865: VM:FSOMv=4
0:03:52.872: VM:smileytongue:ISVt=0,h=54cb,id=d15a33128dfbb5d9
0:03:52.874: VM:ACGRt=2,c=0
0:04:00.827: VM:IGCSc=0
0:04:00.829: VM:+GC(f)w=10
0:04:00.928: VM:-GCt=12,b=1,r=0,g=f,w=10,m=0
0:04:00.934: VM:+CR
0:04:00.957: VM:-CR t=3
0:04:15.831: BbiAuth:ERR:net.rim.device.api.crypto.bbiauth.BbiAuthException: No BBAuth service record configured
0:04:23.528: VM:IGCSc=0
0:04:23.530: VM:+GC(f)w=10
0:04:23.644: VM:-GCt=15,b=1,r=0,g=f,w=10,m=0
0:04:23.649: VM:QUOT t=1
0:04:23.650: VM:+CR
0:04:23.652: VM:-CR t=0
0:04:27.835: VM:smileytongue:ISVt=0,h=54cb,id=d15a33128dfbb5d9
0:04:27.838: VM:LNTDa=commit,t=1,p=net_rim_services_impl,h=234
0:04:35.530: VM:IGCSc=0
0:04:35.533: VM:+GC(f)w=10
0:04:35.641: VM:-GCt=14,b=1,r=0,g=f,w=10,m=0
0:04:35.647: VM:+CR
0:04:35.652: VM:-CR t=1

 

The MDS server is running fine. But still this error is coming.

 

One more request u mentioned in ur last reply that u have BBM apps . Are they apart from BBM sample apps.Can u plz share any application which will solve my purpose of chat implementation in BBM.

 

I shall be highly obliged if u do so.

 

Thanks & Regards,

Tushar

Please use plain text.
Developer
peter_strange
Posts: 19,513
Registered: ‎07-14-2008

Re: Problem starting MDS server Blackberry Messenger

Check that the Browser on your SImualtor works.  Let us know if it does. 

Please use plain text.
Regular Contributor
tushar886
Posts: 52
Registered: ‎08-15-2013
My Carrier: Airtel

Re: Problem starting MDS server Blackberry Messenger

Yes the browser is working on simulator.

 

This time whats happening is that the application is getting hanged up on step 2 i.e. Verification.

 

In MDS logs whats coming is as follows:-

 

<2013-08-25 23:10:12.527 IST>:[224]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, EVENT = Notification, TAG = 937689143, STATE = DELIVERED>
<2013-08-25 23:10:12.574 IST>:[225]:<BBM_MDS>:<DEBUG>:<LAYER = MDP, Receiving ACK for not existing datagram>
<2013-08-25 23:10:15.455 IST>:[226]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, EVENT = RemovedSendingQueue, DEVICEPIN = 2100000b>
<2013-08-25 23:12:02.159 IST>:[227]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, Connection Timed Out:2100000b>
<2013-08-25 23:12:02.160 IST>:[228]:<BBM_MDS>:<DEBUG>:<EVENT = Connection Timed Out, DEVICEPIN = 2100000b, CONNECTIONID = 1183165030>
<2013-08-25 23:12:02.162 IST>:[229]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, EVENT = CreatedSendingQueue, DEVICEPIN = 2100000b>
<2013-08-25 23:12:02.165 IST>:[230]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, EVENT = Sending, TAG = 937689144, DEVICEPIN = 2100000b, VERSION = 16, CONNECTI
ONID = 1183165030, SEQUENCE = 3, TYPE = ERROR, SIZE = 21, ERRORCODE = 127, ERRORMSG = [Connection Timed Out]>
<2013-08-25 23:12:02.167 IST>:[231]:<BBM_MDS>:<DEBUG>:<LAYER = SCM, Device connections: AVG latency (msecs)109640>
<2013-08-25 23:12:02.208 IST>:[232]:<BBM_MDS>:<INFO >:<LAYER = IPPP, DEVICEPIN = 2100000b, DOMAINNAME = appworld.blackberry.com, CONNECTION_TYPE =
DEVICE_CONN, ConnectionId = 1183165030, DURATION(ms) = 113545, MFH_KBytes = 0.646, MTH_KBytes = 4.132, MFH_PACKET_COUNT = 4, MTH_PACKET_COUNT = 4>
<2013-08-25 23:12:02.209 IST>:[233]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, defaulthandlernio: ipppIoThreadPool-8 stopped>
<2013-08-25 23:12:02.209 IST>:[234]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, defaulthandlernio: ipppIoThreadPool-8 cleaned up>
<2013-08-25 23:12:02.210 IST>:[235]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, EVENT = Sending, TAG = 937689145, DEVICEPIN = 2100000b, VERSION = 16, CONNECTI
ONID = 1183165030, SEQUENCE = 4, TYPE = DISCONNECT-ORDER, SIZE = 0>
<2013-08-25 23:12:02.211 IST>:[236]:<BBM_MDS>:<DEBUG>:<LAYER = SCM, Channel is closed>
<2013-08-25 23:12:02.212 IST>:[237]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, EVENT = RemovedReceivingQueue, DEVICEPIN:CONNECTIONID = 2100000b:1183165030, R
eceivingQueueSize = 0>
<2013-08-25 23:12:02.213 IST>:[238]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, User has been logged off:appworld.blackberry.com:443:2100000b:1183165030;>
<2013-08-25 23:12:02.213 IST>:[239]:<BBM_MDS>:<DEBUG>:<LAYER = SCM, Channel is closed>
<2013-08-25 23:12:02.266 IST>:[240]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, EVENT = Notification, TAG = 937689144, STATE = DELIVERED>
<2013-08-25 23:12:02.331 IST>:[241]:<BBM_MDS>:<DEBUG>:<LAYER = MDP, Receiving ACK for not existing datagram>
<2013-08-25 23:12:02.334 IST>:[242]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, EVENT = Notification, TAG = 937689145, STATE = DELIVERED>
<2013-08-25 23:12:02.336 IST>:[243]:<BBM_MDS>:<DEBUG>:<LAYER = MDP, Receiving ACK for not existing datagram>
<2013-08-25 23:12:03.483 IST>:[244]:<BBM_MDS>:<DEBUG>:<LAYER = IPPP, EVENT = RemovedSendingQueue, DEVICEPIN = 2100000b>
<2013-08-25 23:12:47.810 IST>:[245]:<BBM_MDS>:<DEBUG>:<LAYER = SCM, Admin. Task- HTTP Proxy Mappings>
<2013-08-25 23:12:47.810 IST>:[246]:<BBM_MDS>:<DEBUG>:<LAYER = SCM, Admin. Task- refresh media management>

 

 

 


and for about 2 minutes this process keeps on goign and what is getting displayed is that :

 

"SERVER IS UNAVAILABLE. UNABLE TO PROCEED WITH BBM CONNECTION "

 

Please suggest further.

 

Thanks & Regards,

Tushar

Please use plain text.
Developer
peter_strange
Posts: 19,513
Registered: ‎07-14-2008

Re: Problem starting MDS server Blackberry Messenger

[ Edited ]

Are you using one of the BBM Simulators?  Does BBM work on the Simulator?

Please use plain text.
Regular Contributor
tushar886
Posts: 52
Registered: ‎08-15-2013
My Carrier: Airtel

Re: Problem starting MDS server Blackberry Messenger

Yes i am using Blackberry 9900 simulator and development environment is eclipse JUNO.

 

Well i am not sure whether BBM works on simulator or not. Where will i get info about this.

 

I guess in BBM what matters is PIN no of device that i set via "RUN Configuration" in eclipse and that PIN number also appears in MDS Simulator  logs.

 

But still i am not sure that BBM works on simulator or not.

Please use plain text.
Developer
peter_strange
Posts: 19,513
Registered: ‎07-14-2008

Re: Problem starting MDS server Blackberry Messenger

On this page there are 3 download links to Simulators which come with BBM installed and working.  I recommend that you download and install at least one of these and make sure you have it running and working with BBM.

 

http://developer.blackberry.com/devzone/develop/bbm_connected/development.html

Please use plain text.