Spring framework ERROR 10904 [closed] - java

Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 6 years ago.
Improve this question
I was trying to build an application using the Spring framework but I got the following errors and am not sure why.
Whenever I try to run the application I get the bellow errors. I did set up my Maven in C drive and my application in D drive due to space. Can that be an issue?
What is causing the errors and how should I go about them?
ERROR 10904 --- [ main] o.a.coyote.http11.Http11NioProtocol : Failed to start end point associated with ProtocolHandler ["http-nio-8080"]
ERROR 10904 --- [ main] o.apache.catalina.core.StandardService : Failed to start connector [Connector[HTTP/1.1-8080]]
ERROR 10904 --- [ main] o.s.boot.SpringApplication : Application startup failed
INFO 10904 --- [ main] .b.l.ClasspathLoggingApplicationListener : Application failed to start with classpath: [file:/D:/GITHUB/webappaws/target/classes/, file:/C:/Users/codeLearner/.m2/repository/org/springframework/boot/spring-boot-starter-thymeleaf/1.3.6.RELEASE/spring-boot-starter-thymeleaf-1.3.6.RELEASE.jar, file:/C:/Users/codeLearner/.m2/repository/org/springframework/boot/spring-boot-starter/1.3.6.RELEASE/spring-boot-starter-1.3.6.RELEASE.jar, file:/C:/Users/codeLearner/.m2/repository/org/springframework/boot/spring-boot/1.3.6.RELEASE/spring-boot-1.3.6.RELEASE.jar, file:/C:/Users/codeLearner/.m2/repository/org/springframework/boot/spring-boot-autoconfigure/1.3.6.RELEASE/spring-boot-autoconfigure-1.3.6.RELEASE.jar, file:/C:/Users/codeLearner/.m2/repository/org/springframework/boot/spring-boot-starter-logging/1.3.6.RELEASE/spring-boot-starter-logging-1.3.6.RELEASE.jar, file:/C:/Users/codeLearner/.m2/repository/ch/qos/logback/logback-classic/1.1.7/logback-classic-1.1.7.jar, file:/C:/Users/codeLearner/.m2/repository/ch/qos/logback/logback-core/1.1.7/logback-core-1.1.7.jar, ...

Solved
What I did when launching the application was instead of relaunching it, I ran it and that's what cause the problem (I think)
When I go open localhost:8080 it displays what it should.
I am learning, which does counts for stupid mistakes and I learn with every new feedback .. not sure why I was voted down though...
Thank you Luke and Jim!

Related

Dataloader for Salesforce while running it, I get the following error, if anyone can please explain what's wrong?

the error is as Follows:
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
2022-07-08 12:10:35,625 INFO [main] controller.Controller initLog (Controller.java:472) - The log has been initialized
Unable to find SWT jar for Windows 10 : x86
salesforce dataloader running error

Springboot Couchbase Application can not be deployed in windows [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 2 years ago.
Improve this question
I am developing a Springboot application which connects to a remote Couchbase server to fetch data. The application is working fine for the local Couchbase server in my machine. But when I configured the API properties for the remote database, it throws a java.util.concurrent.TimeoutException. Following given is my error log.
2020-08-31 08:50:50.596 WARN 12692 --- [ main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'fileUploadController': Unsatisfied dependency expressed through field 'predictionService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'predictionServiceImpl': Unsatisfied dependency expressed through field 'predictionDao'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'predictionDaoImpl': Unsatisfied dependency expressed through field 'predictionRepository'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'couchbaseRepositoryOperationsMapping' defined in class path resource [com/example/couchbaseService/Configuration/CouchbaseConfiguration.class]: Unsatisfied dependency expressed through method 'repositoryOperationsMapping' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'couchbaseTemplate' defined in class path resource [com/example/couchbaseService/Configuration/CouchbaseConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.couchbase.core.CouchbaseTemplate]: Factory method 'couchbaseTemplate' threw exception; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'couchbaseBucket' defined in class path resource [com/example/couchbaseService/Configuration/CouchbaseConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.couchbase.client.java.Bucket]: Factory method 'couchbaseClient' threw exception; nested exception is java.lang.RuntimeException: java.util.concurrent.TimeoutException
2020-08-31 08:50:50.642 INFO 12692 --- [ main] c.c.client.core.env.CoreEnvironment : Shutdown kvIoPool: success
2020-08-31 08:50:50.645 INFO 12692 --- [ main] c.c.client.core.env.CoreEnvironment : Shutdown viewIoPool: success
2020-08-31 08:50:50.652 INFO 12692 --- [ main] c.c.client.core.env.CoreEnvironment : Shutdown queryIoPool: success
2020-08-31 08:50:50.656 INFO 12692 --- [ main] c.c.client.core.env.CoreEnvironment : Shutdown searchIoPool: success
2020-08-31 08:50:50.659 INFO 12692 --- [ main] c.c.client.core.env.CoreEnvironment : Shutdown Core Scheduler: success
2020-08-31 08:50:50.659 INFO 12692 --- [ Thread-5] c.c.client.core.env.CoreEnvironment : Shutdown Netty: success
2020-08-31 08:50:50.662 INFO 12692 --- [ main] c.c.client.core.env.CoreEnvironment : Shutdown Runtime Metrics Collector: success
2020-08-31 08:50:50.666 INFO 12692 --- [ main] c.c.client.core.env.CoreEnvironment : Shutdown Latency Metrics Collector: success
2020-08-31 08:50:50.683 INFO 12692 --- [ cb-io-1-2] c.c.client.core.endpoint.Endpoint : [][KeyValueEndpoint]: Got notified from Channel as inactive, attempting reconnect.
2020-08-31 08:50:50.690 INFO 12692 --- [entExecutor-2-2] c.c.client.core.env.CoreEnvironment : Shutdown IoPool: success
2020-08-31 08:50:50.703 INFO 12692 --- [ main] o.apache.catalina.core.StandardService : Stopping service [Tomcat]
As I couldn't figure out the cause, I tested the API in different windows machines and all attempts gave the same error. But, API successfully starts in a MacOS machine and works fine. I am using Java 11 and Couchbase enterprise edition 6.5.0. My springboot version is 2.0.1. Can anyone help me on this to figure out the cause? Thank you.
If you claim that it works on a Mac, and there's no problem with the code, then the problem could be with your corporate networking policy. Often times, companies have different profiles for Windows than Macs. It could also be a firewall/antivirus blocking outgoing traffic on your PC that Mac doesn't have.
To verify this theory, run a Couchbase server locally on your PC and see if you can connect to it.

Cant run spring boot application?

I'm working on an assignment with a team. And my team decided to use spring boot for the application. However for some reason whenever I run the application I get a different message on my terminal whereas my teammates have a different message on their terminal. Instead of "LiveReload server is running on port 35729" They get "tomcat initialized with port(s) 8081 (http)".
I am not sure what exactly to do since all of us are using the same project and I have built it as they told me to do so.
However it is still not working for me. Can anybody tell me how to fix it so I could get it to run. I have never used maven or spring boot before.
This is the message I am getting on my terminal
2020-06-13 23:05:35.538 INFO 34396 --- [ restartedMain] com.rest.WebApplication : Starting WebApplication on DESKTOP-1M4A445 with PID 34396 (Directory\project\target\classes started by USER in Directory/project)
2020-06-13 23:05:35.543 INFO 34396 --- [ restartedMain] com.rest.WebApplication : No active profile set, falling back to default profiles: default
2020-06-13 23:05:35.609 INFO 34396 --- [ restartedMain] .e.DevToolsPropertyDefaultsPostProcessor : Devtools property defaults active! Set 'spring.devtools.add-properties' to 'false' to disable
2020-06-13 23:05:36.520 INFO 34396 --- [ restartedMain] o.s.b.d.a.OptionalLiveReloadServer : LiveReload server is running on port 35729
2020-06-13 23:05:36.550 INFO 34396 --- [ restartedMain] com.rest.WebApplication : Started WebApplication in 1.452 seconds (JVM running for 2.035)
Process finished with exit code 0
Thank you so much.
It seems you have spring-boot-devtools dependency in the classpath. Because of this you see LiveReload server is running on port 35729 statement written to log.
From your logs, it seems tomcat is not started at all. Verify your properties files and make sure web environment is not turned off
For spring-boot 1.x, look for spring.main.web-environment=false property
For spring-boot 2.x, look for spring.main.web-application-type=none property

Do Azure Container Instances (Windows) support access to Table Storage

I have a container instance (Windows) running a spring-boot application that accesses azure table storage from within a spring-boot CommandLineRunner. The container runs fine locally (Docker / Win10 Pro).
When I deploy to a container instance, a StorageException is thrown at the point that an attempt is made to retrieve a DynamicTableEntity from a table. The connection to the storage account and the table appear to succeed, but the retrieve operation fails. The Tomcat server is running and responsive (I catch the exception and prepare basic error information to be returned by servlets that manage requests). I have been unable to find any examples or definitive statements about using the Java Azure storage libraries in containers, so I would like to know if there are any restrictions, or work-arounds if necessary.
Below are logs which indicate where the exception is thrown.
Log entries with "CommandLineRunner" are generated by my code.
Line 397 in my application is the line where I attempt to retrieve a DynamicTableEntity from the table (14 lines into the log). Prior to that, the connection string is parsed without error, and a reference to the table is generated without error. Although not shown, I am satisfied that the partitionKey and RowKey are correct (and the exception is because the table does not exist - but it does, and is accessible when the container is run locally). Line 562 is the entry point of the spring-boot CommandLineRunner.
**2019-05-13 00:57:44.632 INFO 3060 --- [ main] a.c.n.sbtest.demo.DemoApplication : CommandLineRunner: Engine Intialization Ready (status: 0)**
2019-05-13 00:57:44.670 INFO 3060 --- [ main] a.c.n.sbtest.demo.DemoApplication : CommandLineRunner: Deployment table <Deployments> accessible
2019-05-13 00:57:44.687 INFO 3060 --- [ main] a.c.n.sbtest.demo.DemoApplication : CommandLineRunner: User <e7c6163e-8c06-4146-b0e4-78fec93e6cce> Container accessible
2019-05-13 01:00:17.755 INFO 3060 --- [nio-8080-exec-7] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring DispatcherServlet 'dispatcherServlet'
2019-05-13 01:00:17.755 INFO 3060 --- [nio-8080-exec-7] o.s.web.servlet.DispatcherServlet : Initializing Servlet 'dispatcherServlet'
2019-05-13 01:00:17.768 INFO 3060 --- [nio-8080-exec-7] o.s.web.servlet.DispatcherServlet : Completed initialization in 13 ms
com.microsoft.azure.storage.StorageException:
at com.microsoft.azure.storage.StorageException.translateException(StorageException.java:87)
at com.microsoft.azure.storage.core.ExecutionEngine.executeWithRetry(ExecutionEngine.java:209)
at com.microsoft.azure.storage.table.QueryTableOperation.performRetrieve(QueryTableOperation.java:178)
at com.microsoft.azure.storage.table.TableOperation.execute(TableOperation.java:694)
at com.microsoft.azure.storage.table.CloudTable.execute(CloudTable.java:529)
at com.microsoft.azure.storage.table.CloudTable.execute(CloudTable.java:496)
at **ai.com.neuralstudio.sbtest.demo.DemoApplication.lambda$commandLineRunner$0(DemoApplication.java:562)**
at org.springframework.boot.SpringApplication.callRunner(SpringApplication.java:813)
at org.springframework.boot.SpringApplication.callRunners(SpringApplication.java:797)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:324)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1260)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1248)
at **ai.com.neuralstudio.sbtest.demo.DemoApplication.main(DemoApplication.java:397)**
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:50)
at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:51)
Caused by: java.net.UnknownHostException: neuralstudiotest002.table.core.windows.net
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at sun.security.ssl.SSLSocketImpl.connect(SSLSocketImpl.java:673)
at sun.net.NetworkClient.doConnect(NetworkClient.java:175)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
at sun.net.www.protocol.https.HttpsClient.<init>(HttpsClient.java:264)
at sun.net.www.protocol.https.HttpsClient.New(HttpsClient.java:367)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(AbstractDelegateHttpsURLConnection.java:191)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1156)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1050)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:177)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1564)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:480)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(HttpsURLConnectionImpl.java:347)
at com.microsoft.azure.storage.core.ExecutionEngine.executeWithRetry(ExecutionEngine.java:115)
... 19 more
2019-05-13 01:00:29.420 ERROR 3060 --- [ main] a.c.n.sbtest.demo.DemoApplication : CommandLineRunner: StorageException com.microsoft.azure.storage.StorageException: (status: -3)
I would greatly appreciate any insights into what might be going on.
Jack
UPDATE:
While the underlying issue is unresolved for recent Windows container images, jakaruna-MSFT responded in another forum and pointed out that an older image
mcr.microsoft.com/windows/servercore:1607-KB4505052-amd64
would work, and it does. The underlying issue is apparently related to DNS services, and was either broken or omitted in transitions to more recent images. Presumably MS will get around to fixing the later images, with or without explanation.
See UPDATE above.
While the underlying issue is unresolved for recent Windows container images, jakaruna- MSFT responded in another forum and pointed out that an older image
mcr.microsoft.com/windows/servercore:1607-KB4505052-amd64
would work, and it does.
The underlying issue is apparently related to DNS services, and was either broken or omitted in transitions to more recent images. Presumably MS will get around to fixing the later images, with or without explanation.

Activiti + Spring Boot + Gradle build hangs while gradle clean test

I am having an issue with executing gradle clean test command.
My application is using activiti for workflow.
Git url: https://github.com/sanelib/eBOSS/tree/merge-before-dev
Branch: "merge-before-dev" is having more tests for activiti worflow process. But it execute only 6 of 12 integration tests from "core" module. If I use #Ignore to any random 6 tests then it success for rest 6. I have put some console out to debug and found it hangs on starting activiti process.
This source has also included database schema in /scripts folder. Let me know if you miss any required file for testing in your environment.
Can anybody look into this and give me solution?
I got also result: 23 tests completed, 14 failed :core:test FAILED
Than I randomly picked one of your tests and it failed in isolation also. It doesn't seem to be concurrency problem.
Root cause seem to be this:
2016-02-05 20:56:16.556 WARN 16072 --- [ main] o.h.e.jdbc.internal.JdbcServicesImpl : HHH000342: Could not obtain connection to query metadata : Cannot create PoolableConnectionFactory (Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.)
Place break-point on this line in Hibernate.
So it does seem to be connection problem.

Categories