Open kavidriod opened 4 years ago
Are you adding only the source code to your project? What about the resources? What's stopping you from just adding Paho as a dependency?
how to fix?
@kavidriod I had solve this problem. 1.in the library build.gradle dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) }
2.copy "org.eclipse.paho.client.mqttv3-1.2.5.jar" to the libs directory of the Library. remark : Copy the org.eclipse.paho.client.mqttv3-x.x.x.jar version you have.
3.The most important step: 3-1 ) Create the java resource folder on your Library Module : New > Folder > Java Resources Folder You will find a "resources" folder in "src/main" 3-2 ) Download the paho.mqtt.java source. Copy FOLDER : META-INF and org FILE : bundle.properties from "paho.mqtt.java-master\paho.mqtt.java-master\org.eclipse.paho.client.mqttv3\src\main\resources" to "src/main/resources"
4.Build your aar file and get it in build/outputs
+1
+1
+1
Please fill out the form below before submitting, thank you!
I'm currently exploring on paho client in my sample Android Application. Instead of using jar file I'm trying to use Source code of org.eclipse.paho.client.mqttv3 and org.eclipse.paho.android.service as Android Library. I'm able to successfully add source code of both jar files. But when I try to connect my app to mosquitto broker I'm getting this Exception.
Caused by: java.util.MissingResourceException: Can't find bundle for base name paho.mqtt.pahoclient.internal.nls.logcat, locale en_US
Error Screenshot is added here.
Anyone faced these issue?