i am trying to query a model that contains a @Reference as attribute like: and so on, then i have a query with more logic and code but in resume i have to filter by the field _id from Branch object, its just id on the object but on database its _id, ok no problem its normal behavior for the
Tag: spring
Is there a way to shorten boolean RequestParams in Spring Boot?
Thanks for all trying to help 🙂 Backround information: I use the spring framework version 2.4.3 together with Java (and Maven) To my question: Is it possible to shorten http://localhost:8080/api/v1/example?admin=true&superPrivilege=true to something like http://localhost:8080/api/v1/example?admin&supe…
Sending JSON Data to JPOS Based Project but failed in unpacking field 34
Request that i send : {“transactionid”:”12″, “ISOMsg”:”010046552063310518890000000000000123001203210541330012003255399022004655206331051889=…
Clean shutdown of Spring WebSockets STOMP client
A Spring WebSocket STOMP client sends a long to Spring WebSocket STOMP server that immediately returns the same value. When the client completes sending, it exits its main thread and the client terminates as expected. If I enable STOMP heartbeats: the client no longer exits the JVM when the client’s mai…
Java show/hide object fields depending on REST call
Is it possible to config the Item class that depending on the REST call to show and hide specific fields? For example I want to hide colorId (and show categoryId) from User class when calling XmlController and vice versa when calling JsonController. Item class JSON Controller XML Controller Answer I’ve …
After trying to test connection to h2 database or connect whitelabel error occurs
After running Spring boot project and going to localhost:8080/h2-console and after trying to connect to my database I get whitelabel error when i click any button on h2-console screen. I am using in memory database. I am trying to connect to database with classic username:sa and password:(blank) Even after cl…
Saving new entity with JPARepository throws InvalidDataAccessResourceUsageException: could not extract ResultSet
Currently working on a REST API with Springboot + JPA/Hibernate + Oracle. I have an entity called Foo linked to a Bar entity with @ManyToOne (Mulitple Foo can have one Bar). When I send an HTTPS GET to get all Foos, everything works fine. The problem is when I try to send a POST request to create a new Foo.
My HTML page is not coming up on localhost:8080 instead tomcat welcome page is displaying
I am new to spring and trying to build a simple application. I have a simple html page(home.html) which gets called from Homecontroller. when i am trying to access localhost:8080 i cant see my html page instead i see the apache tomcat welcome page which shows – If you are seeing this page you have succe…
Print body in handler from post request in spring webflux
I am completely new to Reactive Spring Webflux. I am writing a handler for a Post request which should Accept Json body(Employee id, name and role), Fetch some more Employee details from database 1 using id field, Return Employee json back with additional attributes like age and dept.. My router code is below…
Prevent Spring from prefixing booleans with is only in certain cases
I have an object with a boolean property called hasEnoughBalance, but Spring (or Lombok, or whoever it is) appears to be renaming the getter to isHasEnoughBalance instead of getHasEnoughBalance or plain hasEnoughBalance. How could I prevent that? I know of @JsonProperty, but I’d like another solution if…