Calling this method:
IntercomSdk.Intercom.Client().DisplayMessenger();
I get this exception:
[AndroidRuntime] java.lang.NoSuchMethodError: No virtual method onNestedFling(Landroid/support/design/widget/CoordinatorLayout;Landroid/support/design/widget/AppBarLayout;Landroid/view/View;FFZ)Z in class Landroid/support/design/widget/AppBarLayout$Behavior; or its super classes (declaration of 'android.support.design.widget.AppBarLayout$Behavior' appears in /data/app/es.smartloto.smartloto-dvf2COkzGja7r9FkpKRG-Q==/base.apk
[AndroidRuntime] at io.intercom.android.sdk.profile.ProfileCoordinator.flingCoordinator(ProfileCoordinator.java:191)
[AndroidRuntime] at io.intercom.android.sdk.profile.ProfileCoordinator.profileAutoOpened(ProfileCoordinator.java:175)
[AndroidRuntime] at io.intercom.android.sdk.conversation.ConversationFragment.sdkWindowFinishedAnimating(ConversationFragment.java:643)
[AndroidRuntime] at io.intercom.android.sdk.activities.IntercomMessengerActivity$3.onAnimationEnd(IntercomMessengerActivity.java:244)
[AndroidRuntime] at android.view.ViewPropertyAnimator$AnimatorEventListener.onAnimationEnd(ViewPropertyAnimator.java:1122)
[AndroidRuntime] at android.animation.Animator$AnimatorListener.onAnimationEnd(Animator.java:552)
[AndroidRuntime] at android.animation.ValueAnimator.endAnimation(ValueAnimator.java:1209)
[AndroidRuntime] at android.animation.ValueAnimator.doAnimationFrame(ValueAnimator.java:1449)
[AndroidRuntime] at android.animation.AnimationHandler.doAnimationFrame(AnimationHandler.java:146)
[AndroidRuntime] at android.animation.AnimationHandler.-wrap2(Unknown Source:0)
[AndroidRuntime] at android.animation.AnimationHandler$1.doFrame(AnimationHandler.java:54)
[AndroidRuntime] at android.view.Choreographer$CallbackRecord.run(Choreographer.java:909)
[AndroidRuntime] at android.view.Choreographer.doCallbacks(Choreographer.java:723)
[AndroidRuntime] at android.view.Choreographer.doFrame(Choreographer.java:655)
[AndroidRuntime] at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:897)
[AndroidRuntime] at android.os.Handler.handleCallback(Handler.java:789)
[AndroidRuntime] at android.os.Handler.dispatchMessage(Handler.java:98)
[AndroidRuntime] at android.os.Looper.loop(Looper.java:164)
[AndroidRuntime] at android.app.ActivityThread.main(ActivityThread.java:6541)
[AndroidRuntime] at java.lang.reflect.Method.invoke(Native Method)
[AndroidRuntime] at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
[AndroidRuntime] at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)
I tested different options to try to solve the problem but I couldn't find the solution.
I appreciate your help, thank you!!
I found the cause of the error.
It occurs if you have a newer version of the android support libraries in your project than that the java aar was builded with.
Most bindings for Intercom use the Intercom Android SDK Version 3.0.XX, which was built against API Level 25 (Support libraries 25.XX.XX), I think.
I could solve the problem by creating my own bindings for the newest version of the Intercom Android SDK which are build against API Level 27, which I happen to use in my project.
Basicaly you have 2 option:
Create your own Bindings with the new Intercom Version
Downgrade your API Level and Support Libraries to Version 25.XX.XX
I might upload my Binding of the new Intercom Android SDK to github at some point, however it might take some time until I will be able do so.
Related
Curity is currently using log4j2 as the default logger. Is there a way to change it to logback.?
Currently I have build a custom Docker image doing the following steps. (base image used curity.azurecr.io/curity/idsvr:6.7.2 )
Replaced the log4j2.xml file with a logback.xml file with logback configuration in the path /opt/idsvr/etc/
Removed existing log4j jar files in the path /opt/idsvr/lib and replaced with logback jar files downloaded from https://logback.qos.ch/download.html
After doing above steps I launched the custom image as a container. But I got the following error messages.
your customer that you accept the terms of the Curity License Agreement.
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
idsvr was installed into /opt/idsvr. You can begin using it by starting /opt/idsvr/bin/idsvr
openjdk version "11.0.13" 2021-10-19 LTS
OpenJDK Runtime Environment Zulu11.52+14-SA (build 11.0.13+8-LTS)
OpenJDK 64-Bit Server VM Zulu11.52+14-SA (build 11.0.13+8-LTS, mixed mode)
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/logging/log4j/core/impl/LogEventFactory
at java.base/java.lang.ClassLoader.defineClass1(Native Method)
at java.base/java.lang.ClassLoader.defineClass(Unknown Source)
at java.base/java.security.SecureClassLoader.defineClass(Unknown Source)
at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(Unknown Source)
at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(Unknown Source)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(Unknown Source)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(Unknown Source)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(Unknown Source)
at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
at se.curity.identityserver.app.LogInitializer.initializeLoggers(LogInitializer.java:54)
at se.curity.identityserver.app.Bootstrapper.main(Bootstrapper.java:118)
at se.curity.identityserver.app.Bootstrapper.main(Bootstrapper.java:100)
Caused by: java.lang.ClassNotFoundException: org.apache.logging.log4j.core.impl.LogEventFactory
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(Unknown Source)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(Unknown Source)
at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
... 12 more
Any help would be kindy appreciated. Thanks..
No, replacing Log4j with Logback is not supported. The use of Log4j runs very deep in the product, and cannot be replaced by users. I'd recommend asking another questions about the issue that led you to want to replace the ❤️ of the logging subsystem. Perhaps that has a solution that doesn't require heart surgery.
After upgrading Xamarin.Azure.NotificationHubs.Android Nuget from ancient 0.6 to 1.1.4.1 (which involves also upgrade from Support libs to AndroidX) in my App - Everything is OK without Azure Notification Hub and FireBase Nugets (and commenting code which use them). With these Azure/FCM NuGets I get Exception when starting App:
[AndroidRuntime] Shutting down VM
[AndroidRuntime] FATAL EXCEPTION: main
[AndroidRuntime] Process: com.taphome.android.next, PID: 12930
[AndroidRuntime] java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/android/datatransport/runtime/ExecutionModule_ExecutorFactory;
[AndroidRuntime] at com.google.android.datatransport.runtime.DaggerTransportRuntimeComponent.initialize(DaggerTransportRuntimeComponent.java:75)
[AndroidRuntime] at com.google.android.datatransport.runtime.DaggerTransportRuntimeComponent.<init>(DaggerTransportRuntimeComponent.java:66)
[AndroidRuntime] at com.google.android.datatransport.runtime.DaggerTransportRuntimeComponent.<init>(DaggerTransportRuntimeComponent.java:36)
[AndroidRuntime] at com.google.android.datatransport.runtime.DaggerTransportRuntimeComponent$Builder.build(DaggerTransportRuntimeComponent.java:109)
[AndroidRuntime] at com.google.android.datatransport.runtime.TransportRuntime.initialize(TransportRuntime.java:78)
[AndroidRuntime] at com.google.firebase.datatransport.TransportRegistrar.lambda$getComponents$0(TransportRegistrar.java:37)
[AndroidRuntime] at com.google.firebase.datatransport.TransportRegistrar$$Lambda$1.create(Unknown Source:0)
[AndroidRuntime] at com.google.firebase.components.ComponentRuntime.lambda$discoverComponents$0(ComponentRuntime.java:132)
[AndroidRuntime] at com.google.firebase.components.ComponentRuntime$$Lambda$1.get(Unknown Source:4)
[AndroidRuntime] at com.google.firebase.components.Lazy.get(Lazy.java:53)
[AndroidRuntime] at com.google.firebase.components.AbstractComponentContainer.get(AbstractComponentContainer.java:27)
[AndroidRuntime] at com.google.firebase.components.RestrictedComponentContainer.get(RestrictedComponentContainer.java:89)
[AndroidRuntime] at com.google.firebase.messaging.FirebaseMessagingRegistrar.lambda$getComponents$0$FirebaseMessagingRegistrar(Unknown Source:43)
[AndroidRuntime] at com.google.firebase.messaging.FirebaseMessagingRegistrar$$Lambda$0.create(Unknown Source:0)
[AndroidRuntime] at android.os.Looper.loop(Loope02-05 23:18:04.900 E/AndroidRuntime(12930): at com.google.firebase.components.ComponentRuntime.lambda$discoverComponents$0(ComponentRuntime.java:132)
[AndroidRuntime] at com.google.firebase.components.ComponentRuntime$$Lambda$1.get(Unknown Source:4)
[AndroidRuntime] at com.google.firebase.components.Lazy.get(Lazy.java:53)
[AndroidRuntime] at com.google.firebase.components.ComponentRuntime.initializeEagerComponents(ComponentRuntime.java:281)
[AndroidRuntime] at com.google.firebase.FirebaseApp.initializeAllApis(FirebaseApp.java:584)
[AndroidRuntime] at com.google.firebase.FirebaseApp.initializeApp(FirebaseApp.java:303)
[AndroidRuntime] at com.google.firebase.FirebaseApp.initializeApp(FirebaseApp.java:267)
[AndroidRuntime] at com.google.firebase.FirebaseApp.initializeApp(FirebaseApp.java:252)
[AndroidRuntime] at com.google.firebase.provider.FirebaseInitProvider.onCreate(FirebaseInitProvider.java:51)
[AndroidRuntime] at android.content.ContentProvider.attachInfo(ContentProvider.java:2113)
[AndroidRuntime] at android.content.ContentProvider.attachInfo(ContentProvider.java:2087)
[AndroidRuntime] at com.google.firebase.provider.FirebaseInitProvider.attachInfo(FirebaseInitProvider.java:45)
[AndroidRuntime] at android.app.ActivityThread.installProvider(ActivityThread.java:7751)
[AndroidRuntime] at android.app.ActivityThread.installContentProviders(ActivityThread.java:7296)
[AndroidRuntime] at android.app.ActivityThread.handleMakeApplication(ActivityThread.java:7153)
[AndroidRuntime] at android.app.ActivityThread.handleBindApplication(ActivityThread.java:7121)
[AndroidRuntime] at android.app.ActivityThread.access$1500(ActivityThread.java:274)
[AndroidRuntime] at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2102)
[AndroidRuntime] at android.os.Handler.dispatchMessage(Handler.java:107)
[AndroidRuntime] at android.os.Looper.loop(Looper.java:237)
[AndroidRuntime] at android.app.ActivityThread.main(ActivityThread.java:8154)
[AndroidRuntime] at java.lang.reflect.Method.invoke(Native Method)
[AndroidRuntime] at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:496)
[AndroidRuntime] at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1100)
[AndroidRuntime] Caused by: java.lang.ClassNotFoundException: com.google.android.datatransport.runtime.ExecutionModule_ExecutorFactory
[AndroidRuntime] at java.lang.VMClassLoader.findLoadedClass(Native Method)
[AndroidRuntime] at java.lang.ClassLoader.findLoadedClass(ClassLoader.java:738)
[AndroidRuntime] at java.lang.ClassLoader.loadClass(ClassLoader.java:363)
[AndroidRuntime] at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
[AndroidRuntime] ... 40 more
[AndroidRuntime] Caused by: java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/android/datatransport/runtime/dagger/internal/Factory;
[AndroidRuntime] ... 40 more
[AndroidRuntime] Caused by: java.lang.ClassNotFoundException: com.google.android.datatransport.runtime.dagger.internal.Factory
[AndroidRuntime] at java.lang.VMClassLoader.findLoadedClass(Native Method)
[AndroidRuntime] at java.lang.ClassLoader.findLoadedClass(ClassLoader.java:738)
[AndroidRuntime] at java.lang.ClassLoader.loadClass(ClassLoader.java:363)
[AndroidRuntime] at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
[AndroidRuntime] ... 40 more
[AndroidRuntime] Caused by: java.lang.NoClassDefFoundError: Failed resolution of: Ljavax/inject/Provider;
[AndroidRuntime] ... 40 more
[AndroidRuntime] Caused by: java.lang.ClassNotFoundException: Didn't find class "javax.inject.Provider" on path: DexPathList[[zip file "/data/app/com.taphome.android.next-UA_GiR9v1xnKi34mZZEeCg==/base.apk"],nativeLibraryDirectories=[/data/app/com.taphome.android.next-UA_GiR9v1xnKi34mZZEeCg==/lib/arm, /data/app/com.taphome.android.next-UA_GiR9v1xnKi34mZZEeCg==/base.apk!/lib/armeabi-v7a, /system/lib, /product/lib]]
[AndroidRuntime] at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:196)
[AndroidRuntime] at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
[AndroidRuntime] at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
[AndroidRuntime] ... 40 more
I had to add "Xamarin.Google.Dagger" NuGet, which is not listed in "Xamarin.Azure.NotificationHubs.Android" dependecies.
I'm specifying dataflow runner in my beamSql program below :
DataflowPipelineOptions options = PipelineOptionsFactory.as(DataflowPipelineOptions.class);
options.setStagingLocation("gs://gcpbucket/staging");
options.setTempLocation("gs://gcpbucket/tmp");
options.setProject("beta-19xxxx");
options.setRunner(DataflowRunner.class);
Pipeline p = Pipeline.create(options);
But I'm getting below exception :
Exception in thread "main" java.lang.RuntimeException: Failed to construct instance from factory method DataflowRunner#fromOptions(interface org.apache.beam.sdk.options.PipelineOptions)
at org.apache.beam.sdk.util.InstanceBuilder.buildFromMethod(InstanceBuilder.java:233)
at org.apache.beam.sdk.util.InstanceBuilder.build(InstanceBuilder.java:162)
at org.apache.beam.sdk.PipelineRunner.fromOptions(PipelineRunner.java:55)
at org.apache.beam.sdk.Pipeline.create(Pipeline.java:150)
at my.proj.StarterPipeline.main(StarterPipeline.java:34)Caused by: java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.base/java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.beam.sdk.util.InstanceBuilder.buildFromMethod(InstanceBuilder.java:222)
... 4 more Caused by: java.lang.IllegalArgumentException: Unable to use ClassLoader to detect classpath elements. Current ClassLoader is jdk.internal.loader.ClassLoaders$AppClassLoader#782830e, only URLClassLoaders are supported.
at org.apache.beam.runners.dataflow.repackaged.org.apache.beam.runners.core.construction.PipelineResources.detectClassPathResourcesToStage(PipelineResources.java:43)
at org.apache.beam.runners.dataflow.DataflowRunner.fromOptions(DataflowRunner.java:262)
can anyone help me out understand what exactly is the issue ?
Downgrading java 9 to java 8 did the trick.
This problem can happen when using Beam SDK with JVM > 8.
Support for JVM 11 (or 9) is only experimental, starting from Beam SDK 2.12 and at least up to Beam SDK 2.16. This answer provides a bit more context: https://stackoverflow.com/a/57710742/1046584
Regarding this specific stack trace, it seems related to this issue: https://issues.apache.org/jira/browse/BEAM-3718
For me the fix was different. In my pom.xml, below dependency was set to 2.20 while apache beam was set to 2.19
<dependency>
<groupId>org.apache.beam</groupId>
<artifactId>beam-sdks-java-extensions-google-cloud-platform-core</artifactId>
<version>2.20</version>
</dependency>
After changing it to same as beam version, build was working fine.
Net Net, just make sure all the beam related sdks are set to same version. Use variable for the same, like ${beamVersion} so you don't end up facing strange errors.
I am trying to build a maven 2.2.1 project on Jenkins ver. 1.596. The project uses JDK 1.5 and it is not an option to upgrade to a newer JDK.
When building the project I get the following stacktrace:
Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at hudson.maven.agent.Main.main(Main.java:143)
at hudson.maven.agent.Main.main(Main.java:68)
I have seen a lot of posts about this issue with Jenkins and JDK1.5, but noone has come up with a solution. Hope that somebody has found a workaround.
Regards
Steffen
using Eclipse to try and build a maven project with Eclipse. Anyway when I try to run mvn clean install I get the following error
Failed to execute goal org.jboss.ws.plugins:maven-jaxws-tools-plugin:1.0.1.GA:wsconsume (default) on project sso: Error while running wsconsume: Process terminated with code 1
Its calling a MojoExecutionException.
Anyway I am getting the code from a subversion repository which works for others so its not the pom file. I done some googling and it mentions it could be the JBoss version I have running which could be causing the issue. I am using JBoss6.1.0. Also using Maven 3.0.4
Anyone have any ideas? If you need more info just let me know. Thanks.
EDIT: Full stack trace
[ERROR] Failed to execute goal org.jboss.ws.plugins:maven-jaxws-tools-plugin:1.0.1.GA:wsconsume (default) on project sso: Error while running wsconsume: Process terminated with code 1 -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.jboss.ws.plugins:maven-jaxws-tools-plugin:1.0.1.GA:wsconsume (default) on project sso: Error while running wsconsume
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
Caused by: org.apache.maven.plugin.MojoExecutionException: Error while running wsconsume
at org.jboss.ws.plugins.tools.AbstractWsConsumeMojo.execute(AbstractWsConsumeMojo.java:157)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
... 19 more
Caused by: java.lang.Exception: Process terminated with code 1
at org.jboss.ws.plugins.tools.WSContractDelegate.runConsumerOutOfProcess(WSContractDelegate.java:133)
at org.jboss.ws.plugins.tools.WSContractDelegate.runConsumer(WSContractDelegate.java:99)
at org.jboss.ws.plugins.tools.AbstractWsConsumeMojo.execute(AbstractWsConsumeMojo.java:149)
... 21 more
Well figured it out anyway. Turns out it was a windows limitation with file names. The file path was too long. As such once I moved it to a folder just below root, eg. C:/folder_here then it worked. Also switched to JDK 1.7 because another problem with windows means that if you use 1.6 you need to download another couple of jars. Anyway hope this helps someone else out.