groovy-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Blake McBride <blake1...@gmail.com>
Subject Re: Class not found errors on 2.5.9
Date Wed, 05 Feb 2020 23:01:31 GMT
Greetings,

All of the code is at https://github.com/blakemcbride/Kiss/
It runs as-is.  If I just change Groovy from 2.4.15 to 2.5.9 I get the
following when I run it with: ./gradlew tomcatRun

$ ./gradlew clean

BUILD SUCCESSFUL in 1s
1 actionable task: 1 executed
$ ./gradlew tomcatRun
16:45:28 INFO  Configuring / with
file:/home/blake/intellijProjects/Kiss/build/inplaceWebapp/META-INF/context.xml
Feb 05, 2020 4:45:29 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-nio-8080"]
Feb 05, 2020 4:45:29 PM org.apache.tomcat.util.net.NioSelectorPool
getSharedSelector
INFO: Using a shared selector for servlet write/read
Feb 05, 2020 4:45:29 PM org.apache.catalina.core.StandardService
startInternal
INFO: Starting service Tomcat
Feb 05, 2020 4:45:29 PM org.apache.catalina.core.StandardEngine
startInternal
INFO: Starting Servlet Engine: Apache Tomcat/8.0.51
Feb 05, 2020 4:45:29 PM org.apache.catalina.startup.ContextConfig
getDefaultWebXmlFragment
INFO: No global web.xml found
Feb 05, 2020 4:45:32 PM org.apache.jasper.servlet.TldScanner scanJars
INFO: At least one JAR was scanned for TLDs yet contained no TLDs. Enable
debug logging for this logger for a complete list of JARs that were scanned
but no TLDs were found in them. Skipping unneeded JARs during scanning can
improve startup time and JSP compilation time.
Feb 05, 2020 4:45:32 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-nio-8080"]
16:45:32 INFO  Tomcat 8.0.51 started and listening on port 8080
16:45:32 INFO   runs at:
16:45:32 INFO    http://localhost:8080

> Task :tomcatRun
Press any key to stop the server.

* * * Context path = /home/blake/intellijProjects/Kiss/build/inplaceWebapp/
* * * Is running with source
* * * Application path set to
/home/blake/intellijProjects/Kiss/src/main/application/
Feb 05, 2020 4:45:44 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet [org.kissweb.rest.MainServlet] in
context with path [] threw exception [Servlet execution threw an exception]
with root cause
java.lang.NoSuchMethodError:
org.apache.groovy.util.SystemUtil.getSystemPropertySafe(Ljava/lang/String;)Ljava/lang/String;
        at
org.codehaus.groovy.control.CompilerConfiguration.<init>(CompilerConfiguration.java:411)
        at
org.codehaus.groovy.control.CompilerConfiguration$1.<init>(CompilerConfiguration.java:122)
        at
org.codehaus.groovy.control.CompilerConfiguration.<clinit>(CompilerConfiguration.java:122)
        at groovy.lang.GroovyClassLoader.<init>(GroovyClassLoader.java:160)
        at groovy.lang.GroovyClassLoader.<init>(GroovyClassLoader.java:184)
        at groovy.lang.GroovyClassLoader.<init>(GroovyClassLoader.java:140)
        at org.kissweb.rest.GroovyClass.<init>(GroovyClass.java:54)
        at
org.kissweb.rest.GroovyService.loadGroovyClass(GroovyService.java:155)
        at
org.kissweb.rest.GroovyService.internalGroovy(GroovyService.java:41)
        at
org.kissweb.rest.MainServlet.initializeSystem(MainServlet.java:70)
        at org.kissweb.rest.MainServlet.doPost(MainServlet.java:51)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:292)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at
org.apache.catalina.filters.CorsFilter.handleNonCORS(CorsFilter.java:458)
        at
org.apache.catalina.filters.CorsFilter.doFilter(CorsFilter.java:177)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212)
        at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:94)
        at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:608)
        at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:141)
        at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
        at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
        at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:502)
        at
org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1132)
        at
org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:684)
        at
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1539)
        at
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1495)
        at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at
org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:748)

* * * Context path = /home/blake/intellijProjects/Kiss/build/inplaceWebapp/
* * * Is running with source
* * * Application path set to
/home/blake/intellijProjects/Kiss/src/main/application/
Feb 05, 2020 4:45:44 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet [org.kissweb.rest.MainServlet] in
context with path [] threw exception [Servlet execution threw an exception]
with root cause
java.lang.NoClassDefFoundError: Could not initialize class
org.codehaus.groovy.control.CompilerConfiguration
        at groovy.lang.GroovyClassLoader.<init>(GroovyClassLoader.java:160)
        at groovy.lang.GroovyClassLoader.<init>(GroovyClassLoader.java:184)
        at groovy.lang.GroovyClassLoader.<init>(GroovyClassLoader.java:140)
        at org.kissweb.rest.GroovyClass.<init>(GroovyClass.java:54)
        at
org.kissweb.rest.GroovyService.loadGroovyClass(GroovyService.java:155)
        at
org.kissweb.rest.GroovyService.internalGroovy(GroovyService.java:41)
        at
org.kissweb.rest.MainServlet.initializeSystem(MainServlet.java:70)
        at org.kissweb.rest.MainServlet.doPost(MainServlet.java:51)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:292)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at
org.apache.catalina.filters.CorsFilter.handleNonCORS(CorsFilter.java:458)
        at
org.apache.catalina.filters.CorsFilter.doFilter(CorsFilter.java:177)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212)
        at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:94)
        at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:608)
        at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:141)
        at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
        at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
        at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:502)
        at
org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1132)
        at
org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:684)
        at
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1539)
        at
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1495)
        at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at
org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:748)

* * * Context path = /home/blake/intellijProjects/Kiss/build/inplaceWebapp/
* * * Is running with source
* * * Application path set to
/home/blake/intellijProjects/Kiss/src/main/application/
Feb 05, 2020 4:45:44 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet [org.kissweb.rest.MainServlet] in
context with path [] threw exception [Servlet execution threw an exception]
with root cause
java.lang.NoClassDefFoundError: Could not initialize class
org.codehaus.groovy.control.CompilerConfiguration
        at groovy.lang.GroovyClassLoader.<init>(GroovyClassLoader.java:160)
        at groovy.lang.GroovyClassLoader.<init>(GroovyClassLoader.java:184)
        at groovy.lang.GroovyClassLoader.<init>(GroovyClassLoader.java:140)
        at org.kissweb.rest.GroovyClass.<init>(GroovyClass.java:54)
        at
org.kissweb.rest.GroovyService.loadGroovyClass(GroovyService.java:155)
        at
org.kissweb.rest.GroovyService.internalGroovy(GroovyService.java:41)
        at
org.kissweb.rest.MainServlet.initializeSystem(MainServlet.java:70)
        at org.kissweb.rest.MainServlet.doPost(MainServlet.java:51)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:292)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at
org.apache.catalina.filters.CorsFilter.handleNonCORS(CorsFilter.java:458)
        at
org.apache.catalina.filters.CorsFilter.doFilter(CorsFilter.java:177)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212)
        at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:94)
        at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:608)
        at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:141)
        at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
        at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
        at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:502)
        at
org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1132)
        at
org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:684)
        at
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1539)
        at
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1495)
        at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at
org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:748)

<===========--> 87% EXECUTING [13m 12<===========--> 87% EXECUTING [13m 57s]
> IDLE
> IDLE
> IDLE
> IDLE
> IDLE
> :tomcatRun                         > :tomcatRun
> IDLE
> IDLE



On Wed, Feb 5, 2020 at 4:31 PM Paul King <paulk@asert.com.au> wrote:

> Also, we would be interested in your classpath. It might be that both 2.4
> and 2.5 jars are on the classpath somehow. Doesn't appear to be the case in
> the scan but depends on how the tomcatRun task is defined I guess as to
> where its classpath is set up.
>
> On Thu, Feb 6, 2020 at 8:28 AM Paul King <paulk@asert.com.au> wrote:
>
>>
>> Hi Blake,
>>
>> Do you have a stack trace? That's really what we were after in the scan,
>> but may not be possible to get via that means in your case.
>>
>> Thanks, Paul.
>>
>>
>> On Thu, Feb 6, 2020 at 5:58 AM Blake McBride <blake1024@gmail.com> wrote:
>>
>>> Yes but as I said initially, when I run:  gradle tomcatRun
>>> I get:
>>>
>>> java.lang.NoSuchMethodError:
>>> org.apache.groovy.util.SystemUtil.getSystemPropertySafe(Ljava/lang/String;)Ljava/lang/String;
>>>
>>> java.lang.NoClassDefFoundError: Could not initialize class
>>> org.codehaus.groovy.control.CompilerConfiguration
>>>
>>> The system ran and runs fine until I update Groovy.
>>>
>>> Thanks.
>>>
>>> Blake
>>>
>>>
>>> On Sun, Feb 2, 2020 at 3:48 AM Daniel.Sun <sunlan@apache.org> wrote:
>>>
>>>> Hi Blake,
>>>>
>>>>      The build is *SUCCESSFUL*...
>>>>
>>>> https://scans.gradle.com/s/yxiyvmlpnq5ui/console-log?anchor=13
>>>> ```
>>>> :compileJava UP-TO-DATE
>>>> :processResources NO-SOURCE
>>>> :classes UP-TO-DATE
>>>> :war
>>>> :assemble
>>>> :compileTestJava NO-SOURCE
>>>> :processTestResources NO-SOURCE
>>>> :testClasses UP-TO-DATE
>>>> :test NO-SOURCE
>>>> :check UP-TO-DATE
>>>> :build
>>>> BUILD SUCCESSFUL in 16s
>>>> 2 actionable tasks: 1 executed, 1 up-to-date
>>>> ```
>>>>
>>>> Cheers,
>>>> Daniel.Sun
>>>>
>>>>
>>>>
>>>> -----
>>>> Apache Groovy committer & PMC member
>>>> Blog: http://blog.sunlan.me
>>>> Twitter: @daniel_sun
>>>>
>>>> --
>>>> Sent from: http://groovy.329449.n5.nabble.com/Groovy-Users-f329450.html
>>>>
>>>

Mime
View raw message