Closed shkwaleed closed 6 years ago
try putting
defaultConfig {
your usual config code here
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
in your apps' build.gradle
tried it but still having same issue
Caused by: java.lang.ClassNotFoundException: Didn't find class
"java.time.Duration" on path: DexPathList[[zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/base.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_dependencies_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_0_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_1_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_2_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_3_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_4_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_5_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_6_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_7_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_8_apk.apk",
zip file
"/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_9_apk.apk"],nativeLibraryDirectories=[/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/lib/arm,
/vendor/lib, /system/lib]]
at
dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
at java.lang.ClassLoader.loadClass(ClassLoader.java:469)
at
com.microsoft.signalr.HubConnection.
On Thu, Nov 22, 2018 at 10:20 PM Buli1212 notifications@github.com wrote:
try putting
defaultConfig { your usual config code here }
compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 }
in your apps' build.gradle
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/aspnet/SignalR/issues/3332#issuecomment-441089284, or mute the thread https://github.com/notifications/unsubscribe-auth/Ad0qXK9uVwsatgm8sxjLSHNwl1FhLuYDks5uxtzngaJpZM4YvC9Z .
-- Regards
Engr. Waleed Ahmed
This is a dupe of https://github.com/aspnet/SignalR/issues/3141
We changed the RTM version to work on API level 16 or 20 if you're using the Azure SignalR Service. The RTM version isn't out yet, but will be soon.
If we create our own hub then will it work ?
On Sat, 24 Nov 2018, 03:11 BrennanConroy <notifications@github.com wrote:
Closed #3332 https://github.com/aspnet/SignalR/issues/3332.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/aspnet/SignalR/issues/3332#event-1984752885, or mute the thread https://github.com/notifications/unsubscribe-auth/Ad0qXEjDv5EHHcsoAMewZ1NlcqnzSy1Jks5uyHKhgaJpZM4YvC9Z .
Hubs are on the server and having nothing to do with Android compatibility on the client.
You will either need to wait until the 1.0.0 java client ships, or build it from source to get the lower API level version.
@BrennanConroy @shkwaleed what do you mean by Build it from source? and is it confirmed it will work?
Grab the source from https://github.com/aspnet/SignalR/tree/1.1.0/clients/java/signalr/src/main/java/com/microsoft/signalr and build it yourself.
The RTM version of the client will be shipping soon though, so if you can wait that would be easier.
Any time line when it will be out?
Can't give an exact date. But it will be soon.
The official timelines are posted to the aspnet/Announcements repo as "Roadmap" issues. So for 2.2: https://github.com/aspnet/Announcements/issues/307 . RTM is planned before the end of 2018.
The 1.0.0 version of the Java client has been officially released. You can import with gradle like so
compile 'com.microsoft.signalr:signalr:1.0.0'
And you can find your import statement here https://search.maven.org/artifact/com.microsoft.signalr/signalr/1.0.0/jar
Exception Details java.lang.ClassNotFoundException: Didn't find class "java.time.Duration" on path: DexPathList[[zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/base.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_dependencies_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_0_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_1_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_2_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_3_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_4_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_5_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_6_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_7_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_8_apk.apk", zip file "/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_9_apk.apk"],nativeLibraryDirectories=[/data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/lib/arm, /vendor/lib, /system/lib]] at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56) at java.lang.ClassLoader.loadClass(ClassLoader.java:511) at java.lang.ClassLoader.loadClass(ClassLoader.java:469) at com.microsoft.signalr.HubConnection.(HubConnection.java:50)
at com.microsoft.signalr.HttpHubConnectionBuilder.build(HttpHubConnectionBuilder.java:64)
at com.microsoft.aspnet.signalr.samples.androidjavaclient.MainActivity.onCreate(MainActivity.java:27)
at android.app.Activity.performCreate(Activity.java:6876)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1135)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3206)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3349)
at android.app.ActivityThread.access$1100(ActivityThread.java:221)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1794)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:158)
at android.app.ActivityThread.main(ActivityThread.java:7224)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Suppressed: java.io.IOException: No original dex files found for dex location /data/app/com.microsoft.aspnet.signalr.samples.androidjavaclient-1/split_lib_slice_5_apk.apk
at dalvik.system.DexFile.openDexFileNative(Native Method)
at dalvik.system.DexFile.openDexFile(DexFile.java:295)
at dalvik.system.DexFile.(DexFile.java:80)
at dalvik.system.DexFile.(DexFile.java:59)
at dalvik.system.DexPathList.loadDexFile(DexPathList.java:279)
at dalvik.system.DexPathList.makePathElements(DexPathList.java:248)
at dalvik.system.DexPathList.(DexPathList.java:120)
at dalvik.system.BaseDexClassLoader.(BaseDexClassLoader.java:48)
at dalvik.system.PathClassLoader.(PathClassLoader.java:65)
at android.app.ApplicationLoaders.getClassLoader(ApplicationLoaders.java:84)
at android.app.ApplicationLoaders.getClassLoader(ApplicationLoaders.java:45)
at android.app.LoadedApk.getClassLoader(LoadedApk.java:434)
at android.app.LoadedApk.makeApplication(LoadedApk.java:659)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6289)
On Android api below 26 we are unable to run signalr client