Category "spring-boot"

Thymeleaf doesn't print list of objects (Spring JPA)

I have 5 different object of class Tour with some fields.I want that my main page shows this object with their fields. I wrote conrtoller: @Controller

postman post request json payload created and in return , response is empty with respect to spring boot project

**** I have created repository and autowired that to service class and created controller and autowired the service and and the sample code below same code i ha

Connecting to angular and springboot app from external IP

First of all, thanks for taking your time in reading this. I have a Spring boot backend running locally and angular app making calls to this backend to to do CR

Heroku session unexpectedly dropped/created

I am running an application on Heroku. We have a staging site and a production site. We are attempting to move to a standard 0 tier database. I have successfull

unable to start embedded Tomcat when running Eureka Server

I am just starting with microservices and I want to creat a simple Eureka Server to do my Serviceregistry. For now I just want to run the server on localhost an

Enable HTTP2 with Tomcat in Spring Boot

Tomcat 8.5, which will be the default in Spring Boot 1.4, supports HTTP/2. How can HTTP/2 be enabled in a Spring Boot application?

Don't spring-boot-starter-web and spring-boot-starter-webflux work together?

When I start to learn the spring-webflux, I have the question about this component. I built a simple project, using maven to manage it. I addded the dependencie

Springboot stack-trace logging filter only from my packages

I'm using Springboot with the sl4j-api 1.7.2. Is there a way to filter out from stack-traces only the lines starting with my packages, or excluding from the log

Exclude @SpringBootApplication from component scanning

I have two classes marked as @SpringBootApplication under one directory: @SpringBootApplication public class FirstSpringBootApplication and @SpringBootApp

Intellij complaining about property logging.file.path in SpringBoot

Running Springboot 2.5.9 and IntelliJ 2022.1. I have this in my application.yml: However, IntelliJ is complaining about the fact that logging.file is deprecat

Spring RestController - findById and findByEmail request method not working (Ambiguous handler)

I want to retrieve user's info either based on the ID or the Email. Below is the controller class I wrote: @RestController @RequestMapping("/users") public clas

How to solve "Spring Cloud LoadBalancer is currently working with the default cache. You can switch to using Caffeine cache' warning?

How to solve Spring Cloud LoadBalancer is currently working with the default cache. You can switch to using Caffeine cache, by adding it to the classpath. warni

How to configure port for a Spring Boot application

How do I configure the TCP/IP port listened on by a Spring Boot application, so it does not use the default port of 8080.

Spring.datasource.initialize=false not working

I am working on spring boot and batch application. Due to batch, the application tries to connect to datasource with spring-boot:run. I want to stop that and t

Micrometer - Prometheus Gauge displays NaN

I am trying to generate Prometheus metrics with using Micrometer.io with Spring Boot 2.0.0.RELEASE. When I am trying to expose the size of a List as Gauge, it

Resolving Pageable in Webflux

I spent a lot of time to find a solution about Pageable in Webflux, unfortunately, at the time of writing this, Webflux does not support Pageable so I came up w

Apache Server Reverse Proxy Issue

I have Microservices implemented using Spring Boot hosted in VM. I have Apache HTTP Server which act as load balancer and have configured reverse proxy to redir

How to view the metrics ready to be sent off to Datadog

So I am new to metrics and micrometer. I am have followed this tutorial in which we set up some basics Meters like a counter and a Gauge and expose the metrics.

Restarting inifinite Flux on error with pubSubReactiveFactory

I'm developing an application which uses reactor libraries to connect with Google pubsub. So I have a Flux of messages. I want it to always consume from the que

Predicate on a field of an entity class which is type of a parent class and filter on fields of its children

In the entity class A there is a field of type P1 named as p. Class P2 and P3 is extended from P1. In the predicate I want to filter the result based on a field