spring-messaging

Correct usage of LoadbalanceRSocketClient with Spring's RSocketRequester

雨燕双飞 提交于 2021-02-10 12:48:15
问题 I'm trying to understand the correct configuration and usage pattern of LoadbalanceRSocketClient in a context of SpringBoot application ( RSocketRequester ). I have two RSocket server backends (SpringBoot, RSocket messaging) running and configuring the RSocketRequester on a client side like this: List<LoadbalanceTarget> servers = new ArrayList<>(); for (String url: backendUrls) { HttpClient httpClient = HttpClient.create() .baseUrl(url) .secure(ssl -> ssl.sslContext(SslContextBuilder

Correct usage of LoadbalanceRSocketClient with Spring's RSocketRequester

青春壹個敷衍的年華 提交于 2021-02-10 12:46:23
问题 I'm trying to understand the correct configuration and usage pattern of LoadbalanceRSocketClient in a context of SpringBoot application ( RSocketRequester ). I have two RSocket server backends (SpringBoot, RSocket messaging) running and configuring the RSocketRequester on a client side like this: List<LoadbalanceTarget> servers = new ArrayList<>(); for (String url: backendUrls) { HttpClient httpClient = HttpClient.create() .baseUrl(url) .secure(ssl -> ssl.sslContext(SslContextBuilder

Listen message queue SQS with Spring Boot not works with standard config

喜你入骨 提交于 2020-04-17 07:29:09
问题 I'm unable to make works queue listener with Spring Boot and SQS (the message is sent and appear in SQS ui) The @MessageMapping or @SqsListener not works Java: 11 Spring Boot: 2.1.7 Dependencie: spring-cloud-aws-messaging This is my config @Configuration @EnableSqs public class SqsConfig { @Value("#{'${env.name:DEV}'}") private String envName; @Value("${cloud.aws.region.static}") private String region; @Value("${cloud.aws.credentials.access-key}") private String awsAccessKey; @Value("${cloud

Why are ID and TIMESTAMP declared as transient headers in Spring Integration?

天大地大妈咪最大 提交于 2020-02-06 13:28:28
问题 I'm trying to send/receive messages via Spring Integration's AMQP in/outbound adapters and I'm facing this problem. After finding Gary's answer here, I started to investigate if my app sets a message ID correctly. In fact, it's taken care of automatically here. The producer looks like this. I send a wrong message on purpose and at the consumer's end I watch its message transformer fail here. After that the message gets re-queued and re-processed again endlessly. While debugging this issue, I

Why are ID and TIMESTAMP declared as transient headers in Spring Integration?

我的梦境 提交于 2020-02-06 13:27:28
问题 I'm trying to send/receive messages via Spring Integration's AMQP in/outbound adapters and I'm facing this problem. After finding Gary's answer here, I started to investigate if my app sets a message ID correctly. In fact, it's taken care of automatically here. The producer looks like this. I send a wrong message on purpose and at the consumer's end I watch its message transformer fail here. After that the message gets re-queued and re-processed again endlessly. While debugging this issue, I

Why does STOMP functionality in spring-websocket depend on Spring MVC?

怎甘沉沦 提交于 2020-01-13 19:42:10
问题 Currently, I am trying to use STOMP with websockets using webflux. In order to send a message to a STOMP topic, I need to use SimpMessagingTemplate , which is contributed by spring boot auto configuration when I add @EnableWebSocketMessageBroker But the problem with this is, @EnableWebSocketMessageBroker indirectly expects me to have spring-mvc library in classpath @EnableWebSocketMessageBroker @Import s DelegatingWebSocketMessageBrokerConfiguration which extends

Spring: How to configure Messaging Bridge poller with annotations

╄→尐↘猪︶ㄣ 提交于 2020-01-07 05:37:07
问题 I want to be able to throttle requests received from my SubscribableChannel. I do not use a PollableChannel. Will i be able to do an equivalent of this: <bridge input-channel="pollable" output-channel="subscribable"> <poller max-messages-per-poll="10"> <interval-trigger interval="5" time-unit="SECONDS"/> </poller> </bridge> http://docs.spring.io/spring-integration/docs/2.0.0.M4/spring-integration-reference/html/bridge.html using annotations? 回答1: With a bridge handler... @Bean

Why is SimpUserRegistry not working properly on EC2 Instance

拈花ヽ惹草 提交于 2019-12-23 08:54:06
问题 I am using SimpUserRegistry to get online user-count (with getUserCount() ). And it is working good on my local machines but not on AWS EC2 instances (tried with Amazon Linux and Ubuntu) with just elastic IP and no load balancer. The problem on EC2 is that some users, when connected, are never added to the registry and thus I get wrong results. I have session listeners, for SessionConnectedEvent and SessionDisconnectEvent , where I use the SimpUserRegistry (autowired) to get the user presence

Spring Integration jms message driven channel adapter fails

青春壹個敷衍的年華 提交于 2019-12-23 02:38:48
问题 I am using spring integration 4.1.0 to implement message consumption from TIBCO EMS queue using jms-int:message-driven-channel-adapter I have 9 different message driven channel adapter listening at different server in different queue. Below is how the message driven channel adapters are defined <int-jms:message-driven-channel-adapter id="mdca1" connection-factory="connectionFactory1" channel="jmsChannel1" destination="queueName1" error-channel="errorChannel" max-concurrent-consumers="5" auto

Spring security/Spring session/Web sockets

限于喜欢 提交于 2019-12-23 01:49:31
问题 We are attempting to use a combination of spring session, spring security and websockets to implement security for a websocket API without using cookies. Ideally we would be using a authorization header or authentication using the websocket/stomp messages but this does not seem to be possible with the current spring websocket support. We are using a pre-auth provider to validate a query parameter token and log the user in. I can see that the proper user is pulled out in the pre-auth for the