I have the same issue as below. A very simple Hystrix spring boot application failing to load actuator /hystrix.stream.
Application uses Spring boot starter parent 1.5.x and hystrix 1.5.x libs. It worked well with Spring boot 1.3.x. Other actuators are good.
There's seems to be a known problem with 1.4.x and 1.5.x, however I'm looking for some workaround. Please don't suggest solutions for Spring boot 2.0.x.
From the github issue:
https://github.com/Netflix/Hystrix/issues/1566
We are using the Spring boot starter parent 1.5.2.RELEASE and hystrix 1.5.6 dependencies.
Fortunately it works once in hundred tries. We are really puzzled, why it works once and then never. All the services are running on the local machine.
The log details are as below:
Proxy opening connection to: http://localhost:6001/hystrix.stream
2017-05-05 12:29:16.951 INFO 4876 --- [nio-6001-exec-5] ashboardConfiguration$ProxyStreamServlet :
Proxy opening connection to: http://localhost:6001/hystrix.stream
2017-05-05 12:31:36.163 INFO 4876 --- [trap-executor-0] c.n.d.s.r.aws.ConfigClusterResolver : Resolving eureka endpoints via configuration
If we try to curl the end point instead of getting back a snapshot of data, we get
Previous versions of Spring-boot 1.3.x did not have an issue. At first sight, this seems to be an incompatibility with Spring-boot or one of it's dependencies since our team had not had issues until a recent upgrade with Hystrix.
Noteworthy comment is that all other parts of Hystrix are working just fine. RequestLog, and at least Circuit Breaking are working as designed. For some reason the Hystrix Streaming Servlet is no longer functional for us.
The symptoms we receive for this issue are as follows:
Unable to connect to Command Stream (per description of ticket)
Access log receives 503 http status entry for hystrix.stream end point
Related
I'm using jsonrpc4j library to handle my jsonrpc api. After migrating to new release of SpringBoot 3.0.0 it builds, but fails on run with an error of RemoteExporter:
ERROR 22396 --- [ main] o.s.boot.SpringApplication : Application run failed
java.lang.NoClassDefFoundError: org/springframework/remoting/support/RemoteExporter
as jsonrpc4j uses it in it.
The reason seems to me in a version of Spring Context which comes with SpringBoot 3.0.0 dependency. org.springframework.remoting package is lack of .support package in that version.
Is there any way to avoid the issue?
It looks like org.springframework.remoting was removed in Spring 6 (see Drop RPC-style remoting: Hessian, HTTP Invoker, JMS Invoker, JAX-WS #27422). In Spring 5.3, the subclasses of RemoteExporter are marked deprecated (see Deprecate remoting technologies support #25379), but interestingly enough, RemoteExporter itself wasn't marked as such, but it has been removed anyway. You'll need to find a replacement library or ask the developers of jsonrpc4j to provide a version which supports Spring 6/Spring Boot 3.
I'm trying to update my project Spring Boot version from 2.4.13 to 2.6.12
We were using Spring Cloud 2020.0.0-M6 and I also wanted to bump the version to 2021.0.4
Now my application won't load its remote configuration even though I can see in the logs that it finds the service and the configuration!!
In the above picture you can see my app does find the config-service once deployed to our Development environment.
And after that, it throws me an error because it's trying to use its local configuration where I'm using Environment Variables set from my IDE, using the following syntax ${var}, to replace the value depending on the Run/Debug Configuration.
In the meantime, I'm trying to use Spring Boot 2.6.11 with Spring Cloud 2021.0.4. If I can't get it to work I will have to downgrade it to the last working version until I find the problem.
Any help is appreciated!
Thanks
I am trying to upgrade my web application that is running on Spring boot 1.3.5-Release to 2.7.1. The ultimate goal for this is to implement OIDC authentication in my web app.
The below are the current versions used
<spring.boot.version>1.3.5.RELEASE</spring.boot.version>
<spring.version>4.1.3.RELEASE</spring.version>
<spring.integration.version>4.1.3.RELEASE</spring.integration.version>
<org.hibernate.version>4.3.10.Final</org.hibernate.version>
<aspectj.version>1.8.7</aspectj.version>
To implement OIDC authentication I am supposed to use OAuth2 client dependency. To use this dependency I need to use Spring Security version 5.x.x(I guess so - correct me plz). With these lower versions how can I implement the thing I wanted?
I just tried to upgrade Spring boot to 2.7.1 by resolving some multiple build issues. But finally while running the application I am getting the below error.
2022-10-26 21:26:31.251 INFO 14788 --- [main] o.s.core.annotation.MergedAnnotation : Failed to introspect annotations on public org.springframework.transaction.PlatformTransactionManager org.springframework.boot.autoconfigure.orm.jpa.JpaBaseConfiguration.transactionManager(org.springframework.beans.factory.ObjectProvider): java.lang.ArrayStoreException: sun.reflect.annotation.TypeNotPresentExceptionProxy
What am I missing here?? What is the minimum version of Spring and Springboot that I need to use for implementing OIDC Auth??
framework Spring Authorization Server maybe better for OIDC implementation.
I am upgrading a Spring Boot application from version 1.5.6 to 2.1.1. When I start the application, it gets stuck at this line:
INFO: Initializing Spring DispatcherServlet 'dispatcherServlet'
When I hit this URL: http://localhost:8888/actuator/health, I get {"status":"UP"}
Also when I hit this URL: http://localhost:8888/swagger-ui.html, I see the Swagger UI.
But my main application doesn’t start. Any idea why it’s stuck?
You have just to exclude security auto configuration.
Just add on your main SpringbootApplication
#SpringBootApplication(exclude = SecurityAutoConfiguration.class)
I was facing the same issue. Below code was already a part of my application's main class.
#SpringBootApplication(exclude = SecurityAutoConfiguration.class)
I could not see any logs saying that application has started or anything as such. I had logging level to DEBUG.
logging:
level:
root: ERROR
org:
springframework: DEBUG
But when I tried hitting my APIs from localhost, it could get expected response. The application was running on port 8080 in my case.
I know its old.
I was stuck similarly when I tried to move from SpringBoot 1.5 to 2.
What fixed it for me was when I added
#SpringBootApplication(exclude = { SecurityAutoConfiguration.class })
based on differences in springboot2 and this springboo2 security tutorial . Spring 2 migration guide -> 2
I've created a spring boot project and deployed it on a vm. I've added a command in local.rc that starts the spring boot application on reboot. I want to check whether the command got executed and the application is running. How do I do that?
There are two ways
On system level - you can run your project as a service, which is documented in the Official documentation - Deployments. Then you can query the application status service myapp status.
On application level - include Spring Boot Actuator in your app and use the Actuator endpoints such as /actuator/health as per Official documentation - Production Ready Endpoints. These endpoints can be exposed via HTTP or JMX.
Note: prior to spring boot 2.0 the actuator endpoint is /health
If it's a web project, it makes sense to include spring-boot-actuator (just add a dependency in maven and start the microservice).
In this case, it will automatically expose the following endpoint (for example, its actually can be flexibly set up):
http://<HOST>:<PORT>/health
Just issue an HTTP GET request, and if you get 200 - it's up and running.
If using an actuator is not an option (although it should be really addressed as a first bet), then you can merely telnet to http://<HOST>:<PORT>
The ratio behind this is that that PORT is exposed and ready to "listen" to external connections only after the application context is really started.