"Unknown error" with cypher query on all relations - java

Using neo4j 2.0.1 I frequently observe Java heap space problems. For example when trying to delete all relations of one type I only get an "unknown error".
I'm running neo4j server on my local machine (kubuntu 13.10) with 8 gig ram, 6gig java heap space. the same happens when performing the query on a virtual ubuntu server.
did not observe these issues with previous versions.
I also attached the neo4j output from the console. I'm not a java developer, so it does not really help me.
thanks for suggestions
Starting Neo4j Server console-mode...
Using additional JVM arguments: -server -XX:+DisableExplicitGC -Dorg.neo4j.server.properties=conf/neo4j-server.properties -Djava.util.logging.config.file=conf/logging.properties -Dlog4j.configuration=file:conf/log4j.properties -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -Xms512m -Xmx6196m
Detected incorrectly shut down database, performing recovery..
13:50:00.431 [main] WARN o.e.j.server.handler.ContextHandler - o.e.j.s.ServletContextHandler#35f6002a{/,null,null} contextPath ends with /
13:50:00.431 [main] WARN o.e.j.server.handler.ContextHandler - Empty contextPath
13:50:00.433 [main] INFO org.eclipse.jetty.server.Server - jetty-9.0.5.v20130815
13:50:00.458 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.s.h.MovedContextHandler#453831c{/,null,AVAILABLE}
13:50:00.534 [main] INFO o.e.j.w.StandardDescriptorProcessor - NO JSP Support for /webadmin, did not find org.apache.jasper.servlet.JspServlet
13:50:00.546 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.w.WebAppContext#3c3aea35{/webadmin,jar:file:/media/data/software/Neo4j/system/lib/neo4j-server-2.0.1-static-web.jar!/webadmin-html,AVAILABLE}
13:50:00.950 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler#2078afe{/db/manage,null,AVAILABLE}
13:50:01.206 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler#216e21b4{/db/data,null,AVAILABLE}
13:50:01.224 [main] INFO o.e.j.w.StandardDescriptorProcessor - NO JSP Support for /browser, did not find org.apache.jasper.servlet.JspServlet
13:50:01.225 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.w.WebAppContext#513f27b6{/browser,jar:file:/media/data/software/Neo4j/system/lib/neo4j-browser-2.0.1.jar!/browser,AVAILABLE}
13:50:01.314 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler#35f6002a{/,null,AVAILABLE}
13:50:01.327 [main] INFO o.e.jetty.server.ServerConnector - Started ServerConnector#42f400c3{HTTP/1.1}{localhost:7474}
13:50:01.756 [main] INFO o.e.jetty.server.ServerConnector - Started ServerConnector#40671ba6{SSL-HTTP/1.1}{localhost:7473}
13:50:02.380 [Thread-24] INFO o.e.jetty.server.ServerConnector - Stopped ServerConnector#42f400c3{HTTP/1.1}{localhost:7474}
13:50:02.384 [Thread-24] INFO o.e.jetty.server.ServerConnector - Stopped ServerConnector#40671ba6{SSL-HTTP/1.1}{localhost:7473}
13:50:02.385 [Thread-24] INFO o.e.j.server.handler.ContextHandler - Stopped o.e.j.s.ServletContextHandler#35f6002a{/,null,UNAVAILABLE}
13:50:02.386 [Thread-24] INFO o.e.j.server.handler.ContextHandler - Stopped o.e.j.w.WebAppContext#513f27b6{/browser,jar:file:/media/data/software/Neo4j/system/lib/neo4j-browser-2.0.1.jar!/browser,UNAVAILABLE}
13:50:02.387 [Thread-24] INFO o.e.j.server.handler.ContextHandler - Stopped o.e.j.s.ServletContextHandler#216e21b4{/db/data,null,UNAVAILABLE}
13:50:02.387 [Thread-24] INFO o.e.j.server.handler.ContextHandler - Stopped o.e.j.s.ServletContextHandler#2078afe{/db/manage,null,UNAVAILABLE}
13:50:02.388 [Thread-24] INFO o.e.j.server.handler.ContextHandler - Stopped o.e.j.w.WebAppContext#3c3aea35{/webadmin,jar:file:/media/data/software/Neo4j/system/lib/neo4j-server-2.0.1-static-web.jar!/webadmin-html,UNAVAILABLE}
13:50:02.388 [Thread-24] INFO o.e.j.server.handler.ContextHandler - Stopped o.e.j.s.h.MovedContextHandler#453831c{/,null,UNAVAILABLE}
Starting Neo4j Server console-mode...
Using additional JVM arguments: -server -XX:+DisableExplicitGC -Dorg.neo4j.server.properties=conf/neo4j-server.properties -Djava.util.logging.config.file=conf/logging.properties -Dlog4j.configuration=file:conf/log4j.properties -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -Xms512m -Xmx6196m
13:50:11.228 [main] WARN o.e.j.server.handler.ContextHandler - o.e.j.s.ServletContextHandler#21b4406c{/,null,null} contextPath ends with /
13:50:11.228 [main] WARN o.e.j.server.handler.ContextHandler - Empty contextPath
13:50:11.230 [main] INFO org.eclipse.jetty.server.Server - jetty-9.0.5.v20130815
13:50:11.256 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.s.h.MovedContextHandler#13b357fd{/,null,AVAILABLE}
13:50:11.346 [main] INFO o.e.j.w.StandardDescriptorProcessor - NO JSP Support for /webadmin, did not find org.apache.jasper.servlet.JspServlet
13:50:11.358 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.w.WebAppContext#24c13894{/webadmin,jar:file:/media/data/software/Neo4j/system/lib/neo4j-server-2.0.1-static-web.jar!/webadmin-html,AVAILABLE}
13:50:11.813 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler#66d51e79{/db/manage,null,AVAILABLE}
13:50:12.108 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler#4984bbd4{/db/data,null,AVAILABLE}
13:50:12.129 [main] INFO o.e.j.w.StandardDescriptorProcessor - NO JSP Support for /browser, did not find org.apache.jasper.servlet.JspServlet
13:50:12.131 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.w.WebAppContext#3f30e292{/browser,jar:file:/media/data/software/Neo4j/system/lib/neo4j-browser-2.0.1.jar!/browser,AVAILABLE}
13:50:12.241 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler#21b4406c{/,null,AVAILABLE}
13:50:12.258 [main] INFO o.e.jetty.server.ServerConnector - Started ServerConnector#7ad78ab8{HTTP/1.1}{localhost:7474}
13:50:12.708 [main] INFO o.e.jetty.server.ServerConnector - Started ServerConnector#3f9c4b9a{SSL-HTTP/1.1}{localhost:7473}
13:54:42.617 [qtp808144526-41] WARN o.e.jetty.servlet.ServletHandler - /db/manage/server/monitor/fetch
javax.ws.rs.WebApplicationException: javax.ws.rs.WebApplicationException: org.eclipse.jetty.io.EofException
at org.neo4j.server.rest.repr.OutputFormat$1.write(OutputFormat.java:174) ~[neo4j-server-2.0.1.jar:2.0.1]
at com.sun.jersey.core.impl.provider.entity.StreamingOutputProvider.writeTo(StreamingOutputProvider.java:71) ~[jersey-core-1.9.jar:1.9]
at com.sun.jersey.core.impl.provider.entity.StreamingOutputProvider.writeTo(StreamingOutputProvider.java:57) ~[jersey-core-1.9.jar:1.9]
at com.sun.jersey.spi.container.ContainerResponse.write(ContainerResponse.java:306) ~[jersey-server-1.9.jar:1.9]
at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1437) ~[jersey-server-1.9.jar:1.9]
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1349) ~[jersey-server-1.9.jar:1.9]
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1339) ~[jersey-server-1.9.jar:1.9]
at com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:416) ~[jersey-server-1.9.jar:1.9]
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:537) ~[jersey-server-1.9.jar:1.9]
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:699) ~[jersey-server-1.9.jar:1.9]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848) ~[javax.servlet-3.0.0.v201112011016.jar:na]
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:698) ~[jetty-servlet-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1506) ~[jetty-servlet-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.neo4j.server.rest.security.SecurityFilter.doFilter(SecurityFilter.java:112) ~[neo4j-server-2.0.1.jar:2.0.1]
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1477) ~[jetty-servlet-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:503) [jetty-servlet-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:211) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1096) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:432) [jetty-servlet-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:175) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1030) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:136) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:52) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.Server.handle(Server.java:445) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:268) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:229) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.run(AbstractConnection.java:358) [jetty-io-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:601) [jetty-util-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:532) [jetty-util-9.0.5.v20130815.jar:9.0.5.v20130815]
at java.lang.Thread.run(Thread.java:744) [na:1.7.0_51]
Caused by: javax.ws.rs.WebApplicationException: org.eclipse.jetty.io.EofException
at org.neo4j.server.rest.repr.formats.StreamingJsonFormat$StreamingRepresentationFormat.flush(StreamingJsonFormat.java:401) ~[neo4j-server-2.0.1.jar:2.0.1]
at org.neo4j.server.rest.repr.formats.StreamingJsonFormat$StreamingRepresentationFormat.complete(StreamingJsonFormat.java:389) ~[neo4j-server-2.0.1.jar:2.0.1]
at org.neo4j.server.rest.repr.MappingRepresentation.serialize(MappingRepresentation.java:43) ~[server-api-2.0.1.jar:2.0.1]
at org.neo4j.server.rest.repr.OutputFormat$1.write(OutputFormat.java:160) ~[neo4j-server-2.0.1.jar:2.0.1]
... 30 common frames omitted
Caused by: org.eclipse.jetty.io.EofException: null
at org.eclipse.jetty.io.ChannelEndPoint.flush(ChannelEndPoint.java:186) ~[jetty-io-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.io.WriteFlusher.write(WriteFlusher.java:335) ~[jetty-io-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.io.AbstractEndPoint.write(AbstractEndPoint.java:125) ~[jetty-io-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.HttpConnection$ContentCallback.process(HttpConnection.java:784) ~[jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.util.IteratingCallback.iterate(IteratingCallback.java:79) ~[jetty-util-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.HttpConnection.send(HttpConnection.java:356) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.HttpChannel.sendResponse(HttpChannel.java:631) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.HttpChannel.write(HttpChannel.java:661) [jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at org.eclipse.jetty.server.HttpOutput.flush(HttpOutput.java:151) ~[jetty-server-9.0.5.v20130815.jar:9.0.5.v20130815]
at com.sun.jersey.spi.container.servlet.WebComponent$Writer.flush(WebComponent.java:315) ~[jersey-server-1.9.jar:1.9]
at com.sun.jersey.spi.container.ContainerResponse$CommittingOutputStream.flush(ContainerResponse.java:145) ~[jersey-server-1.9.jar:1.9]
at org.codehaus.jackson.impl.Utf8Generator.flush(Utf8Generator.java:1091) ~[jackson-core-asl-1.9.7.jar:1.9.7]
at org.neo4j.server.rest.repr.formats.StreamingJsonFormat$StreamingRepresentationFormat.flush(StreamingJsonFormat.java:397) ~[neo4j-server-2.0.1.jar:2.0.1]
... 33 common frames omitted

That is unrelated to your config, the transaction size just gets too big.
If you want to delete elements in a batched way use something like this:
match (a)
with a
limit 10000
optional match (a)-[r]-()
delete a,r
return count(*)
run until the result is 0
Which will find at most 10000 nodes then find all their rels and then delete both.

Related

Spring Boot directly throws "java.lang.OutOfMemoryError: unable to create new native thread" after starting the application

I am running a SpringBoot-Application on my Strato V-Server (https://www.strato.de/server/linux-vserver/ => V-Server Linux V10 with 8GB RAM).
Whenn I start the Application I directly get the error mentioned in the Title.
I have two task executors:
#Configuration
public class AsynchronousSpringEventsConfig {
#Bean(name = "applicationEventMulticaster")
public ApplicationEventMulticaster simpleApplicationEventMulticaster() {
SimpleApplicationEventMulticaster eventMulticaster =
new SimpleApplicationEventMulticaster();
ThreadPoolTaskExecutor threadPoolTaskExecutor
= new ThreadPoolTaskExecutor();
threadPoolTaskExecutor.setThreadNamePrefix(
"AsyncThreadPoolTaskExecutor");
threadPoolTaskExecutor.setCorePoolSize(25);
threadPoolTaskExecutor.setMaxPoolSize(50);
threadPoolTaskExecutor.afterPropertiesSet();
eventMulticaster.setTaskExecutor(threadPoolTaskExecutor);
return eventMulticaster;
}
}
and:
#Bean(name = "gaxThreadPoolTaskExecutor")
public ThreadPoolTaskExecutor threadPoolTaskExecutor() {
ThreadPoolTaskExecutor threadPoolTaskExecutor
= new ThreadPoolTaskExecutor();
threadPoolTaskExecutor.setMaxPoolSize(10);
threadPoolTaskExecutor.setCorePoolSize(5);
threadPoolTaskExecutor.setThreadNamePrefix(
"MainThreadPoolTaskExecutor");
return threadPoolTaskExecutor;
}
when I remove the CorePoolSize and the MaxPoolSize from both everthings running fine. But I originally wanted to have the MaxPoolSize for the first one set to 100 and for the second as it is above.
Has somebody an idea how to fix it? Do you need more Information?
EDIT
I am running the following java version on the server:
openjdk version "1.8.0_265"
OpenJDK Runtime Environment (build 1.8.0_265-8u265-b01-0ubuntu2~18.04-b01)
OpenJDK 64-Bit Server VM (build 25.265-b01, mixed mode)
and the following command I use to start the spring application:
/usr/bin/java -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=6006 -Xms4096m -Xmx4096m -Dcom.sun.management.jmxremote.port=3333 -Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false -jar gaxify.jar
The Log/Stacktrace when the error occurs:
2021-01-03 13:48:17,959 INFO org.springframework.boot.StartupInfoLogger [main] Starting Application v1.0-SNAPSHOT on stratoserver.net with PID 4828 (/home/gaxify/gaxify.jar started by root in /home/gaxify)
2021-01-03 13:48:18,016 INFO org.springframework.boot.SpringApplication [main] No active profile set, falling back to default profiles: default
2021-01-03 13:48:19,827 INFO org.springframework.data.repository.config.RepositoryConfigurationDelegate [main] Bootstrapping Spring Data repositories in DEFAULT mode.
2021-01-03 13:48:20,020 INFO org.springframework.data.repository.config.RepositoryConfigurationDelegate [main] Finished Spring Data repository scanning in 179ms. Found 9 repository interfaces.
2021-01-03 13:48:20,796 INFO org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker [main] Bean 'org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration' of type [org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2021-01-03 13:48:20,862 INFO org.springframework.scheduling.concurrent.ExecutorConfigurationSupport [main] Initializing ExecutorService
2021-01-03 13:48:21,411 INFO org.springframework.boot.web.embedded.tomcat.TomcatWebServer [main] Tomcat initialized with port(s): 8080 (http)
2021-01-03 13:48:21,428 INFO org.apache.juli.logging.DirectJDKLog [main] Initializing ProtocolHandler ["http-nio-8080"]
2021-01-03 13:48:21,429 INFO org.apache.juli.logging.DirectJDKLog [main] Starting service [Tomcat]
2021-01-03 13:48:21,430 INFO org.apache.juli.logging.DirectJDKLog [main] Starting Servlet engine: [Apache Tomcat/9.0.27]
2021-01-03 13:48:21,531 INFO org.apache.juli.logging.DirectJDKLog [main] Initializing Spring embedded WebApplicationContext
2021-01-03 13:48:21,532 INFO org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext [main] Root WebApplicationContext: initialization completed in 3411 ms
2021-01-03 13:48:21,955 INFO com.zaxxer.hikari.HikariDataSource [main] HikariPool-1 - Starting...
2021-01-03 13:48:22,252 INFO com.zaxxer.hikari.HikariDataSource [main] HikariPool-1 - Start completed.
2021-01-03 13:48:23,224 INFO liquibase.logging.core.Slf4jLogger [main] SELECT COUNT(*) FROM public.databasechangeloglock
2021-01-03 13:48:23,226 INFO liquibase.logging.core.Slf4jLogger [main] SELECT COUNT(*) FROM public.databasechangeloglock
2021-01-03 13:48:23,228 INFO liquibase.logging.core.Slf4jLogger [main] SELECT LOCKED FROM public.databasechangeloglock WHERE ID=1
2021-01-03 13:48:23,244 INFO liquibase.logging.core.Slf4jLogger [main] Changelog-Protokoll erfolgreich gesperrt.
2021-01-03 13:48:24,449 INFO liquibase.logging.core.Slf4jLogger [main] SELECT MD5SUM FROM public.databasechangelog WHERE MD5SUM IS NOT NULL LIMIT 1
2021-01-03 13:48:24,452 INFO liquibase.logging.core.Slf4jLogger [main] SELECT COUNT(*) FROM public.databasechangelog
2021-01-03 13:48:24,453 INFO liquibase.logging.core.Slf4jLogger [main] Reading from public.databasechangelog
2021-01-03 13:48:24,454 INFO liquibase.logging.core.Slf4jLogger [main] SELECT * FROM public.databasechangelog ORDER BY DATEEXECUTED ASC, ORDEREXECUTED ASC
2021-01-03 13:48:24,547 INFO liquibase.logging.core.Slf4jLogger [main] Successfully released change log lock
2021-01-03 13:48:24,549 INFO com.zaxxer.hikari.HikariDataSource [main] HikariPool-1 - Shutdown initiated...
2021-01-03 13:48:24,583 INFO com.zaxxer.hikari.HikariDataSource [main] HikariPool-1 - Shutdown completed.
2021-01-03 13:48:24,653 INFO com.zaxxer.hikari.HikariDataSource [main] HikariPool-2 - Starting...
2021-01-03 13:48:24,695 INFO com.zaxxer.hikari.HikariDataSource [main] HikariPool-2 - Start completed.
2021-01-03 13:48:24,746 INFO org.hibernate.jpa.internal.util.LogHelper [main] HHH000204: Processing PersistenceUnitInfo [name: default]
2021-01-03 13:48:24,849 INFO org.hibernate.Version [main] HHH000412: Hibernate Core {5.4.6.Final}
2021-01-03 13:48:25,141 INFO org.hibernate.annotations.common.reflection.java.JavaReflectionManager [main] HCANN000001: Hibernate Commons Annotations {5.1.0.Final}
2021-01-03 13:48:25,337 INFO org.hibernate.dialect.Dialect [main] HHH000400: Using dialect: org.hibernate.dialect.PostgreSQL95Dialect
2021-01-03 13:48:26,032 WARN org.hibernate.id.UUIDHexGenerator [main] HHH000409: Using org.hibernate.id.UUIDHexGenerator which does not generate IETF RFC 4122 compliant UUID values; consider using org.hibernate.id.UUIDGenerator instead
2021-01-03 13:48:27,306 INFO org.hibernate.engine.transaction.jta.platform.internal.JtaPlatformInitiator [main] HHH000490: Using JtaPlatform implementation: [org.hibernate.engine.transaction.jta.platform.internal.NoJtaPlatform]
2021-01-03 13:48:27,317 INFO org.springframework.orm.jpa.AbstractEntityManagerFactoryBean [main] Initialized JPA EntityManagerFactory for persistence unit 'default'
2021-01-03 13:48:28,158 INFO org.springframework.scheduling.concurrent.ExecutorConfigurationSupport [main] Initializing ExecutorService 'gaxThreadPoolTaskExecutor'
2021-01-03 13:48:28,324 INFO org.springframework.scheduling.concurrent.ExecutorConfigurationSupport [main] Initializing ExecutorService 'threadPoolTaskScheduler'
2021-01-03 13:48:28,411 WARN org.springframework.boot.autoconfigure.orm.jpa.JpaBaseConfiguration$JpaWebConfiguration [main] spring.jpa.open-in-view is enabled by default. Therefore, database queries may be performed during view rendering. Explicitly configure spring.jpa.open-in-view to disable this warning
2021-01-03 13:48:28,485 INFO de.gaxify.backend.task.StartGaxTask [MainThreadPoolTaskExecutor1] ########## Schedule Token Task
2021-01-03 13:48:28,486 INFO org.springframework.scheduling.concurrent.ExecutorConfigurationSupport [MainThreadPoolTaskExecutor1] Initializing ExecutorService
2021-01-03 13:48:28,498 INFO de.gaxify.backend.task.StartGaxTask [MainThreadPoolTaskExecutor1] ########## Schedule CSV Task
2021-01-03 13:48:28,498 INFO org.springframework.scheduling.concurrent.ExecutorConfigurationSupport [MainThreadPoolTaskExecutor1] Initializing ExecutorService
2021-01-03 13:48:28,499 INFO de.gaxify.backend.rest.token.TokenTask [ThreadPoolTaskScheduler-1] #############running token task
2021-01-03 13:48:28,507 INFO de.gaxify.backend.task.StartGaxTask [MainThreadPoolTaskExecutor1] ########## Schedule Trade Task
2021-01-03 13:48:28,507 INFO org.springframework.scheduling.concurrent.ExecutorConfigurationSupport [MainThreadPoolTaskExecutor1] Initializing ExecutorService
2021-01-03 13:48:28,521 INFO de.gaxify.backend.task.StartGaxTask [MainThreadPoolTaskExecutor1] ########## Schedule Report Task
2021-01-03 13:48:28,522 INFO org.springframework.scheduling.concurrent.ExecutorConfigurationSupport [MainThreadPoolTaskExecutor1] Initializing ExecutorService
2021-01-03 13:48:29,636 INFO de.gaxify.backend.rest.token.TokenTask [ThreadPoolTaskScheduler-1] Token for Company 'Schuhhaus Fischer' is 'bearer 88991645-28a0-4d56-a671-a611fa073f9f'
2021-01-03 13:48:29,984 INFO org.springframework.security.web.DefaultSecurityFilterChain [main] Creating filter chain: any request, [org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter#289778cd, org.springframework.security.web.context.SecurityContextPersistenceFilter#4f824872, org.springframework.security.web.header.HeaderWriterFilter#26f7cdf8, org.springframework.security.web.csrf.CsrfFilter#6c03fb16, org.springframework.security.web.authentication.logout.LogoutFilter#50acf55d, org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter#61f80d55, org.springframework.security.web.authentication.ui.DefaultLoginPageGeneratingFilter#363f0ba0, org.springframework.security.web.authentication.ui.DefaultLogoutPageGeneratingFilter#7495699f, org.springframework.security.web.authentication.www.BasicAuthenticationFilter#11e33bac, org.springframework.security.web.savedrequest.RequestCacheAwareFilter#29629fbb, org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter#35dd9ed3, org.springframework.security.web.authentication.AnonymousAuthenticationFilter#7c2312fa, org.springframework.security.web.session.SessionManagementFilter#23202c31, org.springframework.security.web.access.ExceptionTranslationFilter#3e7545e8, org.springframework.security.web.access.intercept.FilterSecurityInterceptor#6401d0a0]
2021-01-03 13:48:30,044 INFO org.springframework.boot.actuate.endpoint.web.EndpointLinksResolver [main] Exposing 2 endpoint(s) beneath base path '/actuator'
2021-01-03 13:48:30,112 INFO org.apache.juli.logging.DirectJDKLog [main] Starting ProtocolHandler ["http-nio-8080"]
2021-01-03 13:48:30,158 INFO org.springframework.boot.web.embedded.tomcat.TomcatWebServer [main] Tomcat started on port(s): 8080 (http) with context path ''
2021-01-03 13:48:30,161 INFO org.springframework.boot.StartupInfoLogger [main] Started Application in 13.24 seconds (JVM running for 14.0)
2021-01-03 13:48:30,180 ERROR org.springframework.boot.SpringApplication [main] Application run failed
java.lang.OutOfMemoryError: unable to create new native thread
at java.lang.Thread.start0(Native Method)
at java.lang.Thread.start(Thread.java:717)
at java.util.concurrent.ThreadPoolExecutor.addWorker(ThreadPoolExecutor.java:957)
at java.util.concurrent.ThreadPoolExecutor.execute(ThreadPoolExecutor.java:1367)
at org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor.execute(ThreadPoolTaskExecutor.java:314)
at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:136)
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:403)
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:360)
at org.springframework.boot.context.event.EventPublishingRunListener.running(EventPublishingRunListener.java:103)
at org.springframework.boot.SpringApplicationRunListeners.running(SpringApplicationRunListeners.java:77)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:330)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1226)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1215)
at de.gaxify.Application.main(Application.java:34)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:87)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:51)
at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:52)
2021-01-03 13:48:30,182 WARN org.springframework.context.support.AbstractApplicationContext [main] Exception thrown from ApplicationListener handling ContextClosedEvent
java.lang.OutOfMemoryError: unable to create new native thread
at java.lang.Thread.start0(Native Method)
at java.lang.Thread.start(Thread.java:717)
at java.util.concurrent.ThreadPoolExecutor.addWorker(ThreadPoolExecutor.java:957)
at java.util.concurrent.ThreadPoolExecutor.execute(ThreadPoolExecutor.java:1367)
at org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor.execute(ThreadPoolTaskExecutor.java:314)
at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:136)
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:403)
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:360)
at org.springframework.context.support.AbstractApplicationContext.doClose(AbstractApplicationContext.java:1012)
at org.springframework.context.support.AbstractApplicationContext.close(AbstractApplicationContext.java:978)
at org.springframework.boot.SpringApplication.handleRunFailure(SpringApplication.java:803)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:333)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1226)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1215)
at de.gaxify.Application.main(Application.java:34)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:87)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:51)
at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:52)
2021-01-03 13:48:30,187 INFO org.springframework.scheduling.concurrent.ExecutorConfigurationSupport [main] Shutting down ExecutorService 'threadPoolTaskScheduler'
2021-01-03 13:48:30,187 INFO org.springframework.scheduling.concurrent.ExecutorConfigurationSupport [main] Shutting down ExecutorService 'gaxThreadPoolTaskExecutor'
2021-01-03 13:48:30,190 INFO org.springframework.orm.jpa.AbstractEntityManagerFactoryBean [main] Closing JPA EntityManagerFactory for persistence unit 'default'
2021-01-03 13:48:30,202 INFO com.zaxxer.hikari.HikariDataSource [main] HikariPool-2 - Shutdown initiated...
2021-01-03 13:48:30,237 INFO com.zaxxer.hikari.HikariDataSource [main] HikariPool-2 - Shutdown completed.
2021-01-03 13:48:30,240 INFO org.apache.juli.logging.DirectJDKLog [main] Pausing ProtocolHandler ["http-nio-8080"]
2021-01-03 13:48:30,246 INFO org.apache.juli.logging.DirectJDKLog [main] Stopping service [Tomcat]
2021-01-03 13:48:30,251 INFO org.apache.juli.logging.DirectJDKLog [main] Stopping ProtocolHandler ["http-nio-8080"]
2021-01-03 13:48:30,279 INFO org.apache.juli.logging.DirectJDKLog [main] Destroying ProtocolHandler ["http-nio-8080"]
2021-01-03 13:48:32,980 INFO de.gaxify.backend.trade.TradeTask [ThreadPoolTaskScheduler-1] Trade status for Company 'Schuhhaus Fischer': 200
2021-01-03 13:48:33,041 ERROR org.springframework.scheduling.support.TaskUtils$LoggingErrorHandler [ThreadPoolTaskScheduler-1] Unexpected error occurred in scheduled task
org.springframework.boot.context.properties.ConfigurationPropertiesBindException: Error creating bean with name 'spring.liquibase-org.springframework.boot.autoconfigure.liquibase.LiquibaseProperties': Could not bind properties to 'LiquibaseProperties' : prefix=spring.liquibase, ignoreInvalidFields=false, ignoreUnknownFields=false; nested exception is java.lang.IllegalStateException: org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext#10bdf5e5 has been closed already
at org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor.bind(ConfigurationPropertiesBindingPostProcessor.java:110)
at org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor.postProcessBeforeInitialization(ConfigurationPropertiesBindingPostProcessor.java:96)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:416)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1795)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:595)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:517)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:323)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:321)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)
at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:276)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1287)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1207)
at org.springframework.beans.factory.support.ConstructorResolver.resolveAutowiredArgument(ConstructorResolver.java:874)
at org.springframework.beans.factory.support.ConstructorResolver.resolvePreparedArguments(ConstructorResolver.java:821)
at org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:151)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:1358)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1193)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:557)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:517)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:323)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:321)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:400)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1338)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:557)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:517)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:323)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:321)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:310)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeansOfType(DefaultListableBeanFactory.java:617)
at org.springframework.beans.factory.BeanFactoryUtils.beansOfTypeIncludingAncestors(BeanFactoryUtils.java:378)
at org.springframework.dao.support.PersistenceExceptionTranslationInterceptor.detectPersistenceExceptionTranslators(PersistenceExceptionTranslationInterceptor.java:168)
at org.springframework.dao.support.PersistenceExceptionTranslationInterceptor.invoke(PersistenceExceptionTranslationInterceptor.java:150)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at org.springframework.data.jpa.repository.support.CrudMethodMetadataPostProcessor$CrudMethodMetadataPopulatingMethodInterceptor.invoke(CrudMethodMetadataPostProcessor.java:149)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:93)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212)
at com.sun.proxy.$Proxy161.getTradeByOrderId(Unknown Source)
at de.gaxify.backend.database.services.GaxifyTradeService.getTradeByOrderId(GaxifyTradeService.java:48)
at de.gaxify.backend.trade.TradeProcessor.processTrades(TradeProcessor.java:52)
at de.gaxify.backend.trade.TradeTask.processTrade(TradeTask.java:62)
at de.gaxify.backend.trade.TradeTask.run(TradeTask.java:54)
at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
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)
Caused by: java.lang.IllegalStateException: org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext#10bdf5e5 has been closed already
at org.springframework.context.support.AbstractApplicationContext.assertBeanFactoryActive(AbstractApplicationContext.java:1092)
at org.springframework.context.support.AbstractApplicationContext.getBeanProvider(AbstractApplicationContext.java:1137)
at org.springframework.boot.context.properties.ConfigurationPropertiesBinder.getBindHandlerAdvisors(ConfigurationPropertiesBinder.java:147)
at org.springframework.boot.context.properties.ConfigurationPropertiesBinder.getBindHandler(ConfigurationPropertiesBinder.java:119)
at org.springframework.boot.context.properties.ConfigurationPropertiesBinder.bind(ConfigurationPropertiesBinder.java:88)
at org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor.bind(ConfigurationPropertiesBindingPostProcessor.java:107)
... 57 common frames omitted

ClassNotFoundException: org.jboss.resteasy.core.messagebody.AsyncBufferedMessageBodyWriter

I'm trying to implement this tutorial:
https://www.baeldung.com/rest-api-spring-oauth2-angular
My implementation: Github
I updated the package dependencies to latest version. But when I start the project I get exception:
13:34:43.343 [main] INFO EngineApplication[logStarting:55] - Starting EngineApplication v1.0 on ws-11820 with PID 56180 (C:\Users\plte1219\Desktop\CJM\media_auth\target\engine-1.0.jar started by plte1219 in C:\Users\plte1219\Desktop\CJM\media_auth)
13:34:43.347 [main] INFO EngineApplication[logStartupProfileInfo:655] - The following profiles are active: local
13:34:46.239 [main] INFO RepositoryConfigurationDelegate[registerRepositoriesIn:127] - Bootstrapping Spring Data JPA repositories in DEFAULT mode.
13:34:46.289 [main] INFO RepositoryConfigurationDelegate[registerRepositoriesIn:187] - Finished Spring Data repository scanning in 7ms. Found 0 JPA repository interfaces.
13:34:46.299 [main] INFO RepositoryConfigurationDelegate[registerRepositoriesIn:127] - Bootstrapping Spring Data JPA repositories in DEFAULT mode.
13:34:46.301 [main] INFO RepositoryConfigurationDelegate[registerRepositoriesIn:187] - Finished Spring Data repository scanning in 1ms. Found 0 JPA repository interfaces.
13:34:48.008 [main] INFO PostProcessorRegistrationDelegate$BeanPostProcessorChecker[postProcessAfterInitialization:335] - Bean 'contextProductionDatasource' of type [org.engine.context.ContextProductionDatasource$$EnhancerBySpringCGLIB$$80cefca2] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
13:34:48.192 [main] INFO PostProcessorRegistrationDelegate$BeanPostProcessorChecker[postProcessAfterInitialization:335] - Bean 'contextWarehouseDatasource' of type [org.engine.context.ContextWarehouseDatasource$$EnhancerBySpringCGLIB$$f848a010] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
13:34:49.537 [main] INFO TomcatWebServer[initialize:108] - Tomcat initialized with port(s): 8080 (http)
13:34:49.551 [main] INFO Http11NioProtocol[log:173] - Initializing ProtocolHandler ["http-nio-8080"]
13:34:49.552 [main] INFO StandardService[log:173] - Starting service [Tomcat]
13:34:49.552 [main] INFO StandardEngine[log:173] - Starting Servlet engine: [Apache Tomcat/9.0.36]
13:34:49.693 [main] INFO [/engine][log:173] - Initializing Spring embedded WebApplicationContext
13:34:49.693 [main] INFO ServletWebServerApplicationContext[prepareWebApplicationContext:285] - Root WebApplicationContext: initialization completed in 6128 ms
13:34:50.508 [main] INFO LogHelper[logPersistenceUnitInformation:31] - HHH000204: Processing PersistenceUnitInfo [name: DS1]
13:34:51.231 [main] INFO Version[logVersion:44] - HHH000412: Hibernate ORM core version 5.4.18.Final
13:34:51.979 [main] INFO Version[<clinit>:49] - HCANN000001: Hibernate Commons Annotations {5.1.0.Final}
13:34:53.126 [main] INFO HikariDataSource[getConnection:110] - PRODUCTION_HIKARICP_CONNECTION_POOL - Starting...
13:34:53.427 [main] INFO HikariDataSource[getConnection:123] - PRODUCTION_HIKARICP_CONNECTION_POOL - Start completed.
13:34:53.565 [main] INFO Dialect[<init>:172] - HHH000400: Using dialect: org.hibernate.dialect.MariaDB103Dialect
13:34:55.995 [main] INFO JtaPlatformInitiator[initiateService:52] - HHH000490: Using JtaPlatform implementation: [org.hibernate.engine.transaction.jta.platform.internal.NoJtaPlatform]
13:34:57.676 [main] INFO LocalContainerEntityManagerFactoryBean[buildNativeEntityManagerFactory:416] - Initialized JPA EntityManagerFactory for persistence unit 'DS1'
13:34:57.698 [main] INFO LogHelper[logPersistenceUnitInformation:31] - HHH000204: Processing PersistenceUnitInfo [name: DS2]
13:34:58.075 [main] INFO HikariDataSource[getConnection:110] - WAREHOUSE_HIKARICP_CONNECTION_POOL - Starting...
13:34:58.081 [main] INFO HikariDataSource[getConnection:123] - WAREHOUSE_HIKARICP_CONNECTION_POOL - Start completed.
13:34:58.082 [main] INFO Dialect[<init>:172] - HHH000400: Using dialect: org.hibernate.dialect.MariaDB103Dialect
13:34:58.432 [main] INFO JtaPlatformInitiator[initiateService:52] - HHH000490: Using JtaPlatform implementation: [org.hibernate.engine.transaction.jta.platform.internal.NoJtaPlatform]
13:34:58.433 [main] INFO LocalContainerEntityManagerFactoryBean[buildNativeEntityManagerFactory:416] - Initialized JPA EntityManagerFactory for persistence unit 'DS2'
13:34:58.879 [main] WARN JpaBaseConfiguration$JpaWebConfiguration[openEntityManagerInViewInterceptor:220] - spring.jpa.open-in-view is enabled by default. Therefore, database queries may be performed during view rendering. Explicitly configure spring.jpa.open-in-view to disable this warning
13:34:59.216 [main] INFO ThreadPoolTaskExecutor[initialize:181] - Initializing ExecutorService 'applicationTaskExecutor'
13:35:00.069 [main] WARN FreeMarkerAutoConfiguration[checkTemplateLocationExists:67] - Cannot find template location(s): [classpath:/templates/] (please add some templates, check your FreeMarker configuration, or set spring.freemarker.checkTemplateLocation=false)
13:35:01.188 [main] INFO Http11NioProtocol[log:173] - Starting ProtocolHandler ["http-nio-8080"]
13:35:01.423 [main] WARN i18n[registerProviders:150] - RESTEASY002145: NoClassDefFoundError: Unable to load builtin provider org.jboss.resteasy.plugins.providers.jackson.ResteasyJackson2Provider from jar:file:/C:/Users/plte1219/Desktop/CJM/media_auth/target/engine-1.0.jar!/BOOT-INF/lib/resteasy-jackson2-provider-4.5.5.Final.jar!/META-INF/services/javax.ws.rs.ext.Providers
java.lang.NoClassDefFoundError: org/jboss/resteasy/core/messagebody/AsyncBufferedMessageBodyWriter
at java.base/java.lang.ClassLoader.defineClass1(Native Method)
at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1017)
at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:151)
at java.base/java.net.URLClassLoader.defineClass(URLClassLoader.java:514)
at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java:422)
at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java:416)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:691)
at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:415)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:589)
at org.springframework.boot.loader.LaunchedURLClassLoader.loadClass(LaunchedURLClassLoader.java:151)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Class.java:427)
at org.springframework.boot.web.embedded.tomcat.TomcatEmbeddedWebappClassLoader.loadFromParent(TomcatEmbeddedWebappClassLoader.java:114)
at org.springframework.boot.web.embedded.tomcat.TomcatEmbeddedWebappClassLoader.doLoadClass(TomcatEmbeddedWebappClassLoader.java:87)
at org.springframework.boot.web.embedded.tomcat.TomcatEmbeddedWebappClassLoader.loadClass(TomcatEmbeddedWebappClassLoader.java:70)
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1188)
at org.jboss.resteasy.plugins.providers.RegisterBuiltin.registerProviders(RegisterBuiltin.java:132)
at org.jboss.resteasy.plugins.providers.RegisterBuiltin.register(RegisterBuiltin.java:52)
at org.jboss.resteasy.spi.ResteasyDeployment.startInternal(ResteasyDeployment.java:266)
at org.jboss.resteasy.spi.ResteasyDeployment.start(ResteasyDeployment.java:92)
at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.init(ServletContainerDispatcher.java:119)
at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.init(HttpServletDispatcher.java:36)
at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1134)
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:986)
at org.springframework.boot.web.embedded.tomcat.TomcatEmbeddedContext.load(TomcatEmbeddedContext.java:82)
at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1624)
at java.base/java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:658)
at java.base/java.util.stream.ReferencePipeline$7$1.accept(ReferencePipeline.java:274)
at java.base/java.util.TreeMap$ValueSpliterator.forEachRemaining(TreeMap.java:2905)
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
at java.base/java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:150)
at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:173)
at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.base/java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:497)
at org.springframework.boot.web.embedded.tomcat.TomcatEmbeddedContext.lambda$deferredLoadOnStartup$0(TomcatEmbeddedContext.java:65)
at org.springframework.boot.web.embedded.tomcat.TomcatEmbeddedContext.doWithThreadContextClassLoader(TomcatEmbeddedContext.java:106)
at org.springframework.boot.web.embedded.tomcat.TomcatEmbeddedContext.deferredLoadOnStartup(TomcatEmbeddedContext.java:64)
at org.springframework.boot.web.embedded.tomcat.TomcatWebServer.performDeferredLoadOnStartup(TomcatWebServer.java:305)
at org.springframework.boot.web.embedded.tomcat.TomcatWebServer.start(TomcatWebServer.java:216)
at org.springframework.boot.web.servlet.context.WebServerStartStopLifecycle.start(WebServerStartStopLifecycle.java:43)
at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:182)
at org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:53)
at org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
at org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:158)
at org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:122)
at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:895)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:554)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:143)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:758)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:750)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:397)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:315)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1237)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1226)
at org.engine.EngineApplication.main(EngineApplication.java:25)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:564)
at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:49)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:109)
at org.springframework.boot.loader.Launcher.launch(Launcher.java:58)
at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:88)
Caused by: java.lang.ClassNotFoundException: org.jboss.resteasy.core.messagebody.AsyncBufferedMessageBodyWriter
at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:435)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:589)
at org.springframework.boot.loader.LaunchedURLClassLoader.loadClass(LaunchedURLClassLoader.java:151)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
... 66 common frames omitted
Do you know how I can fix this issue?
I had the same error. I updated resteasy-jackson2-provider and that caused the problem.
Turned out I had to also update resteasy-client to the same version, not sure if it applies to your case, but I got rid of this error this way. In my case I updated to the latest (at the moment) 4.5.8.Final

TestContainers - Can't connect to MySQLContainer Docker - Integration Test

I'm Trying to run my Integration Test using MySQLContainer in Docker, however when i run the tests, the application gets caught in a loop trying to establish a JDBC Connection, find bellow my integration Test class and the log of the Spring Boot Application.
Integration Test Class
package com.recargaslda.multiplatform.repositorios;
import static org.hamcrest.CoreMatchers.is;
import static org.junit.Assert.assertThat;
import java.time.LocalDate;
import org.junit.Rule;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.util.TestPropertyValues;
import org.springframework.context.ApplicationContextInitializer;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.test.context.ContextConfiguration;
import org.testcontainers.containers.MySQLContainer;
import com.recargaslda.multiplatform.entidades.Album;
#SpringBootTest
#ContextConfiguration(initializers = { AlbumRepositorioTesteIntegracao.Initializer.class })
public class AlbumRepositorioTesteIntegracao {
// Even When i change the image version to 5.5 it still fails to connect
#Rule
private static MySQLContainer sqlContainer = new MySQLContainer<>("mysql:8.0");
static {
sqlContainer.withDatabaseName("teste-integração-album-repositorio").withUsername("root").withPassword("root");
sqlContainer.start();
}
static class Initializer implements ApplicationContextInitializer<ConfigurableApplicationContext> {
#Override
public void initialize(ConfigurableApplicationContext applicationContext) {
TestPropertyValues.of("spring.datasource.url=" + sqlContainer.getJdbcUrl(),
"spring.datasource.username=" + sqlContainer.getUsername(),
"spring.datasource.password=" + sqlContainer.getPassword()).applyTo(applicationContext);
}
}
#Autowired
AlbumRepositorio albumRepositorio;
#Test
public void DevePersistirUmNovoAlbumSemImagens() {
Album album = new Album("album", LocalDate.now(), "Capa");
albumRepositorio.save(album);
Album albumEncontrado = albumRepositorio.findByNome("album");
assertThat(album.getNome(), is(albumEncontrado.getNome()));
}
}
The Console Log During the loop:
13:48:00.676 [main] INFO org.springframework.test.context.support.AbstractContextLoader - Could not detect default resource locations for test class [com.recargaslda.multiplatform.repositorios.AlbumRepositorioTesteIntegracao]: no resource found for suffixes {-context.xml, Context.groovy}.
13:48:00.678 [main] DEBUG org.springframework.test.context.support.AnnotationConfigContextLoaderUtils - Ignoring class [com.recargaslda.multiplatform.repositorios.AlbumRepositorioTesteIntegracao$Initializer]; it must be static, non-private, non-final, and annotated with #Configuration to be considered a default configuration class.
13:48:00.678 [main] INFO org.springframework.test.context.support.AnnotationConfigContextLoaderUtils - Could not detect default configuration classes for test class [com.recargaslda.multiplatform.repositorios.AlbumRepositorioTesteIntegracao]: AlbumRepositorioTesteIntegracao does not declare any static, non-private, non-final, nested classes annotated with #Configuration.
13:48:00.770 [main] DEBUG org.springframework.test.context.support.ActiveProfilesUtils - Could not find an 'annotation declaring class' for annotation type [org.springframework.test.context.ActiveProfiles] and class [com.recargaslda.multiplatform.repositorios.AlbumRepositorioTesteIntegracao]
13:48:00.990 [main] DEBUG org.springframework.context.annotation.ClassPathScanningCandidateComponentProvider - Identified candidate component class: file [C:\Users\Pete\Documents\Workspace\MultiPlatformAplicacao\target\classes\com\recargaslda\multiplatform\MultiPlatformApplication.class]
13:48:00.993 [main] INFO org.springframework.boot.test.context.SpringBootTestContextBootstrapper - Found #SpringBootConfiguration com.recargaslda.multiplatform.MultiPlatformApplication for test class com.recargaslda.multiplatform.repositorios.AlbumRepositorioTesteIntegracao
13:48:01.216 [main] DEBUG org.springframework.boot.test.context.SpringBootTestContextBootstrapper - #TestExecutionListeners is not present for class [com.recargaslda.multiplatform.repositorios.AlbumRepositorioTesteIntegracao]: using defaults.
13:48:01.217 [main] INFO org.springframework.boot.test.context.SpringBootTestContextBootstrapper - Loaded default TestExecutionListener class names from location [META-INF/spring.factories]: [org.springframework.boot.test.mock.mockito.MockitoTestExecutionListener, org.springframework.boot.test.mock.mockito.ResetMocksTestExecutionListener, org.springframework.boot.test.autoconfigure.restdocs.RestDocsTestExecutionListener, org.springframework.boot.test.autoconfigure.web.client.MockRestServiceServerResetTestExecutionListener, org.springframework.boot.test.autoconfigure.web.servlet.MockMvcPrintOnlyOnFailureTestExecutionListener, org.springframework.boot.test.autoconfigure.web.servlet.WebDriverTestExecutionListener, org.springframework.test.context.web.ServletTestExecutionListener, org.springframework.test.context.support.DirtiesContextBeforeModesTestExecutionListener, org.springframework.test.context.support.DependencyInjectionTestExecutionListener, org.springframework.test.context.support.DirtiesContextTestExecutionListener, org.springframework.test.context.transaction.TransactionalTestExecutionListener, org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener, org.springframework.test.context.event.EventPublishingTestExecutionListener, org.springframework.security.test.context.support.WithSecurityContextTestExecutionListener, org.springframework.security.test.context.support.ReactorContextTestExecutionListener]
13:48:01.269 [main] INFO org.springframework.boot.test.context.SpringBootTestContextBootstrapper - Using TestExecutionListeners: [org.springframework.test.context.web.ServletTestExecutionListener#2eae8e6e, org.springframework.test.context.support.DirtiesContextBeforeModesTestExecutionListener#8f2ef19, org.springframework.boot.test.mock.mockito.MockitoTestExecutionListener#470734c3, org.springframework.boot.test.autoconfigure.SpringBootDependencyInjectionTestExecutionListener#2cf3d63b, org.springframework.test.context.support.DirtiesContextTestExecutionListener#7674f035, org.springframework.test.context.transaction.TransactionalTestExecutionListener#69e153c5, org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener#173ed316, org.springframework.test.context.event.EventPublishingTestExecutionListener#25ce9dc4, org.springframework.security.test.context.support.WithSecurityContextTestExecutionListener#74ea2410, org.springframework.security.test.context.support.ReactorContextTestExecutionListener#17f62e33, org.springframework.boot.test.mock.mockito.ResetMocksTestExecutionListener#76b1e9b8, org.springframework.boot.test.autoconfigure.restdocs.RestDocsTestExecutionListener#27406a17, org.springframework.boot.test.autoconfigure.web.client.MockRestServiceServerResetTestExecutionListener#2af004b, org.springframework.boot.test.autoconfigure.web.servlet.MockMvcPrintOnlyOnFailureTestExecutionListener#248e319b, org.springframework.boot.test.autoconfigure.web.servlet.WebDriverTestExecutionListener#5d0bf09b]
13:48:01.737 [main] INFO org.testcontainers.dockerclient.DockerClientProviderStrategy - Loaded org.testcontainers.dockerclient.NpipeSocketClientProviderStrategy from ~/.testcontainers.properties, will try it first
13:48:02.995 [ducttape-0] DEBUG org.testcontainers.dockerclient.DockerClientProviderStrategy - Pinging docker daemon...
13:48:03.311 [ducttape-0] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: org.testcontainers.dockerclient.transport.okhttp.OkHttpDockerCmdExecFactory$1#298aadd0
13:48:03.418 [main] INFO org.testcontainers.dockerclient.NpipeSocketClientProviderStrategy - Accessing docker with local Npipe socket (npipe:////./pipe/docker_engine)
13:48:03.419 [main] INFO org.testcontainers.dockerclient.DockerClientProviderStrategy - Found Docker environment with local Npipe socket (npipe:////./pipe/docker_engine)
13:48:03.419 [main] DEBUG org.testcontainers.dockerclient.DockerClientProviderStrategy - Checking Docker OS type for local Npipe socket (npipe:////./pipe/docker_engine)
13:48:03.421 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: com.github.dockerjava.core.exec.InfoCmdExec#1115ec15
13:48:03.715 [main] INFO org.testcontainers.DockerClientFactory - Docker host IP address is localhost
13:48:03.717 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: com.github.dockerjava.core.exec.InfoCmdExec#6155d082
13:48:03.738 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: com.github.dockerjava.core.exec.VersionCmdExec#7803bfd
13:48:03.770 [main] INFO org.testcontainers.DockerClientFactory - Connected to docker:
Server Version: 19.03.8
API Version: 1.40
Operating System: Docker Desktop
Total Memory: 1989 MB
13:48:03.770 [main] DEBUG org.testcontainers.DockerClientFactory - Ryuk is enabled
13:48:03.776 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ListImagesCmdImpl[imageNameFilter=quay.io/testcontainers/ryuk:0.2.3,showAll=false,filters=com.github.dockerjava.core.util.FiltersBuilder#0,execution=com.github.dockerjava.core.exec.ListImagesCmdExec#4f25b795]
13:48:03.851 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - Looking up auth config for image: quay.io/testcontainers/ryuk:0.2.3
13:48:03.851 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - RegistryAuthLocator has configFile: C:\Users\Pete\.docker\config.json (exists) and commandPathPrefix:
13:48:03.860 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - registryName [quay.io] for dockerImageName [quay.io/testcontainers/ryuk:0.2.3]
13:48:03.861 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - Executing docker credential provider: docker-credential-desktop to locate auth config for: quay.io
13:48:03.878 [main] DEBUG org.testcontainers.shaded.org.zeroturnaround.exec.ProcessExecutor - Executing [docker-credential-desktop, get].
13:48:03.885 [main] DEBUG org.testcontainers.shaded.org.zeroturnaround.exec.ProcessExecutor - Started java.lang.ProcessImpl#3212a8d7
13:48:04.044 [WaitForProcess-java.lang.ProcessImpl#3212a8d7] DEBUG org.testcontainers.shaded.org.zeroturnaround.exec.WaitForProcess - java.lang.ProcessImpl#3212a8d7 stopped with exit code 1
13:48:04.048 [main] DEBUG org.testcontainers.shaded.org.zeroturnaround.exec.ProcessExecutor - Executing [docker-credential-desktop, get].
13:48:04.053 [main] DEBUG org.testcontainers.shaded.org.zeroturnaround.exec.ProcessExecutor - Started java.lang.ProcessImpl#71454b9d
13:48:04.188 [WaitForProcess-java.lang.ProcessImpl#71454b9d] DEBUG org.testcontainers.shaded.org.zeroturnaround.exec.WaitForProcess - java.lang.ProcessImpl#71454b9d stopped with exit code 1
13:48:04.190 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - Got credentials not found error message from docker credential helper - credentials not found in native keychain
13:48:04.192 [main] INFO org.testcontainers.utility.RegistryAuthLocator - Credential helper/store (docker-credential-desktop) does not have credentials for quay.io
13:48:04.195 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - no matching Auth Configs - falling back to defaultAuthConfig [null]
13:48:04.195 [main] DEBUG org.testcontainers.dockerclient.auth.AuthDelegatingDockerClientConfig - Effective auth config [null]
13:48:04.239 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: com.github.dockerjava.core.command.CreateContainerCmdImpl#584f54e6[name=testcontainers-ryuk-c9db393d-d0ec-4740-848a-134abfe549c5,hostName=<null>,domainName=<null>,user=<null>,attachStdin=<null>,attachStdout=<null>,attachStderr=<null>,portSpecs=<null>,tty=<null>,stdinOpen=<null>,stdInOnce=<null>,env=<null>,cmd=<null>,healthcheck=<null>,argsEscaped=<null>,entrypoint=<null>,image=quay.io/testcontainers/ryuk:0.2.3,volumes=com.github.dockerjava.api.model.Volumes#23aa363a,workingDir=<null>,macAddress=<null>,onBuild=<null>,networkDisabled=<null>,exposedPorts=com.github.dockerjava.api.model.ExposedPorts#5ef6ae06,stopSignal=<null>,stopTimeout=<null>,hostConfig=com.github.dockerjava.api.model.HostConfig#55dfebeb[binds=com.github.dockerjava.api.model.Binds#604f2bd2,blkioWeight=<null>,blkioWeightDevice=<null>,blkioDeviceReadBps=<null>,blkioDeviceWriteBps=<null>,blkioDeviceReadIOps=<null>,blkioDeviceWriteIOps=<null>,memorySwappiness=<null>,nanoCPUs=<null>,capAdd=<null>,capDrop=<null>,containerIDFile=<null>,cpuPeriod=<null>,cpuRealtimePeriod=<null>,cpuRealtimeRuntime=<null>,cpuShares=<null>,cpuQuota=<null>,cpusetCpus=<null>,cpusetMems=<null>,devices=<null>,deviceCgroupRules=<null>,diskQuota=<null>,dns=<null>,dnsOptions=<null>,dnsSearch=<null>,extraHosts=<null>,groupAdd=<null>,ipcMode=<null>,cgroup=<null>,links=<null>,logConfig=<null>,lxcConf=<null>,memory=<null>,memorySwap=<null>,memoryReservation=<null>,kernelMemory=<null>,networkMode=<null>,oomKillDisable=<null>,init=<null>,autoRemove=true,oomScoreAdj=<null>,portBindings=<null>,privileged=false,publishAllPorts=true,readonlyRootfs=<null>,restartPolicy=<null>,ulimits=<null>,cpuCount=<null>,cpuPercent=<null>,ioMaximumIOps=<null>,ioMaximumBandwidth=<null>,volumesFrom=<null>,mounts=<null>,pidMode=<null>,isolation=<null>,securityOpts=<null>,storageOpt=<null>,cgroupParent=<null>,volumeDriver=<null>,shmSize=<null>,pidsLimit=<null>,runtime=<null>,tmpFs=<null>,utSMode=<null>,usernsMode=<null>,sysctls=<null>,consoleSize=<null>],labels={org.testcontainers=true},shell=<null>,networkingConfig=<null>,ipv4Address=<null>,ipv6Address=<null>,aliases=<null>,authConfig=<null>,execution=com.github.dockerjava.core.exec.CreateContainerCmdExec#1d3ac898]
13:48:05.184 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: 63eb180f9f28ccc0ef8215d62d80d404de21b3841411a9ba29492c5dab3e42e0,com.github.dockerjava.core.exec.StartContainerCmdExec#56e8b606
13:48:06.714 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: 63eb180f9f28ccc0ef8215d62d80d404de21b3841411a9ba29492c5dab3e42e0,false,com.github.dockerjava.core.exec.InspectContainerCmdExec#366c4480
13:48:06.718 [main] DEBUG com.github.dockerjava.core.exec.InspectContainerCmdExec - GET: OkHttpWebTarget(okHttpClient=org.testcontainers.shaded.okhttp3.OkHttpClient#2c7b5824, baseUrl=http://docker.socket/, path=[/containers/63eb180f9f28ccc0ef8215d62d80d404de21b3841411a9ba29492c5dab3e42e0/json], queryParams={})
13:48:06.892 [testcontainers-ryuk] DEBUG org.testcontainers.utility.ResourceReaper - Sending 'label=org.testcontainers%3Dtrue&label=org.testcontainers.sessionId%3Dc9db393d-d0ec-4740-848a-134abfe549c5' to Ryuk
13:48:06.895 [testcontainers-ryuk] DEBUG org.testcontainers.utility.ResourceReaper - Received 'ACK' from Ryuk
13:48:06.895 [main] INFO org.testcontainers.DockerClientFactory - Ryuk started - will monitor and terminate Testcontainers containers on JVM exit
13:48:06.895 [main] DEBUG org.testcontainers.DockerClientFactory - Checks are enabled
13:48:06.895 [main] INFO org.testcontainers.DockerClientFactory - Checking the system...
13:48:06.896 [main] INFO org.testcontainers.DockerClientFactory - ✔︎ Docker server version should be at least 1.6.0
13:48:06.899 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: 63eb180f9f28ccc0ef8215d62d80d404de21b3841411a9ba29492c5dab3e42e0,<null>,true,<null>,<null>,<null>,<null>,{df,-P},<null>,<null>,com.github.dockerjava.core.exec.ExecCreateCmdExec#2a79d4b1
13:48:07.015 [tc-okhttp-stream-1130346421] DEBUG com.github.dockerjava.core.command.ExecStartResultCallback - STDOUT: Filesystem 1024-blocks Used Available Capacity Mounted on
overlay 61255652 3271272 54843048 6% /
tmpfs 65536 0 65536 0% /dev
tmpfs 1018508 0 1018508 0% /sys/fs/cgroup
shm 65536 0 65536 0% /dev/shm
/dev/sda1 61255652 3271272 54843048 6% /etc/resolv.conf
/dev/sda1 61255652 3271272 54843048 6% /etc/hostname
/dev/sda1 61255652 3271272 54843048 6% /etc/hosts
overlay 1018508 400 1018108 0% /run/docker.sock
tmpfs 1018508 0 1018508 0% /proc/acpi
tmpfs 65536 0 65536 0% /proc/kcore
tmpfs 65536 0 65536 0% /proc/keys
tmpfs 65536 0 65536 0% /proc/timer_list
tmpfs 65536 0 65536 0% /proc/sched_debug
tmpfs 1018508 0 1018508 0% /sys/firmware
13:48:07.045 [main] INFO org.testcontainers.DockerClientFactory - ✔︎ Docker environment should have more than 2GB free disk space
13:48:07.046 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ListImagesCmdImpl[imageNameFilter=<null>,showAll=false,filters=com.github.dockerjava.core.util.FiltersBuilder#0,execution=com.github.dockerjava.core.exec.ListImagesCmdExec#56c698e3]
13:48:07.091 [main] DEBUG org.testcontainers.images.AbstractImagePullPolicy - Using locally available and not pulling image: mysql:8.0
13:48:07.091 [main] DEBUG 🐳 [mysql:8.0] - Starting container: mysql:8.0
13:48:07.092 [main] DEBUG 🐳 [mysql:8.0] - Trying to start container: mysql:8.0
13:48:07.092 [main] DEBUG 🐳 [mysql:8.0] - Trying to start container: mysql:8.0 (attempt 1/3)
13:48:07.092 [main] DEBUG 🐳 [mysql:8.0] - Starting container: mysql:8.0
13:48:07.092 [main] INFO 🐳 [mysql:8.0] - Creating container for image: mysql:8.0
13:48:07.093 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - Looking up auth config for image: mysql:8.0
13:48:07.093 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - RegistryAuthLocator has configFile: C:\Users\Pete\.docker\config.json (exists) and commandPathPrefix:
13:48:07.093 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - registryName [index.docker.io] for dockerImageName [mysql:8.0]
13:48:07.093 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - Executing docker credential provider: docker-credential-desktop to locate auth config for: index.docker.io
13:48:07.093 [main] DEBUG org.testcontainers.shaded.org.zeroturnaround.exec.ProcessExecutor - Executing [docker-credential-desktop, get].
13:48:07.097 [main] DEBUG org.testcontainers.shaded.org.zeroturnaround.exec.ProcessExecutor - Started java.lang.ProcessImpl#5c8504fd
13:48:07.224 [WaitForProcess-java.lang.ProcessImpl#5c8504fd] DEBUG org.testcontainers.shaded.org.zeroturnaround.exec.WaitForProcess - java.lang.ProcessImpl#5c8504fd stopped with exit code 0
13:48:07.225 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - Credential helper/store provided auth config for: index.docker.io
13:48:07.232 [main] DEBUG org.testcontainers.utility.RegistryAuthLocator - found creds store auth config [AuthConfig{username=petechiboleca, password=hidden non-blank value, auth=blank, email=null, registryAddress=index.docker.io, registryToken=blank}]
13:48:07.232 [main] DEBUG org.testcontainers.dockerclient.auth.AuthDelegatingDockerClientConfig - Effective auth config [AuthConfig{username=petechiboleca, password=hidden non-blank value, auth=blank, email=null, registryAddress=index.docker.io, registryToken=blank}]
13:48:07.243 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: com.github.dockerjava.core.command.CreateContainerCmdImpl#5c153b9e[name=<null>,hostName=<null>,domainName=<null>,user=<null>,attachStdin=<null>,attachStdout=<null>,attachStderr=<null>,portSpecs=<null>,tty=<null>,stdinOpen=<null>,stdInOnce=<null>,env={MYSQL_DATABASE=teste-integração-album-repositorio,MYSQL_PASSWORD=root,MYSQL_USER=root,MYSQL_ROOT_PASSWORD=root},cmd={},healthcheck=<null>,argsEscaped=<null>,entrypoint=<null>,image=mysql:8.0,volumes=com.github.dockerjava.api.model.Volumes#2a7686a7,workingDir=<null>,macAddress=<null>,onBuild=<null>,networkDisabled=<null>,exposedPorts=com.github.dockerjava.api.model.ExposedPorts#758a34ce,stopSignal=<null>,stopTimeout=<null>,hostConfig=com.github.dockerjava.api.model.HostConfig#7ec3394b[binds=com.github.dockerjava.api.model.Binds#bff34c6,blkioWeight=<null>,blkioWeightDevice=<null>,blkioDeviceReadBps=<null>,blkioDeviceWriteBps=<null>,blkioDeviceReadIOps=<null>,blkioDeviceWriteIOps=<null>,memorySwappiness=<null>,nanoCPUs=<null>,capAdd=<null>,capDrop=<null>,containerIDFile=<null>,cpuPeriod=<null>,cpuRealtimePeriod=<null>,cpuRealtimeRuntime=<null>,cpuShares=<null>,cpuQuota=<null>,cpusetCpus=<null>,cpusetMems=<null>,devices=<null>,deviceCgroupRules=<null>,diskQuota=<null>,dns=<null>,dnsOptions=<null>,dnsSearch=<null>,extraHosts={},groupAdd=<null>,ipcMode=<null>,cgroup=<null>,links=com.github.dockerjava.api.model.Links#1522d8a0,logConfig=<null>,lxcConf=<null>,memory=<null>,memorySwap=<null>,memoryReservation=<null>,kernelMemory=<null>,networkMode=<null>,oomKillDisable=<null>,init=<null>,autoRemove=<null>,oomScoreAdj=<null>,portBindings={},privileged=<null>,publishAllPorts=true,readonlyRootfs=<null>,restartPolicy=<null>,ulimits=<null>,cpuCount=<null>,cpuPercent=<null>,ioMaximumIOps=<null>,ioMaximumBandwidth=<null>,volumesFrom={},mounts=<null>,pidMode=<null>,isolation=<null>,securityOpts=<null>,storageOpt=<null>,cgroupParent=<null>,volumeDriver=<null>,shmSize=<null>,pidsLimit=<null>,runtime=<null>,tmpFs=<null>,utSMode=<null>,usernsMode=<null>,sysctls=<null>,consoleSize=<null>],labels={org.testcontainers=true, org.testcontainers.sessionId=c9db393d-d0ec-4740-848a-134abfe549c5},shell=<null>,networkingConfig=<null>,ipv4Address=<null>,ipv6Address=<null>,aliases=<null>,authConfig=AuthConfig[username=petechiboleca,password=tWindrifter12345,email=<null>,registryAddress=index.docker.io,auth=<null>,registrytoken=<null>,identitytoken=<null>,stackOrchestrator=<null>],execution=com.github.dockerjava.core.exec.CreateContainerCmdExec#5644dc81]
13:48:08.194 [main] DEBUG org.testcontainers.utility.MountableFile - Copying classpath resource(s) from jar:file:/C:/Users/Pete/.m2/repository/org/testcontainers/mysql/1.13.0/mysql-1.13.0.jar!/mysql-default-conf to C:\Users\Pete\AppData\Local\Temp\.testcontainers-tmp-5095191207689237918 to permit Docker to bind
13:48:08.194 [main] DEBUG org.testcontainers.utility.MountableFile - Copying resource mysql-default-conf from JAR file C:\Users\Pete\.m2\repository\org\testcontainers\mysql\1.13.0\mysql-1.13.0.jar
13:48:08.194 [main] DEBUG org.testcontainers.utility.MountableFile - Copying classpath resource(s) from jar:file:/C:/Users/Pete/.m2/repository/org/testcontainers/mysql/1.13.0/mysql-1.13.0.jar!/mysql-default-conf to C:\Users\Pete\AppData\Local\Temp\.testcontainers-tmp-5095191207689237918 to permit Docker to bind
13:48:08.195 [main] DEBUG org.testcontainers.utility.MountableFile - Copying resource mysql-default-conf from JAR file C:\Users\Pete\.m2\repository\org\testcontainers\mysql\1.13.0\mysql-1.13.0.jar
13:48:08.202 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d,false,com.github.dockerjava.core.exec.InspectContainerCmdExec#57fd91c9
13:48:08.203 [main] DEBUG com.github.dockerjava.core.exec.InspectContainerCmdExec - GET: OkHttpWebTarget(okHttpClient=org.testcontainers.shaded.okhttp3.OkHttpClient#2c7b5824, baseUrl=http://docker.socket/, path=[/containers/ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d/json], queryParams={})
13:48:08.234 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: com.github.dockerjava.core.command.CopyArchiveToContainerCmdImpl#25e2a451[cp ,<null>, ,ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d,:,/]
13:48:08.379 [main] INFO 🐳 [mysql:8.0] - Starting container with ID: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d
13:48:08.379 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d,com.github.dockerjava.core.exec.StartContainerCmdExec#63b1d4fa
13:48:09.716 [main] INFO 🐳 [mysql:8.0] - Container mysql:8.0 is starting: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d
13:48:09.718 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d,false,com.github.dockerjava.core.exec.InspectContainerCmdExec#75459c75
13:48:09.718 [main] DEBUG com.github.dockerjava.core.exec.InspectContainerCmdExec - GET: OkHttpWebTarget(okHttpClient=org.testcontainers.shaded.okhttp3.OkHttpClient#2c7b5824, baseUrl=http://docker.socket/, path=[/containers/ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d/json], queryParams={})
13:48:09.735 [ducttape-0] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d,false,com.github.dockerjava.core.exec.InspectContainerCmdExec#410298f0
13:48:09.737 [ducttape-0] DEBUG com.github.dockerjava.core.exec.InspectContainerCmdExec - GET: OkHttpWebTarget(okHttpClient=org.testcontainers.shaded.okhttp3.OkHttpClient#2c7b5824, baseUrl=http://docker.socket/, path=[/containers/ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d/json], queryParams={})
13:48:09.753 [main] INFO 🐳 [mysql:8.0] - Waiting for database connection to become available at jdbc:mysql://localhost:32851/teste-integração-album-repositorio using query 'SELECT 1'
13:48:09.753 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d,false,com.github.dockerjava.core.exec.InspectContainerCmdExec#2a3c96e3
13:48:09.753 [main] DEBUG com.github.dockerjava.core.exec.InspectContainerCmdExec - GET: OkHttpWebTarget(okHttpClient=org.testcontainers.shaded.okhttp3.OkHttpClient#2c7b5824, baseUrl=http://docker.socket/, path=[/containers/ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d/json], queryParams={})
13:48:09.792 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d,false,com.github.dockerjava.core.exec.InspectContainerCmdExec#a8e6492
13:48:09.792 [main] DEBUG com.github.dockerjava.core.exec.InspectContainerCmdExec - GET: OkHttpWebTarget(okHttpClient=org.testcontainers.shaded.okhttp3.OkHttpClient#2c7b5824, baseUrl=http://docker.socket/, path=[/containers/ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d/json], queryParams={})
13:48:09.799 [main] DEBUG 🐳 [mysql:8.0] - Trying to create JDBC connection using com.mysql.cj.jdbc.Driver to jdbc:mysql://localhost:32851/teste-integração-album-repositorio?useSSL=false&allowPublicKeyRetrieval=true with properties: {user=root, password=root}
13:48:10.233 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d,false,com.github.dockerjava.core.exec.InspectContainerCmdExec#1e5f4170
13:48:10.233 [main] DEBUG com.github.dockerjava.core.exec.InspectContainerCmdExec - GET: OkHttpWebTarget(okHttpClient=org.testcontainers.shaded.okhttp3.OkHttpClient#2c7b5824, baseUrl=http://docker.socket/, path=[/containers/ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d/json], queryParams={})
13:48:10.240 [main] DEBUG 🐳 [mysql:8.0] - Trying to create JDBC connection using com.mysql.cj.jdbc.Driver to jdbc:mysql://localhost:32851/teste-integração-album-repositorio?useSSL=false&allowPublicKeyRetrieval=true with properties: {user=root, password=root}
13:48:09.799 [main] DEBUG 🐳 [mysql:8.0] - Trying to create JDBC connection using com.mysql.cj.jdbc.Driver to jdbc:mysql://localhost:32851/teste-integração-album-repositorio?useSSL=false&allowPublicKeyRetrieval=true with properties: {user=root, password=root}
13:48:10.233 [main] DEBUG com.github.dockerjava.core.command.AbstrDockerCmd - Cmd: ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d,false,com.github.dockerjava.core.exec.InspectContainerCmdExec#1e5f4170
13:48:10.233 [main] DEBUG com.github.dockerjava.core.exec.InspectContainerCmdExec - GET: OkHttpWebTarget(okHttpClient=org.testcontainers.shaded.okhttp3.OkHttpClient#2c7b5824, baseUrl=http://docker.socket/, path=[/containers/ce913f5a3ea48d499b6882d31da0c9c37bb004b8036e321f6420ef5d2bd5b73d/json], queryParams={})
13:48:10.240 [main] DEBUG 🐳 [mysql:8.0] - Trying to create JDBC connection using com.mysql.cj.jdbc.Driver to jdbc:mysql://localhost:32851/teste-integração-album-repositorio?useSSL=false&allowPublicKeyRetrieval=true with properties: {user=root, password=root}
MySQL Container Docker Dependency and MySQL Connector 8.0 Dependency (Spring Boot is managing my connector)
<groupId>org.testcontainers</groupId>
<artifactId>mysql</artifactId>
version>1.13.0</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<scope>runtime</scope>
</dependency>
Note: When i use PostgreSQLContainer, The test passes succesfully
Note 2: When the loop breaks it Says *Communications link failure
You cannot create a user called "root" in mysql, since it already exists. Remove this part, and see if it helps:
.withUsername("root")

Apache Solr "HTTP ERROR 503" after unloading Core and trying to re-create it

I was looking how I can query some XML files with Solr and thus I went and changed the schema.xml file located under the collection1 directory.
Then I launched a query, which I knew it should return 1 result but in vain.
So I figured I might have to re-load the CORE (the idea was taken from CoreAdmin -Solr Wiki). So I did, but for some reason I wasn't able to. Thats said, I decided to restart the service (sorl/example java -jar start.jar) and now I am getting this error:
HTTP ERROR 503
Problem accessing /solr/. Reason:
Server is shutting down or failed to initialize
Powered by Jetty://
This is the command prompt output which shows that server is running??
0 [main] INFO org.eclipse.jetty.server.Server û jetty-8.1.10.v20130312
75 [main] INFO org.eclipse.jetty.deploy.providers.ScanningAppProvider û Depl
oyment monitor C:\Users\kapel_000\Desktop\solr-4.10.2\example\contexts at interv
al 0
83 [main] INFO org.eclipse.jetty.deploy.DeploymentManager û Deployable added
: C:\Users\kapel_000\Desktop\solr-4.10.2\example\contexts\solr-jetty-context.xml
1916 [main] INFO org.eclipse.jetty.webapp.StandardDescriptorProcessor û NO JSP
Support for /solr, did not find org.apache.jasper.servlet.JspServlet
2066 [main] INFO org.apache.solr.servlet.SolrDispatchFilter û SolrDispatchFilt
er.init()
2083 [main] INFO org.apache.solr.core.SolrResourceLoader û JNDI not configured
for solr (NoInitialContextEx)
2083 [main] INFO org.apache.solr.core.SolrResourceLoader û solr home defaulted
to 'solr/' (could not find system property or JNDI)
2084 [main] INFO org.apache.solr.core.SolrResourceLoader û new SolrResourceLoa
der for directory: 'solr/'
2248 [main] INFO org.apache.solr.core.ConfigSolr û Loading container configura
tion from C:\Users\kapel_000\Desktop\solr-4.10.2\example\solr\solr.xml
2323 [main] INFO org.apache.solr.core.CoresLocator û Config-defined core root
directory: C:\Users\kapel_000\Desktop\solr-4.10.2\example\solr
2334 [main] INFO org.apache.solr.core.CoreContainer û New CoreContainer 307272
05
2335 [main] INFO org.apache.solr.core.CoreContainer û Loading cores into CoreC
ontainer [instanceDir=solr/]
2351 [main] INFO org.apache.solr.handler.component.HttpShardHandlerFactory û S
etting socketTimeout to: 0
2352 [main] INFO org.apache.solr.handler.component.HttpShardHandlerFactory û S
etting urlScheme to: null
2359 [main] INFO org.apache.solr.handler.component.HttpShardHandlerFactory û S
etting connTimeout to: 0
2360 [main] INFO org.apache.solr.handler.component.HttpShardHandlerFactory û S
etting maxConnectionsPerHost to: 20
2362 [main] INFO org.apache.solr.handler.component.HttpShardHandlerFactory û S
etting corePoolSize to: 0
2363 [main] INFO org.apache.solr.handler.component.HttpShardHandlerFactory û S
etting maximumPoolSize to: 2147483647
2363 [main] INFO org.apache.solr.handler.component.HttpShardHandlerFactory û S
etting maxThreadIdleTime to: 5
2364 [main] INFO org.apache.solr.handler.component.HttpShardHandlerFactory û S
etting sizeOfQueue to: -1
2365 [main] INFO org.apache.solr.handler.component.HttpShardHandlerFactory û S
etting fairnessPolicy to: false
2596 [main] INFO org.apache.solr.update.UpdateShardHandler û Creating UpdateSh
ardHandler HTTP client with params: socketTimeout=0&connTimeout=0&retry=false
2599 [main] INFO org.apache.solr.logging.LogWatcher û SLF4J impl is org.slf4j.
impl.Log4jLoggerFactory
2601 [main] INFO org.apache.solr.logging.LogWatcher û Registering Log Listener
[Log4j (org.slf4j.impl.Log4jLoggerFactory)]
2603 [main] INFO org.apache.solr.core.CoreContainer û Host Name:
7194 [main] INFO org.apache.solr.core.CoresLocator û Looking for core definiti
ons underneath C:\Users\kapel_000\Desktop\solr-4.10.2\example\solr
7213 [main] INFO org.apache.solr.core.CoresLocator û Found core collection1 in
C:\Users\kapel_000\Desktop\solr-4.10.2\example\solr\collection1\
7215 [main] INFO org.apache.solr.core.CoresLocator û Found core collection1 in
C:\Users\kapel_000\Desktop\solr-4.10.2\example\solr\collection5\
7216 [main] INFO org.apache.solr.core.CoresLocator û Found 2 core definitions
7220 [main] ERROR org.apache.solr.servlet.SolrDispatchFilter û Could not start
Solr. Check solr/home property and the logs
7270 [main] ERROR org.apache.solr.core.SolrCore û null:org.apache.solr.common.S
olrException: Found multiple cores with the name [collection1], with instancedir
s [C:\Users\kapel_000\Desktop\solr-4.10.2\example\solr\collection1\] and [C:\Use
rs\kapel_000\Desktop\solr-4.10.2\example\solr\collection5\]
at org.apache.solr.core.CoreContainer.checkForDuplicateCoreNames(CoreCon
tainer.java:297)
at org.apache.solr.core.CoreContainer.load(CoreContainer.java:241)
at org.apache.solr.servlet.SolrDispatchFilter.createCoreContainer(SolrDi
spatchFilter.java:189)
at org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.ja
va:136)
at org.eclipse.jetty.servlet.FilterHolder.doStart(FilterHolder.java:119)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLife
Cycle.java:64)
at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.ja
va:719)
at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletC
ontextHandler.java:265)
at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.jav
a:1252)
at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandle
r.java:710)
at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:494
)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLife
Cycle.java:64)
at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(Stan
dardStarter.java:39)
at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:1
86)
at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentM
anager.java:494)
at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.j
ava:141)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(Scan
ningAppProvider.java:145)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(Sc
anningAppProvider.java:56)
at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:609)
at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:540)
at org.eclipse.jetty.util.Scanner.scan(Scanner.java:403)
at org.eclipse.jetty.util.Scanner.doStart(Scanner.java:337)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLife
Cycle.java:64)
at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(Scanni
ngAppProvider.java:121)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLife
Cycle.java:64)
at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(Deploymen
tManager.java:555)
at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.
java:230)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLife
Cycle.java:64)
at org.eclipse.jetty.util.component.AggregateLifeCycle.doStart(Aggregate
LifeCycle.java:81)
at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHand
ler.java:58)
at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrappe
r.java:96)
at org.eclipse.jetty.server.Server.doStart(Server.java:280)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLife
Cycle.java:64)
at org.eclipse.jetty.xml.XmlConfiguration$1.run(XmlConfiguration.java:12
59)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:118
2)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.jetty.start.Main.invokeMain(Main.java:473)
at org.eclipse.jetty.start.Main.start(Main.java:615)
at org.eclipse.jetty.start.Main.main(Main.java:96)
7276 [main] INFO org.apache.solr.servlet.SolrDispatchFilter û SolrDispatchFilt
er.init() done
7302 [main] INFO org.eclipse.jetty.server.AbstractConnector û Started SocketCo
nnector#0.0.0.0:8983
Does any of this make any sense? Did I messed up badly (more than once?) or is it something simle I am not aware of?
Here's your error:
7270 [main] ERROR org.apache.solr.core.SolrCore û
null:org.apache.solr.common.S olrException: Found multiple cores with
the name [collection1], with instancedirs
[C:\Users\kapel_000\Desktop\solr-4.10.2\example\solr\collection1] and
[C:\Users\kapel_000\Desktop\solr-4.10.2\example\solr\collection5]
Check your config, you've got the core collection1 configured twice. Once pointing to example\solr\collection1 and once to example\solr\collection5
HTTP ERROR 503
Problem accessing /solr/. Reason:
Server is shutting down or failed to initialize

Jetty + Guice + Jersey gives 404 on accessing the resource

I have seen similar issues and solutions to those, but still cannot figure out the solution to mine.
I start Jetty server programmatically and hook Jersey using Guice into it. When I try to access my Jersey resource, I get 404.
public class TestService {
public static void main(String[] args) throws Exception {
Server server = new Server(8080);
ServletContextHandler context = new ServletContextHandler();
context.setContextPath("/");
server.setHandler(context);
final Injector injector = Guice.createInjector(new MyServletModule());
FilterHolder guiceFilter = new FilterHolder(injector.getInstance(GuiceFilter.class));
context.addFilter(guiceFilter, "/*", EnumSet.allOf(DispatcherType.class));
context.addEventListener(new GuiceServletContextListener() {
#Override
protected Injector getInjector() {
return injector;
}
});
server.start();
server.join();
}
}
class MyServletModule extends ServletModule {
#Override
protected void configureServlets() {
bind(GuiceContainer.class);
Map<String, String> parameters = Maps.newHashMap();
parameters.put(PackagesResourceConfig.PROPERTY_PACKAGES, "com.test");
parameters.put(JSONConfiguration.FEATURE_POJO_MAPPING, "true");
serve("/*").with(GuiceContainer.class, parameters);
}
}
My resource:
#Singleton
#Path("/")
public class MyResource {
#GET
public String sayhello() {
return "hello";
}
}
I can see that the resource is being loaded in the log:
INFO: Root resource classes found:
class com.test.MyResource
But I get 404 on loading http://localhost:8080/. I have also tried mapping the resource to other urls, fx /web, but it was still 404.
And complete log:
2013-07-23 11:06:07,993 [main] DEBUG org.eclipse.jetty.util.log - Logging to org.slf4j.impl.Log4jLoggerAdapter(org.eclipse.jetty.util.log) via org.eclipse.jetty.util.log.Slf4jLog
2013-07-23 11:06:08,114 [main] DEBUG org.eclipse.jetty.util.component.Container - Container org.eclipse.jetty.server.Server#18fef3d + SelectChannelConnector#0.0.0.0:8080 as connector
2013-07-23 11:06:08,131 [main] DEBUG org.eclipse.jetty.util.component.Container - Container org.eclipse.jetty.server.Server#18fef3d + o.e.j.s.ServletContextHandler{/,null} as handler
2013-07-23 11:06:08,425 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - filterNameMap={com.google.inject.servlet.GuiceFilter-1346515=com.google.inject.servlet.GuiceFilter-1346515}
2013-07-23 11:06:08,426 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - pathFilters=[[/*]/[]==31=>com.google.inject.servlet.GuiceFilter-1346515]
2013-07-23 11:06:08,426 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - servletFilterMap={}
2013-07-23 11:06:08,426 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - servletPathMap=null
2013-07-23 11:06:08,427 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - servletNameMap={}
2013-07-23 11:06:08,429 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - starting org.eclipse.jetty.server.Server#18fef3d
2013-07-23 11:06:08,429 [main] INFO org.eclipse.jetty.server.Server - jetty-8.1.0.RC5
2013-07-23 11:06:08,443 [main] DEBUG org.eclipse.jetty.util.component.Container - Container org.eclipse.jetty.server.Server#18fef3d + qtp22355327{8<=0<=0/254,-1} as threadpool
2013-07-23 11:06:08,444 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - starting o.e.j.s.ServletContextHandler{/,null}
2013-07-23 11:06:08,453 [main] DEBUG org.eclipse.jetty.util.component.Container - Container org.eclipse.jetty.servlet.ServletHandler#128f6ee + com.google.inject.servlet.GuiceFilter-1346515 as filter
2013-07-23 11:06:08,453 [main] DEBUG org.eclipse.jetty.util.component.Container - Container org.eclipse.jetty.servlet.ServletHandler#128f6ee + [/*]/[]==31=>com.google.inject.servlet.GuiceFilter-1346515 as filterMapping
2013-07-23 11:06:08,454 [main] DEBUG org.eclipse.jetty.util.component.Container - Container o.e.j.s.ServletContextHandler{/,null} + org.eclipse.jetty.servlet.ServletHandler#128f6ee as handler
2013-07-23 11:06:08,454 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - starting org.eclipse.jetty.servlet.ServletHandler#128f6ee
2013-07-23 11:06:08,454 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - filterNameMap={com.google.inject.servlet.GuiceFilter-1346515=com.google.inject.servlet.GuiceFilter-1346515}
2013-07-23 11:06:08,454 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - pathFilters=[[/*]/[]==31=>com.google.inject.servlet.GuiceFilter-1346515]
2013-07-23 11:06:08,454 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - servletFilterMap={}
2013-07-23 11:06:08,454 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - servletPathMap=null
2013-07-23 11:06:08,454 [main] DEBUG org.eclipse.jetty.servlet.ServletHandler - servletNameMap={}
2013-07-23 11:06:08,454 [main] DEBUG org.eclipse.jetty.server.handler.AbstractHandler - starting org.eclipse.jetty.servlet.ServletHandler#128f6ee
2013-07-23 11:06:08,454 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - STARTED org.eclipse.jetty.servlet.ServletHandler#128f6ee
2013-07-23 11:06:08,455 [main] DEBUG org.eclipse.jetty.server.handler.AbstractHandler - starting o.e.j.s.ServletContextHandler{/,null}
2013-07-23 11:06:08,455 [main] INFO org.eclipse.jetty.server.handler.ContextHandler - started o.e.j.s.ServletContextHandler{/,null}
2013-07-23 11:06:08,455 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - starting com.google.inject.servlet.GuiceFilter-1346515
2013-jul-23 11:06:08 com.sun.jersey.api.core.PackagesResourceConfig init
INFO: Scanning for root resource and provider classes in the packages:
com.test
2013-jul-23 11:06:08 com.sun.jersey.api.core.ScanningResourceConfig logClasses
INFO: Root resource classes found:
class com.test.MyResource
2013-jul-23 11:06:08 com.sun.jersey.api.core.ScanningResourceConfig init
INFO: No provider classes found.
2013-jul-23 11:06:08 com.sun.jersey.server.impl.application.WebApplicationImpl _initiate
INFO: Initiating Jersey application, version 'Jersey: 1.12 02/15/2012 04:51 PM'
2013-07-23 11:06:09,219 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - STARTED com.google.inject.servlet.GuiceFilter-1346515
2013-07-23 11:06:09,219 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - STARTED o.e.j.s.ServletContextHandler{/,null}
2013-07-23 11:06:09,219 [main] DEBUG org.eclipse.jetty.server.handler.AbstractHandler - starting org.eclipse.jetty.server.Server#18fef3d
2013-07-23 11:06:09,219 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - starting qtp22355327{8<=0<=0/254,-1}
2013-07-23 11:06:09,221 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - STARTED qtp22355327{8<=1<=8/254,0}
2013-07-23 11:06:09,222 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - starting SelectChannelConnector#0.0.0.0:8080
2013-07-23 11:06:09,258 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - starting null/null
2013-07-23 11:06:09,260 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - STARTED PooledBuffers [0/1024#6144,0/1024#16384,0/1024#-]/PooledBuffers [0/1024#6144,0/1024#32768,0/1024#-]
2013-07-23 11:06:09,260 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - starting org.eclipse.jetty.server.nio.SelectChannelConnector$ConnectorSelectorManager#20c906
2013-07-23 11:06:09,279 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - STARTED org.eclipse.jetty.server.nio.SelectChannelConnector$ConnectorSelectorManager#20c906
2013-07-23 11:06:09,279 [qtp22355327-10 Selector0] DEBUG org.eclipse.jetty.io.nio - Starting Thread[qtp22355327-10 Selector0,5,main] on org.eclipse.jetty.io.nio.SelectorManager$1#10c3a08
2013-07-23 11:06:09,280 [main] INFO org.eclipse.jetty.server.AbstractConnector - Started SelectChannelConnector#0.0.0.0:8080
2013-07-23 11:06:09,280 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - STARTED SelectChannelConnector#0.0.0.0:8080
2013-07-23 11:06:09,280 [main] DEBUG org.eclipse.jetty.util.component.AbstractLifeCycle - STARTED org.eclipse.jetty.server.Server#18fef3d
2013-07-23 11:06:16,602 [qtp22355327-10 Selector0] DEBUG org.eclipse.jetty.io.nio - created SCEP#cc7439{l(/127.0.0.1:61292)<->r(/127.0.0.1:8080),d=false,open=true,ishut=false,oshut=false,rb=false,wb=false,w=true,i=0}-{AsyncHttpConnection#e2892b,g=HttpGenerator{s=0,h=-1,b=-1,c=-1},p=HttpParser{s=-14,l=0,c=0},r=0}
2013-07-23 11:06:16,604 [qtp22355327-16] DEBUG org.eclipse.jetty.http.HttpParser - filled 0/0
2013-07-23 11:06:16,604 [qtp22355327-10 Selector0] DEBUG org.eclipse.jetty.io.nio - created SCEP#1dd9891{l(/127.0.0.1:61293)<->r(/127.0.0.1:8080),d=false,open=true,ishut=false,oshut=false,rb=false,wb=false,w=true,i=0}-{AsyncHttpConnection#14b6b02,g=HttpGenerator{s=0,h=-1,b=-1,c=-1},p=HttpParser{s=-14,l=0,c=0},r=0}
2013-07-23 11:06:16,604 [qtp22355327-14] DEBUG org.eclipse.jetty.http.HttpParser - filled 0/0
2013-07-23 11:06:16,634 [qtp22355327-17] DEBUG org.eclipse.jetty.http.HttpParser - filled 328/328
2013-07-23 11:06:16,641 [qtp22355327-17 - /] DEBUG org.eclipse.jetty.server.Server - REQUEST / on AsyncHttpConnection#e2892b,g=HttpGenerator{s=0,h=-1,b=-1,c=-1},p=HttpParser{s=-5,l=14,c=0},r=1
2013-07-23 11:06:16,641 [qtp22355327-17 - /] DEBUG org.eclipse.jetty.server.handler.ContextHandler - scope null||/ # o.e.j.s.ServletContextHandler{/,null}
2013-07-23 11:06:16,641 [qtp22355327-17 - /] DEBUG org.eclipse.jetty.server.handler.ContextHandler - context=||/ # o.e.j.s.ServletContextHandler{/,null}
2013-07-23 11:06:16,641 [qtp22355327-17 - /] DEBUG org.eclipse.jetty.servlet.ServletHandler - servlet ||/ -> null
2013-07-23 11:06:16,641 [qtp22355327-17 - /] DEBUG org.eclipse.jetty.servlet.ServletHandler - chain=null
2013-07-23 11:06:16,641 [qtp22355327-17 - /] DEBUG org.eclipse.jetty.servlet.ServletHandler - Not Found /
2013-07-23 11:06:16,647 [qtp22355327-17 - /] DEBUG org.eclipse.jetty.server.Server - RESPONSE / 404
2013-07-23 11:06:16,651 [qtp22355327-17] DEBUG org.eclipse.jetty.http.HttpParser - filled 0/0
2013-07-23 11:06:16,769 [qtp22355327-11] DEBUG org.eclipse.jetty.http.HttpParser - filled 279/279
2013-07-23 11:06:16,770 [qtp22355327-11 - /favicon.ico] DEBUG org.eclipse.jetty.server.Server - REQUEST /favicon.ico on AsyncHttpConnection#e2892b,g=HttpGenerator{s=0,h=-1,b=-1,c=-1},p=HttpParser{s=-5,l=14,c=0},r=2
2013-07-23 11:06:16,770 [qtp22355327-11 - /favicon.ico] DEBUG org.eclipse.jetty.server.handler.ContextHandler - scope null||/favicon.ico # o.e.j.s.ServletContextHandler{/,null}
2013-07-23 11:06:16,771 [qtp22355327-11 - /favicon.ico] DEBUG org.eclipse.jetty.server.handler.ContextHandler - context=||/favicon.ico # o.e.j.s.ServletContextHandler{/,null}
2013-07-23 11:06:16,771 [qtp22355327-11 - /favicon.ico] DEBUG org.eclipse.jetty.servlet.ServletHandler - servlet ||/favicon.ico -> null
2013-07-23 11:06:16,771 [qtp22355327-11 - /favicon.ico] DEBUG org.eclipse.jetty.servlet.ServletHandler - chain=null
2013-07-23 11:06:16,772 [qtp22355327-11 - /favicon.ico] DEBUG org.eclipse.jetty.servlet.ServletHandler - Not Found /favicon.ico
2013-07-23 11:06:16,774 [qtp22355327-11 - /favicon.ico] DEBUG org.eclipse.jetty.server.Server - RESPONSE /favicon.ico 404
2013-07-23 11:06:16,775 [qtp22355327-11] DEBUG org.eclipse.jetty.http.HttpParser - filled 0/0
2013-07-23 11:06:26,564 [qtp22355327-15] DEBUG org.eclipse.jetty.io.nio.ChannelEndPoint - ishut SCEP#1dd9891{l(/127.0.0.1:61293)<->r(/127.0.0.1:8080),d=true,open=true,ishut=false,oshut=false,rb=false,wb=false,w=true,i=1r}-{AsyncHttpConnection#14b6b02,g=HttpGenerator{s=0,h=-1,b=-1,c=-1},p=HttpParser{s=-14,l=0,c=0},r=0}
2013-07-23 11:06:26,564 [qtp22355327-15] DEBUG org.eclipse.jetty.http.HttpParser - filled -1/0
2013-07-23 11:06:26,566 [qtp22355327-15] DEBUG org.eclipse.jetty.io.nio.ChannelEndPoint - close SCEP#1dd9891{l(/127.0.0.1:61293)<->r(/127.0.0.1:8080),d=true,open=true,ishut=true,oshut=false,rb=false,wb=false,w=true,i=1r}-{AsyncHttpConnection#14b6b02,g=HttpGenerator{s=0,h=-1,b=-1,c=-1},p=HttpParser{s=0,l=0,c=0},r=0}
2013-07-23 11:06:26,568 [qtp22355327-10 Selector0] DEBUG org.eclipse.jetty.io.nio - destroyEndPoint SCEP#1dd9891{l(/127.0.0.1:61293)<->r(/127.0.0.1:8080),d=true,open=false,ishut=true,oshut=true,rb=false,wb=false,w=true,i=1!}-{AsyncHttpConnection#14b6b02,g=HttpGenerator{s=0,h=-1,b=-1,c=-1},p=HttpParser{s=0,l=0,c=0},r=0}
2013-07-23 11:06:26,572 [qtp22355327-10 Selector0] DEBUG org.eclipse.jetty.server.AbstractHttpConnection - closed AsyncHttpConnection#14b6b02,g=HttpGenerator{s=0,h=-1,b=-1,c=-1},p=HttpParser{s=0,l=0,c=0},r=0
You need a default servlet. Try adding
context.addServlet(DefaultServlet.class, "/");
after adding your Guice Filter.

Categories

Resources