786 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
0
votes
0
answers
53
views
Different name for hypermedia links attribute in json response after using RestTemplateBuilder for the first time (links vs _links)
Different name for hypermedia links attribute in json response after using RestTemplateBuilder for the first time (links vs _links).
We have adopted a legacy application which has several rest ...
0
votes
1
answer
104
views
Should HATEOAS links preferably be placed on objects or be separate?
Should all HATEOAS links of the data-transfer object (DTO) be placed on the root level? Or should they be coupled with the individual keys as sub-objects? For example:
Option 1: separate links
{
&...
-1
votes
0
answers
81
views
Unable to write JSON:Java 8 date/time type java.time.LocalDateTime when using Hateos Json API [duplicate]
I am working on Spring Hateos Json APi.
I have a Get request
import static com.toedter.spring.hateoas.jsonapi.MediaTypes.JSON_API_VALUE;
import org.springframework.hateoas.EntityModel;
import java....
1
vote
1
answer
50
views
Post Payload issue when using NGRX-Hateoas (angular) and Spring Hateoas (HAL)
Currently We have a Spring Hateoas (HAL) implementation in the backend and manually handle the communication with our angular client which is working fine.
I started to look for libs (seems like no ...
0
votes
0
answers
28
views
When using WebFluxLinkBuilder LocalDate is not encoded correctly
I'm trying to migrate a project of mine to WebFlux from MVC and I'm having an issue when encoding links using the WebFluxLinkBuilder to a method that take in a LocalDate, the link shows the data as &...
0
votes
0
answers
35
views
Unable to call post method for Spring Hateos JSON API with relationships
I am working on using Spring Hateos Json APi as a replacement for crnk .I want to implement a post request ie to save the Book object
import static com.toedter.spring.hateoas.jsonapi.MediaTypes....
0
votes
0
answers
50
views
Spring Hateos Json APi add included to the response
I am working on using Spring Hateos Json APi as a replacement for crnk .As per the documentation. I was able to get the expected response when I retrieve a List of object ie when I did
import static ...
0
votes
1
answer
52
views
Spring Hateos Json api list deserialise issue
I am working on using Spring Hateos Json api as a replacement for crnk. As per the documentation. I was able to get the expected response when I retrieve a object ie when I did
import static com....
0
votes
0
answers
91
views
Crnk alternate for spring boot 3
I am working on a project which has spring boot 2.7 . We are planning to migrate it to spring boot 3. Our current project uses CRNK as the json api specification implementation. Since CRNK is not ...
0
votes
0
answers
16
views
Is it possible to replace spring-hateoas with spring-hateoas-jsonapi in spring-data-rest?
Spring Data Rest works with Spring Hateoas. Id like to replace it with spring-hateoas-jsonapi. Is it possible?
0
votes
1
answer
54
views
How to convert URI to object in custom spring-data-rest controller?
I use spring-data-rest to publish this entity, among others
@Entity
public class Activity {
@Id
private Long id;
@ManyToOne
private Customer customer;
}
Referenced entities such as ...
1
vote
1
answer
135
views
How to solve 'Cannot subclass final class java.lang.reflect.Method'?
I have this Junit 5 test code:
@InjectMocks
ReportAssembler reportAssembler;
private ReportingReturnResponse reportingReturnResponse;
private ReturnReport returnReport;
private StaticPathLinkBuilder ...
1
vote
1
answer
66
views
How to replace Link.REL_SELF when migrating from spring-hateoas 1.0 to 2.4?"
I have this Junit test with is using hateoas 1.0:
@Test
public void processUserExceptionThrown() {
when(userService.processAccount(request, account))
.thenThrow(new RuntimeException());
try {
...
0
votes
1
answer
224
views
Cannot invoke "java.lang.reflect.Method.getDeclaringClass()" because "method" is null in Junit 5
I want to mock a complex case of Java method response into JUnit 5 test which is using hateoas.
The JUnit 5 test:
@ExtendWith(MockitoExtension.class)
public class ReportingATest {
@Spy
protected ...
0
votes
1
answer
71
views
How can I specify actual type of T on a ParameterizedTypeReference<T>?
I have a controller defines following methods.
Mono<EntityModel<Some>> readSome(...) {
// works, simply.
}
Flux<EntityModel<Other>> readOther(...) {
...