Skip to main content

Questions tagged [classloader]

A class loader is an object that is responsible for loading classes in Java.

0 votes
0 answers
48 views

JMX metrics problem with spring-boot-starter-quartz and class loader

I'm running a spring boot (3.3.0) app with a simple quartz job configured with an mssql database (2017). All works correctly. The app exposes quartz jmx metrics with the property spring.quartz....
Enzo Terranova's user avatar
0 votes
0 answers
16 views

How to set flatclasspath in QuarkusTest

I have problems with classloading in QuarkusTests which could be solved if I could set the existing boolean property flatclasspath in QuarkusBootstrap.Builder. I tested this by setting it during ...
aschoerk's user avatar
  • 3,553
0 votes
0 answers
92 views

Why debugging leads to MetaSpace memory leak in Java?

Debugging a class loaded by a ClassLoader created by a user will cause the class to be referenced by JNI global, and the ClassLoader cannot be uninstalled. Repeating this operation for many times will ...
kyle wang's user avatar
1 vote
0 answers
107 views

How do I make my webapp classes available to a jar on Jetty's classpath? (Jetty 10+)

My webapp is a WAR file deployed on Jetty 10. I want to use Java SPI to define an interface that end users can implement. The idea is that end users can implement the interface and put a jar in Jetty'...
Scott Ellis's user avatar
0 votes
1 answer
72 views

Loading Singleton Instance of a Class using Java ServiceLoader

I have an Interface in my project. End users can implement this interface and can create their concrete implementations. All the users have been advised to follow singleton design pattern while ...
booyaakaashaa's user avatar
0 votes
1 answer
44 views

How to configure Embedded Tomcat such that the classloader will find classes in CATALINA_HOME/lib

I have an issue with embedded Tomcat and classloaders. I have a java servlet application that runs in an embedded Tomcat(9.0.70) instance. When the application is packaged into a single war file – the ...
Dave Breeze's user avatar
0 votes
1 answer
59 views

Unexpected `NoClassDefFoundError` when optional library is not on classpath, but related code is not executed

I am trying to use the Google Closure Compiler from Java code, but want it to be an optional dependency (present at build time, but may not be around when deployed). The problem I'm having is that I'm ...
Patrick Ziegler's user avatar
0 votes
0 answers
23 views

does monkey patching still works in android gradle

So I read this post on the monkey patching in Android, and seems quite an interesting approach to fix AGP bugs before they get fixed, but when I try to use the approach by creating a class in the ...
max's user avatar
  • 6,127
1 vote
1 answer
60 views

JavaFX+mybatis+sqlite Could not find resource mapper/UserMapper.xml

When I create a sample-demo use JavaFX+mybatis+sqlite Could not find resource mapper/UserMapper.xml when I create the folder 'mapper' in 'src/main/resources/', when I debug in Resources....
qcrrm's user avatar
  • 11
0 votes
0 answers
48 views

Does Java Class Data Sharing (CDS) also archive classes in the "classpath"?

We are working on an application that runs the following java command: java -classpath "C:/dir/sample1.jar; C:/dir/sample2.jar" example.class I loaded classes to LoadedClasses.lst: java -...
Jeffrey Pham's user avatar
0 votes
0 answers
27 views

In GlassFish3, How can I "override" internal library, or give preference to app library?

In GlassFish3, my web application 'sfeaapp' uses a library 'jaxrs-api-3.0.10.Final.jar' located in '/var/opt/GlassFish3/domains/sfeaapp/lib/ext/jaxrs-api-3.0.10.Final.jar', which conflicts with ...
JLLMNCHR's user avatar
  • 1,571
-1 votes
1 answer
64 views

How do I solve this Tomcat class loading issue?

I have three Webapps on my Tomcat server. I use ActiveMQ to send messages between them. This has worked but now I'm trying to update from 5.14 to 5.18 and I'm running in to a class loading issue. To ...
Mathias's user avatar
  • 3,921
0 votes
0 answers
36 views

Conflicts between WAR file and tomcat lib causing webapp unable to startup due to java.lang.VerifyError: Bad return type

I came across a problems which is causing my spring webapp unable to start up, the error that showing is java.lang.VerifyError: Bad return type , which org/springframework/http/converter/json/...
Lucas K's user avatar
0 votes
0 answers
126 views

Invalid value io.confluent.kafka.serializers.context.NullContextNameStrategy during runtime when producing a Kafka event using schema registry

I get the following error message during runtime, every time a Kafka event is generated in my production environment. Please note that the same code works in my local setup without any issues and all ...
bilalchetaba's user avatar
0 votes
1 answer
61 views

Load dependency class in sbt task

I want to run embedded kafka before all IT test as Tests.Setup from scala object. So, I have something like Test / testOptions += Tests.Setup { loader => loader.loadClass("io.github....
skilgal's user avatar
  • 174

15 30 50 per page
1
2 3 4 5
277