spring-boot-logging
spring-boot-logging copied to clipboard
When Using spring-cloud-starter-bus-amqp along with logstash-logging-spring-boot-starter, logs are not showing in Kibana.
Backgroud
I have a rest-api in which I am using
-
spring-cloud-starter-config
-
spring-cloud-starter-bus-amqp
and then I used -
logstash-logging-spring-boot-starter
Now I cannot see the logs in Kibana dashboard. When I remove spring-cloud-starter-bus-amqp
then logs are being showed in Kibana dashboard.
I guess there is something wrong in between spring-cloud-starter-bus-amqp
and logstash-logging-spring-boot-starter
Expected Result
I should able to use logstash-logging-spring-boot-starter
with spring-cloud-starter-bus-amqp
and logs should have shown.
Prerequisite
- Java 15
- Maven 3.6.3
- Docker 19
How to reproduce the problem:
-
git clone https://github.com/UbaidurRehman1/Cloud-Native-App-Spring-Boot.git
-
cd Cloud-Native-App-Spring-Boot
-
git checkout issues/#146
-
mvn clean install -DskipTests
-
cd envcn
-
./run.sh
(this will up all tools which are required for our services like ELK stack, config server, zipkin and rabbit-mq) -
cd ..
-
./run.sh
(this will up our services like rest-api) - Go to Kibana Dashboard
- First setupt the kibana dashboard
- Now go to Swagger UI
- Execute this controller by putting in
from
fieldUSD
, into
fieldPKR
and inquantity
field10
- Now check the logs, there are only logs of services. There is no log about rest-api. (I have added this combination
logstash-logging-spring-boot-starter
withspring-cloud-starter-bus-amqp
only in rest-api)
Profile
- The above services will run in dev profile
- You can access them