spencergibb on main
Bumping versions Bumping versions Bumping versions and 3 more (compare)
spencergibb on jenkins-releaser-config
Updates versions (compare)
spencergibb on 2021.0.x
Updates versions (compare)
spencergibb on 2021.0.x
Updates versions (compare)
spencergibb on jenkins-releaser-config
Updates 2021_0_4-snapshot.prope… (compare)
spencergibb on 3.1.x
Update SNAPSHOT to 3.1.2 Updates to latest snapshot vers… (compare)
spencergibb on 3.1.x
Update SNAPSHOT to 3.1.3 Merge tag 'v3.1.3' into 3.1.x Bumps to next snapshot version (compare)
spencergibb on 3.1.x
Update SNAPSHOT to 3.1.1 Bumps to next snapshot version (compare)
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
:
hello,
I'm wondering how to expand values in Spring Cloud Config server with vault:
For example, if I add this configuration:
env_name: "test-sandbox3"
redis:
host: "{vault}:applications/{env_name}#redis_host"
it will throw Cannot resolve key: redis.host (class java.lang.IllegalArgumentException: Not enough variable values available to expand 'env_name')
Is it possible to force the config server to evaluate the vault path first ?
cloud:
config:
server:
git:
uri: ssh://cloud-user@10.0.0.195/git/config-server
ignore-local-ssh-settings: true
clone-on-start: true
private-key: | (it is correct)
Caused by: com.jcraft.jsch.JSchException: failed to send channel request
at com.jcraft.jsch.Request.write(Request.java:65) ~[jsch-0.1.55.jar:na]
at com.jcraft.jsch.RequestEnv.request(RequestEnv.java:52) ~[jsch-0.1.55.jar:na]
at com.jcraft.jsch.ChannelSession.sendRequests(ChannelSession.java:222) ~[jsch-0.1.55.jar:na]
at com.jcraft.jsch.ChannelExec.start(ChannelExec.java:41) ~[jsch-0.1.55.jar:na]
at com.jcraft.jsch.Channel.connect(Channel.java:152) ~[jsch-0.1.55.jar:na]
at org.eclipse.jgit.transport.JschSession$JschProcess.<init>(JschSession.java:159) ~[org.eclipse.jgit.ssh.jsch-5.12.0.202106070339-r.jar:5.12.0.202106070339-r]
hello,
in cloud-gateway I have a couple of routes defined, but would like to configure rate limited individually for different paths within one route
for example I have
routes:
- id: user
uri: http://localhost:8100/user
predicates:
- Path=/user/**
- id: management
uri: http://localhost:8110/management
predicates:
- Path=/management/**
but I want to configure different rate limits for /management/users
and /management/permissions
the problem I have is that I need to duplicate uri
for each of the paths.
is it possible to override only filter for a child sub-path but keep the rest of the config as is?
Hello everyone, I need your help pls
Jar working on EC2 but not on Lambda
On Lambda :-
13:50:33.867 [main] ERROR org.springframework.cloud.stream.binding.BindingService - Failed to create consumer binding; retrying in 30 seconds
13:50:33.867 [main] ERROR org.springframework.cloud.stream.binding.BindingService - Failed to create producer binding; retrying in 30 seconds
Operation is a varaiable which the kafka message has but its going as NULL to lambda but same message going to EC2 instance corrrectly.
On EC2 :-
the jar is working perfectly.
Mode of deployment: CloudFormation
I have a doubt Is this issue because of maven-shaded plugin
Actual plugin :-
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>${version.spring.boot}</version>
<configuration>
<jvmArguments>
-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=${debug.suspend},address=${debug.port}
</jvmArguments>
<arguments>
<argument>
--spring.config.additional-location=${user.home}/etc/${project.groupId}/${project.artifactId}/conf/application.yml
</argument>
</arguments>
<layout>JAR</layout>
</configuration>
<executions>
<execution>
<id>repackage</id>
<goals>
<goal>repackage</goal>
</goals>
<configuration>
<mainClass>XXXXXXX</mainClass>
<layout>JAR</layout>
</configuration>
</execution>
</executions>
</plugin>
I changed it to (for AWS LAMBDA Deployment)
Note:- Even after changing It was working on EC2
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.2.4</version>
<configuration>
<createDependencyReducedPom>false</createDependencyReducedPom>
<shadedArtifactAttached>true</shadedArtifactAttached>
<shadedClassifierName>aws</shadedClassifierName>
</configuration>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>2.4.1</version>
</dependency>
</dependencies>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<filters>
<filter>
<artifact>*:*</artifact>
<excludes>
<exclude>**/Log4j2Plugins.dat</exclude>
</excludes>
</filter>
</filters>
<transformers>
<transformer implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
<resource>META-INF/spring.handlers</resource>
</transformer>
<transformer implementation="org.springframework.boot.maven.PropertiesMergingResourceTransformer">
<resource>META-INF/spring.factories</resource>
</transformer>
<transformer implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
<resource>META-INF/spring.schemas</resource>
</transformer>
<transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
<transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<mainClass>XXXXX</mainClass>
</transformer>
</transformers>
</configuration>
</execution>
</executions>
</plugin>
application/x-www-form-urlencoded
.Hi there,
I am trying to work on a cache-control requirement and want my resources to be cached on the browser.
My parent application is a Zuul app and it uses spring security, i set the cache control on this app using resourceHandler in WebMvcConfigurer and this worked fine for all the resources. Also set ignore-security-headers to false on zuul.
Now this app loads another app(child app from another url) in an iframe (angular component), which in-turn uses spring security but its NOT a zuul app. Here also I used resourceHandler to configure cache control params and child app is intended to be accessible from parent app iframe only.
Now, unfortunately, cache control is not working properly for the resources of child app. I checked the response headers in chroma and found that now I get two cache control in response.
1) cache-control: no-cache
2) cache-control: (intended) I set in child app WebMvcConfigurer.
This works perfectly fine if I directly access my child app.
Not able to figure out how the no-cache got added in response headers. Whether its an iframe, parent zuul component or spring cloud added default caching.
I tried to disable the cache control for spring security from HTTPSecurity but still facing the same issue.
Looks like I am missing some basics here. I would like to know what I can check further.
Thanks a lot.
Hi Everybody!
@Bean
public Function<Flux<Message<OfferIncomingEvent>>, Flux<Message<OfferOutgoingEvent>>> offerValidatorAutomatic() {
return this::validateOfferAutomatic;
}
I have that Function which is procesing events from one kafka topic to another. My question is the following:
Is there a way to set up the binding between this two topics so that spring would forward the ALL the headers automatically?
Because if i remove the Message<?> type of the Flux parameter the headers from the input topic doesnt get forwarded.
Also, in the current setting i have to manually added them when building the outgoin message.
Thank you for your attention!
Approaches to handle 10 million records of 10 tables each with several joins
I have 10 million records of 10 tables each with several joins. I am looking for the best alternative or DB assign or approach to read the records very quickly that is the query should be fast.
option#1 - normalize the tables, don't go for joins unnecessarily
option#2 - add all the columns in 1st query where multiple times the
where conditions will be used in the looping construct
option#3 - go for nosql database instead of mysql
Please advise
Thanks
Hi, i've work with spring cloud gateway and experience same issue same as this thread (proxy server has response but spring cloud gateway not return it )
Could you give me sone suggestion about this ?
spring-cloud/spring-cloud-gateway#2484
thanks you very much