jonatan-ivanov on 3.1.x
Increase timeout for zipkin sen… (compare)
Hello together!
I am currently developing a Spring Boot application that uses Spring Cloud Stream together with RabbitMQ. I am using Spring Boot version 2.5.3 and Spring Cloud version 2020.0.3.
When I include the dependencies which also provides start.spring.io, I get a NoSuchMethod
error during the start of the service. However, if I manage the org.springframework.integration:spring-integration-amqp
dependency manually, the service starts without problems.
Now I wonder if I am missing something or if this is really a general problem. And if so, for which of the involved projects I should create an issue.
Perhaps @spencergibb can say something about this? :)
Hi , read about issue where a large number of tcp connections are made from clients to gateway. spring-cloud/spring-cloud-gateway#1985 . This was fixed in reactor netty.
However i had a doubt about usage of property 'spring.cloud.gateway.httpclient.pool.max-idle-time' . Does this property achieve the same functionality of removing idle connections.
Registering error with row details + line number + error message
I'm processing a csv file using spring batch. I want to registering error with row details + line number + error message on all the steps wherever the error has been occured. The error may occur in reading stage or file input stage or processing stage or writing stage.
How to do this? Best practice to do this?
Thanks
Hello, everybody! I am currently refactoring my spring cloud application using spring cloud kubernetes together with kubernetes.
I am trying to externalize the properties in application.yml file with configMap and secret with embeded application.yaml file. I wonder if there is a way for Splitting one application.yml file into embeded application.yaml file in configMap and embeded application.yaml file in secret. something like:
application.yml
spring:
profiles: development
greeting:
message: Say Hello to the Developers
datasource:
url: xxxd
username: xxxd
password: xxxd
driver-class-name: xxxd
---
spring:
profiles: production
greeting:
message: Say Hello to the Ops
datasource:
url: xxxp
username: xxxp
password: xxxp
driver-class-name: xxxp
ConfigMap:
kind: ConfigMap
apiVersion: v1
metadata:
name: myconfig
data:
application.yml: |-
spring:
profiles: development
greeting:
message: Say Hello to the Developers
---
spring:
profiles: production
greeting:
message: Say Hello to the Ops
Secret:
apiVersion: v1
kind: Secret
metadata:
name: mysecret
type: Opaque
stringData:
application.yml: |-
spring:
profiles: development
datasource:
url: xxxd
username: xxxd
password: xxxd
driver-class-name: xxxd
---
spring:
profiles: production
datasource:
url: xxxp
username: xxxp
password: xxxp
driver-class-name: xxxp
spring cloud kubernetes config:
spring:
application:
name: cloud-k8s-app
cloud:
kubernetes:
secrets:
namespace: default-namespace
sources:
- name: mysecret
config:
namespace: default-namespace
sources:
- name: myconfig
can spring cloud kubernetes automatically combine two parts of applicaton.yml (in configmap and secret respectively)?
Can someone help me with a good link to do the following using Spring Integration Outbound Adapter?
#1 - Write an API, when user hits the API where csv is input for the API - process via spring
integration and send it FTP server (OR)
#2 - Write an API, when user hits the API - fetch the new daily records from DB - write it to
a csv file and send it to the FTP server via Spring Integration Outbound Adapter
Thanks
Spring Application Is A Micro-Service? A confusion
One of my friend creates separate spring boot application for each functions or modules and run as a separate application and calling it as micro-service
I told him is that the microservice? There is a confusion how to treat a application or a service as micro-service
When i searched internet, i observed authentication would be in a separate service...All microservice will run independently
Can some experts give a good back around of micro-service or characteristics of micro-service to clarify the confusions
Thanks
Hi,
I have issue with custom health indicators / health contributors in application.
I'm using Spring Boot 2.5.5, Spring Cloud 2020.0.4 and Netflix Eureka for service registry/discovery.
If my HealthIndicator
returns status DOWN
/OUT_OF_SERVICE
, then also 'eureka' health check in 'discoveryComposite' is DOWN
/OUT_OF_SERVICE
and service instance is not visible to other services, but if I implement it as CompositeHealthContributor
and it also has status DOWN
/OUT_OF_SERVICE
, 'eureka' health has status 'UP' and service is visible to other services.
Is this expected behaviour?
Hi, how come my tests fail when I use org.springframework.cloud:spring-cloud-starter-kubernetes-client
and org.springframework.cloud:spring-cloud-starter-consul-discovery
despite me having spring.cloud.{kubernetes,consul}.enabled=false
?
If it's just consul discovery and spring.cloud.consul.enabled=false
it works.
The error:
AccountServiceTest > lock_whenUserRequestLock_userShouldBeMarkedAsLocked() FAILED
java.lang.IllegalStateException at DefaultCacheAwareContextLoaderDelegate.java:132
Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException at ConstructorResolver.java:800
Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException at DefaultListableBeanFactory.java:1790
spring.cloud.kubernetes.discovery.enabled=false
io.awspring.cloud:spring-cloud-starter-aws-messaging
and de.idealo.spring:spring-cloud-stream-binder-sqs
, but these don’t seem to have documentation supporting the spring cloud function capabilities. do these packages all work in harmony?
${spring.cloud.client.hostname}
it's the ip address of the network interface and not the local hostname?
Greetings All,
I'm in the process of migrating to SpringBoot 2.5.6 and also to spring-cloud-starter-loadbalancer. I'm not using the Eureka service registry in my system but instead configuring a list of servers in our external configuration.
springBootVersion=2.5.6
springCloudVersion=2020.0.4
implementation 'org.springframework.cloud:spring-cloud-starter-openfeign'
implementation 'org.springframework.cloud:spring-cloud-starter-loadbalancer'
productservice:
ribbon:
listOfServers: https://product.service.mycompany.com
RoundRobinLoadBalancer : No servers available for service: productservice
FeignBlockingLoadBalancerClient : Load balancer does not contain an instance for the service productservice
What I understand from the logs is that the problem here is with the creation of a client-side load balancer which is needed for the FeignClient to work.
Can someone here help me with the config that will be needed in the case where you are not using the Eureka service registry?
Hi Team,
I am facing issue with springencoder in the new version of open feing. It used work fine with earlier versions of spring cloud.
When I debuuged the code, I found this additional code has been added in the new version of SpringEncoder
if (Objects.equals(requestContentType, MediaType.MULTIPART_FORM_DATA)) {
this.springFormEncoder.encode(requestBody, bodyType, request);
return;
}
Earlier my code was using AllEncompassingFormHttpMessageConverter(SpringCloud 2.2.1) when i submitted multivalue map(MULTIFORM_DATA) but now it breaks with new version.
I'm working on implementing some new stream processors (PubSub binder) and using spring-boot 2.5.6, with spring-cloud 2020.0.4.
We collect traces with zipkin and I'm noticing that the applications I have built with these latest versions are not getting b3
message attributes attached, so the traceId isn't propagated through like it does with our previously created applications based on spring-boot 2.3.6 and spring-cloud Horsham.SR10.
My "guess" is that I'm missing a dependency that is necessary to get this all wired together that wasn't needed two releases ago? I have the following explicit spring dependencies:
implementation 'org.springframework.boot:spring-boot-starter-actuator'
implementation 'org.springframework.boot:spring-boot-starter-data-redis-reactive'
implementation 'org.springframework.cloud:spring-cloud-sleuth-zipkin'
implementation 'org.springframework.cloud:spring-cloud-starter-sleuth'
implementation 'org.springframework.cloud:spring-cloud-stream'
implementation 'com.google.cloud:spring-cloud-gcp-pubsub-stream-binder'
I'm sure it's documented somewhere, but I'm not finding it. Could I get a pointer in the right direction?
Hello room! In Cloud Config 3.1 RC1, has anything changed that would affect property-source loading, bootstrap context and the like? I am seeing a scenario where bootstrap environment and context is initialized from property sources, but actual application context/environment is not post-processed. It's as if the event listener that does the post processing of the environment never kicks into action for the application context/environment.
I see the two Environemnts created, and the Bootstrap environment is post-processed via the appropriat listener, but it seems like it gets in the way of the actual (servlet) application context. Beans are then created using the Bootstrap context property sources and none of the property sources that are profile-based are not actually read at the right time. They are read later, once after the context has initialized and beans are created, which is too late.
I am running this with Spring Boot 2.6 RC1 and Spring Cloud 3.1 RC1.
includeProfileSpecificSources
but i wasn't able to properly disable it. here's my bootstrap: https://gist.github.com/marcguilera/b73e2b0d9b5367ac1da7c0e10a7e2f4b
Hi, everyone. I'd like to ask for an advice regarding Spring Cloud Consul service discovery and Kubernetes. We are running containers with Spring Boot in AWS EKS. We have an issue with correctly unregistering the instance from Consul when a pod with running container is being deleted. Once the application receives SIGTERM it is given 30 seconds period to shut down gracefully. My observation from logs is that the application tries to unregister from Consul right after receiving the signal, but is unable to make a new connection to Consul even when it still has plenty of time to shut down.
2021-11-30 21:28:51.374 WARN [printer,,,] 1 --- [extShutdownHook] .s.c.a.CommonAnnotationBeanPostProcessor : Destroy method on bean with name 'consulAutoServiceRegistration' threw an exception: com.ecwid.consul.transport.TransportException: org.apache.http.NoHttpResponseException: consul-server.consul.svc.cluster.local:8500 failed to respond
Did you run into similar issue before? I would welcome any advice.
Hello everyone, I'm facing an issue with HTTP source app in a spring cloud data flow stream.
org.springframework.core.io.buffer.DataBufferLimitException: Exceeded limit on max bytes to buffer : 262144
at org.springframework.core.io.buffer.LimitedDataBufferList.raiseLimitException(LimitedDataBufferList.java:98) ~[spring-core-5.3.10.jar:5.3.10]
Suppressed: reactor.core.publisher.FluxOnAssembly$OnAssemblyException:
Error has been observed at the following site(s):
|_ checkpoint ? org.springframework.security.web.server.authorization.AuthorizationWebFilter [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.security.web.server.authorization.ExceptionTranslationWebFilter [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.security.web.server.authentication.logout.LogoutWebFilter [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.security.web.server.savedrequest.ServerRequestCacheWebFilter [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.security.web.server.context.SecurityContextServerWebExchangeWebFilter [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.security.web.server.context.ReactorContextWebFilter [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.security.web.server.header.HttpHeaderWriterWebFilter [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.security.config.web.server.ServerHttpSecurity$ServerWebExchangeReactorContextWebFilter [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.security.web.server.WebFilterChainProxy [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.cloud.sleuth.instrument.web.TraceWebFilter [DefaultWebFilterChain]
|_ checkpoint ? org.springframework.boot.actuate.metrics.web.reactive.server.MetricsWebFilter [DefaultWebFilterChain]
|_ checkpoint ? HTTP POST "/" [ExceptionHandlingWebHandler]
This happens when I try to post a HTTP request with huge body size to the HTTP end point.
I have tried setting following property in the deployment which didn't help me:
app.http.spring.codec.max-in-memory-size: 10MB
spring cloud starter http kafka source app version used is 3.1.1
Do anyone have a clue about how to fix this?
spring-cloud-dependencies
compatibility for SB2.6.x
? The compatibility table on https://spring.io/projects/spring-cloud still doesn’t refer SB2.6.x
: