groovy-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gerald Wiltse <>
Subject Classloader Won't Load Some Classes
Date Tue, 19 Apr 2016 02:01:55 GMT
I have a bunch of classes in different packages called "Datasources" which
are all very similar. They extend an abstract base class, they have quite a
few dependencies and implement some traits.  They also use
@InheritConstructors annotation.

I am unable to load any of them using newInstance() :

import com.gsi.monitor.loader.CustomLoader
URLClassLoader loader = CustomLoader.getCustomLoader("master")
Datasource dsi =
println dsi.output

Error:    unable to resolve class Datasource

What I find interesting, is that several other classes load as expected,
and that the error is "unable to resolve".   The other classes I've tested
are simpler classes, so I'm wondering what it is about the "Datasource"
classes that us causing them to fail.  Could it be the annotations, or
dependencies, etc?

Note: These are running inside the script engine of Logicmonitor monitoring
platform.   It has groovy-all-2.3.0 library.

Any ideas?

Gerald R. Wiltse

View raw message