vertex jar not found exception even after the jar is present - maven

org.vertx.java.platform.PlatformManagerException: Module io.vertx~lang-groovy~2.0.0-final not found in any repositories
at org.vertx.java.platform.impl.DefaultPlatformManager.getModule(DefaultPlatformManager.java:985)
at org.vertx.java.platform.impl.DefaultPlatformManager.doInstallMod(DefaultPlatformManager.java:974)
at org.vertx.java.platform.impl.DefaultPlatformManager.loadIncludedModules(DefaultPlatformManager.java:858)
at org.vertx.java.platform.impl.DefaultPlatformManager.doDeploy(DefaultPlatformManager.java:1219)
at org.vertx.java.platform.impl.DefaultPlatformManager.deployModuleFromModJson(DefaultPlatformManager.java:742)
at org.vertx.java.platform.impl.DefaultPlatformManager.deployModuleFromFileSystem(DefaultPlatformManager.java:812)
at org.vertx.java.platform.impl.DefaultPlatformManager.access$100(DefaultPlatformManager.java:55)
at org.vertx.java.platform.impl.DefaultPlatformManager$1.run(DefaultPlatformManager.java:151)
at org.vertx.java.platform.impl.DefaultPlatformManager$11.run(DefaultPlatformManager.java:359)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)

The issue was io.vertx~lang-groovy~2.0.0-final folder was missing after compiling of project.
It was missing because the vertx was not able to fetch the jar from maven as maven has stopped support to http from january 15 2020.

Related

java.lang.NoClassDefFoundError in firebase admin

I have log4j in spring boot project which uses firebase admin
Randomly firebase admin threw this error even if it is not in use.
Exception in thread "firebase-database-worker" java.lang.NoClassDefFoundError: ch/qos/logback/classic/spi/ThrowableProxy
at ch.qos.logback.classic.spi.LoggingEvent.<init>(LoggingEvent.java:119)
at ch.qos.logback.classic.Logger.buildLoggingEventAndAppend(Logger.java:419)
at ch.qos.logback.classic.Logger.filterAndLog_0_Or3Plus(Logger.java:383)
at ch.qos.logback.classic.Logger.error(Logger.java:538)
at com.google.firebase.database.core.JvmPlatform$1.handleException(JvmPlatform.java:57)
at com.google.firebase.database.utilities.DefaultRunLoop.handleExceptionInternal(DefaultRunLoop.java:102)
at com.google.firebase.database.utilities.DefaultRunLoop.access$000(DefaultRunLoop.java:34)
at com.google.firebase.database.utilities.DefaultRunLoop$1.afterExecute(DefaultRunLoop.java:65)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1157)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
2022-08-13 22:27:22,729 INFO [http-nio-9658-exec-190]
It seems like it needs a different log library, and when I tried to install ch/qos
The project won't work. unless I removed it from the pom.xml
Does anyone have a solution?
i don't want to change my log library as I can't replace firebase now

Zeppelin does not load maven jar

Apache Zeppelin Version 0.7.1
%dep
z.reset() // clean up previously added artifact and repository
// add maven repository
z.addRepo("Spark Cassandra Connector 2.0.10").url("https://mvnrepository.com/artifact/com.datastax.spark/spark-cassandra-connector")
// add artifact recursively
// z.load("groupId:artifactId:version")
z.load("com.datastax.spark:spark-cassandra-connector_2.11:2.0.10")
java.lang.NullPointerException
at org.sonatype.aether.impl.internal.DefaultRepositorySystem.resolveDependencies(DefaultRepositorySystem.java:352)
at org.apache.zeppelin.spark.dep.SparkDependencyContext.fetchArtifactWithDep(SparkDependencyContext.java:171)
at org.apache.zeppelin.spark.dep.SparkDependencyContext.fetch(SparkDependencyContext.java:121)
at org.apache.zeppelin.spark.DepInterpreter.interpret(DepInterpreter.java:245)
at org.apache.zeppelin.interpreter.LazyOpenInterpreter.interpret(LazyOpenInterpreter.java:95)
at org.apache.zeppelin.interpreter.remote.RemoteInterpreterServer$InterpretJob.jobRun(RemoteInterpreterServer.java:490)
at org.apache.zeppelin.scheduler.Job.run(Job.java:175)
at org.apache.zeppelin.scheduler.FIFOScheduler$1.run(FIFOScheduler.java:139)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
The following doesn't seem to be helpful:
apache zeppelin additional repository import
In https://zeppelin.apache.org/docs/0.7.1/interpreter/spark.html, it gives an example of setting zeppelin.dep.additionalRemoteRepository to http://dl.bintray.com/spark-packages/maven, but this repo doesn't have the version of jar I need.
https://zeppelin.apache.org/docs/0.7.1/interpreter/spark.html#3-dynamic-dependency-loading-via-sparkdep-interpreter
Zeppelin dynamic dependency loading fails on os-maven-plugin
Now I'm getting
%dep
z.load("com.datastax.spark:spark-cassandra-connector_2.11:2.0.10")
org.sonatype.aether.resolution.DependencyResolutionException: Could not find artifact com.datastax.spark:spark-cassandra-connector_2.11:jar:2.0.10 in central (https://repo1.maven.org/maven2/)
I need to update the maven reposition url from http to https in zeppelin-env.sh
export ZEPPELIN_INTERPRETER_DEP_MVNREPO="https://repo1.maven.org/maven2/"
There are also other non-generic changes specific to our build system (Jenkins pipeline)
If you have control over the server, it would be much easier to just download the jar you need (i.e. "groupArtifactVersion": "com.datastax.spark:spark-cassandra-connector_2.11:2.0.10",), then load the dependency from disk, like:
%dep
z.load("/opt/zeppelin/spark-cassandra-connector-assembly/spark-cassandra-connector-assembly.jar")

Failed to copy resources: java.nio.file.NoSuchFileException

I'm trying to compile and run my Quarkus servlet application. But it keeps getting the following error with quarkus-maven-plugin 0.24.0 and 0.25.0. But it works fine with quarkus-maven-plugin 0.23.2
ERROR [io.qua.dev] (vert.x-worker-thread-0) Failed to copy resources: java.nio.file.NoSuchFileException: D:\quarkus-sample\rest\target\classes\myproperties.properties
at sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:79)
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:97)
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:102)
at sun.nio.fs.WindowsFileSystemProvider.implDelete(WindowsFileSystemProvider.java:269)
at sun.nio.fs.AbstractFileSystemProvider.delete(AbstractFileSystemProvider.java:103)
at java.nio.file.Files.delete(Files.java:1126)
at io.quarkus.dev.RuntimeUpdatesProcessor.checkForFileChange(RuntimeUpdatesProcessor.java:332)
at io.quarkus.dev.RuntimeUpdatesProcessor.doScan(RuntimeUpdatesProcessor.java:121)
at io.quarkus.vertx.http.deployment.devmode.VertxHotReplacementSetup$1.handle(VertxHotReplacementSetup.java:52)
at io.quarkus.vertx.http.deployment.devmode.VertxHotReplacementSetup$1.handle(VertxHotReplacementSetup.java:44)
at io.vertx.core.impl.ContextImpl.lambda$executeBlocking$2(ContextImpl.java:316)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
at java.lang.Thread.run(Thread.java:748)
If it worked with a previous version, there's a good chance it's a bug.
Could you create a GitHub issue in our tracker and provide a reproducer (simple Quarkus app reproducing the issue) and the steps to reproduce it?
This was fixed by Quarkus release 0.26.0.
Related git hub issue can be found in https://github.com/quarkusio/quarkus/issues/4697

org.gradle.tooling.GradleConnectionException: Could not fetch model of type 'BuildEnvironment'

I am running netbeans with lates version of Gradle on windows and anytime I try to select an old project from the gradle tasks panel I get the following error:
Requested project: D:\ian\libGDX\MarioBros
Stack trace:
org.gradle.tooling.GradleConnectionException: Could not fetch model of type 'BuildEnvironment' using Gradle distribution 'https://services.gradle.org/distributions/gradle-2.10-all.zip'.
at org.gradle.tooling.internal.consumer.ExceptionTransformer.transform(ExceptionTransformer.java:55)
at org.gradle.tooling.internal.consumer.ExceptionTransformer.transform(ExceptionTransformer.java:29)
at org.gradle.tooling.internal.consumer.ResultHandlerAdapter.onFailure(ResultHandlerAdapter.java:41)
at org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor$1$1.run(DefaultAsyncConsumerActionExecutor.java:57)
at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55)
at java.lang.Thread.run(Thread.java:748)
at org.gradle.tooling.internal.consumer.BlockingResultHandler.getResult(BlockingResultHandler.java:46)
at org.gradle.tooling.internal.consumer.DefaultModelBuilder.get(DefaultModelBuilder.java:50)
at org.netbeans.gradle.project.model.DefaultGradleModelLoader.loadModelWithProgress(DefaultGradleModelLoader.java:551)
at org.netbeans.gradle.project.model.DefaultGradleModelLoader.access$1600(DefaultGradleModelLoader.java:64)
at org.netbeans.gradle.project.model.DefaultGradleModelLoader$6.run(DefaultGradleModelLoader.java:419)
at org.netbeans.gradle.project.tasks.GradleDaemonManager.runNonBlockingGradleTask(GradleDaemonManager.java:35)
at org.netbeans.gradle.project.tasks.GradleDaemonManager.access$100(GradleDaemonManager.java:22)
at org.netbeans.gradle.project.tasks.GradleDaemonManager$2.execute(GradleDaemonManager.java:125)
at org.jtrim.concurrent.AbstractTaskExecutorService$FunctionWrapper.execute(AbstractTaskExecutorService.java:270)
at org.jtrim.concurrent.AbstractTaskExecutorService$TaskOfAbstractExecutor.execute(AbstractTaskExecutorService.java:340)
at org.jtrim.concurrent.Tasks$RunOnceCancelableTask.execute(Tasks.java:342)
at org.jtrim.concurrent.SingleThreadedExecutor$QueuedItem.runTask(SingleThreadedExecutor.java:919)
at org.jtrim.concurrent.SingleThreadedExecutor$QueuedItem.access$1200(SingleThreadedExecutor.java:898)
at org.jtrim.concurrent.SingleThreadedExecutor$Impl$Worker.executeTask(SingleThreadedExecutor.java:815)
at org.jtrim.concurrent.SingleThreadedExecutor$Impl$Worker.processQueue(SingleThreadedExecutor.java:827)
at org.jtrim.concurrent.SingleThreadedExecutor$Impl$Worker.run(SingleThreadedExecutor.java:861)
at org.jtrim.concurrent.SingleThreadedExecutor$Impl$1.run(SingleThreadedExecutor.java:453)
at java.lang.Thread.run(Thread.java:748)
Caused by: org.gradle.api.GradleException: Java home supplied via 'org.gradle.java.home' is invalid. Invalid directory: C:\Program Files\Java\jdk1.8.0_92
at org.gradle.launcher.cli.converter.PropertiesToDaemonParametersConverter.convert(PropertiesToDaemonParametersConverter.java:51)
at org.gradle.tooling.internal.provider.ProviderConnection.initParams(ProviderConnection.java:172)
at org.gradle.tooling.internal.provider.ProviderConnection.run(ProviderConnection.java:91)
at org.gradle.tooling.internal.provider.DefaultConnection.getModel(DefaultConnection.java:168)
at org.gradle.tooling.internal.consumer.connection.CancellableModelBuilderBackedModelProducer.produceModel(CancellableModelBuilderBackedModelProducer.java:53)
at org.gradle.tooling.internal.consumer.connection.PluginClasspathInjectionSupportedCheckModelProducer.produceModel(PluginClasspathInjectionSupportedCheckModelProducer.java:41)
at org.gradle.tooling.internal.consumer.connection.AbstractConsumerConnection.run(AbstractConsumerConnection.java:58)
at org.gradle.tooling.internal.consumer.connection.ParameterValidatingConsumerConnection.run(ParameterValidatingConsumerConnection.java:46)
at org.gradle.tooling.internal.consumer.DefaultModelBuilder$1.run(DefaultModelBuilder.java:60)
at org.gradle.tooling.internal.consumer.connection.LazyConsumerActionExecutor.run(LazyConsumerActionExecutor.java:84)
at org.gradle.tooling.internal.consumer.connection.CancellableConsumerActionExecutor.run(CancellableConsumerActionExecutor.java:45)
at org.gradle.tooling.internal.consumer.connection.ProgressLoggingConsumerActionExecutor.run(ProgressLoggingConsumerActionExecutor.java:58)
at org.gradle.tooling.internal.consumer.connection.RethrowingErrorsConsumerActionExecutor.run(RethrowingErrorsConsumerActionExecutor.java:38)
at org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor$1$1.run(DefaultAsyncConsumerActionExecutor.java:55)
at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55)
... 1 more
Has anyone else run into this error? And How to fix the problem?
Actually the issue is described here already
Caused by: org.gradle.api.GradleException: Java home supplied via 'org.gradle.java.home' is invalid. Invalid directory: C:\Program Files\Java\jdk1.8.0_92
If you go to your gradle.properties configuration file, you will get the following
org.gradle.java.home=C:\Program Files\Java\jdk1.8.0_92
You can remove it or give the original JAVA_HOME location. Hope it will solve your issue.
N.B: If your path is OK, then use double backslashes "\" like above in your path.
Wrong jdk version in %userprofile%\.gradle\gradle.properties caused the issue in my case. Another option to try is hardcode the java home path directly in gradle_dir/bin/gradle.bat like so:
set JAVA_HOME="c:\Program Files\Java\jdk1.8.0_251"
This is probably an proxy issue, try creating %userprofile%\.gradle\gradle.properties or ~/.gradle/gradle.properties containing the following :
systemProp.http.proxyHost=[host]
systemProp.http.proxyPort=[port]
systemProp.http.proxyUser=[user]
systemProp.http.proxyPassword=[pass]
systemProp.https.proxyHost=
systemProp.https.proxyPort=
systemProp.https.proxyUser=
systemProp.https.proxyPassword=
systemProp.http.nonProxyHosts=localhost|orther.domain.tld

Unable to find data for class 'org/springframework/boot/context/web/SpringBootServletInitializer'

I am getting this strange error while trying to start Spring Boot application in Servlet container.
The same WAR starts normally in standalone Tomcat server, but gives the error seen below if started using Gretty Gradle plugin
Any ideas that it means?
Spring-boot 1.3.3, Gradle 2.12, Gretty 1.2.4, Tomcat 8
java.lang.RuntimeException: Reloading agent exited via exception, please raise a jira
at org.springsource.loaded.agent.ClassPreProcessorAgentAdapter.transform(ClassPreProcessorAgentAdapter.java:104)
at sun.instrument.TransformerManager.transform(TransformerManager.java:188)
at sun.instrument.InstrumentationImpl.transform(InstrumentationImpl.java:428)
...
at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:305)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5066)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1399)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.springsource.loaded.UnableToLoadClassException: Unable to find data for class 'org/springframework/boot/context/web/SpringBootServletInitializer'
at org.springsource.loaded.Utils.loadSlashedClassAsBytes(Utils.java:787)
at org.springsource.loaded.TypeRegistry.getDescriptorFor(TypeRegistry.java:311)
at org.springsource.loaded.TypeDescriptorExtractor$ExtractionVisitor.getTypeDescriptorFor(TypeDescriptorExtractor.java:124)
at org.springsource.loaded.TypeDescriptorExtractor$ExtractionVisitor.findTypeDescriptor(TypeDescriptorExtractor.java:140)
at org.springsource.loaded.TypeDescriptorExtractor$ExtractionVisitor.walkHierarchyForCatchersAndSuperDispatchers(TypeDescriptorExtractor.java:152)
at org.springsource.loaded.TypeDescriptorExtractor$ExtractionVisitor.computeCatchersAndSuperdispatchers(TypeDescriptorExtractor.java:219)
at org.springsource.loaded.TypeDescriptorExtractor$ExtractionVisitor.getTypeDescriptor(TypeDescriptorExtractor.java:81)
at org.sprce.loaded.TypeDescriptorExtractor.extract(TypeDescriptorExtractor.java:51)
at org.springsource.loaded.TypeRegistry.addType(TypeRegistry.java:912)
at org.springsource.loaded.agent.SpringLoadedPreProcessor.preProcess(SpringLoadedPreProcessor.java:302)
at org.springsource.loaded.agent.ClassPreProcessorAgentAdapter.transform(ClassPreProcessorAgentAdapter.java:102)
... 42 more
Apparently there is a bug in Gretty related to classloading.
Starting Gretty with WAR e.g. gradlew appRunWar allows to work around it.
There are multiple bugs opened for it:
https://github.com/akhikhl/gretty/issues/199
https://github.com/akhikhl/gretty/issues/209
https://github.com/akhikhl/gretty/issues/148

Resources