I am working on a Spring Boot application running it on a Linux machine. It is a batch application containing Spring Boot Admin tool listening on the 8080 port. I have the following “problem”: I run it into my shell for the first time using this command: it correctly start and I can access to the …
Tag: spring-boot
Problem in updating the entity with unidirectional @ManyToOne relation
I have two entities as below and the main problem is when I want to update the AccountRequestStatus entity. I save the integer enum code of AccountRequestStatusEnum in the database to persist the AcountRequest status in the whole application. AccountRequestStatusEnum AccountRequest AccountRequestStatus The fi…
Vaadin 14 show simple HTML Page
I made some kind of internal manual for a webapp that i am developing. I am using Spring Boot and Vaadin 14. How to implement a button that shows that document? The html doc is in my resources folder. I wonder if i am stupid. Or should i write my own controller for this? Answer A Vaadin application itself is
Error creating bean with name ‘solverManager’, Unsatisfied dependency expressed through constructor parameter
JHipster is a development platform to quickly generate, develop, & deploy modern web applications & microservice architectures using Spring-boot framework. Jhipster has “straight to go” script to deploy on google cloud. Optaplanner is an AI library which helps solve planning and scheduling…
Update DB column which has null value in Spring boot JPA
I am trying to update in the database with the help of the Spring JPA and having an issue while doing it. I have an Embedded class in my entity. My entity class is : My Repository class is : Audit, Transfer and Beneficiary Details are my Emededded class and those are : My Controller class is: My error stack
Spring Boot + Infinispan embedded – how to prevent ClassCastException when the object to be cached has been modified?
I have a web application with Spring Boot 2.5.5 and embedded Infinispan 12.1.7. I have a Controller with an endpoint to get a Person object by ID: The following is the PersonService implementation with the use of the @Cacheable annotation on the getPerson method : And here is the Person class: I configured in…
How to save/zip binary/octet-stream s3 content to zip
I am trying to add s3 bucket files into a zip. The files in the s3 bucket are in binary/octet-stream format. When I run the below method The IO Exception below is thrown when executing IOUtils.copy method “exception”: “Premature end of Content-Length delimited message body (expected: 206,034…
How connect to db when running Dockerfile?
I have a spring boot app that connects fine to my PostgreSQL server running locally in Desktop Docker. Than I wrote a simple Dockerfile to run my app in container. Container starts but can’t connect to my db server with error message: Connection to localhost:5432 refused. Why and how to fix this? Answer…
How to use Bearer or Apikey keywords automatically onswagger java
I am trying to make some security configurations in my SwaggerConfiguration class. My purpose is sending scheme keyword with authentication key like or It is possible on ASP.NET Core but I can only achieve this in Java like this: What shall I use for my Docket security scheme instead of ApiKey? Answer You can…
Limit number of requests(read, update, delete) if it exceeds the capacity of AWS Neptune Server?
I’m trying to implement some limits on the database requests made to the Neptune Server. The problem is: Multiple scheduled jobs that do analytics, logs, updates, deletions User activity, anything related to users: read, write, update, delete All of these request depending on when they occur can impact …