Questions tagged [spring-data-rest]

Spring Data REST (SDR) is a Spring Data project that aims to make it easy to expose Spring Data repositories as REST services. SDR use Spring HATEOAS internally to create HAL response.

2228 questions
1
vote
1 answer

Spring Data Rest Unit Tests Selectively Pass

I am investigating the use of Spring Data Rest (2.0.1.RELEASE and Spring 4.0.2.RELEASE), and have written a simple service. I have also written a simple test class (see below) using DbUnit. Unfortunately when I run the tests only the findAll method…
Steve Bosman
  • 2,599
  • 1
  • 25
  • 41
1
vote
1 answer

Spring Repository Rest Resource - issue not saving sub objects

I have been trying to get a RESTful interface going with Spring boot but have hit a problem. When POST'ing the following JSON I get an org.hibernate.TransientObjectException exception (please see below) that indicates that the sub-object is not…
1
vote
2 answers

Connect to local neo4j Server instance from Spring Boot Starter

I am trying to connect to a locally installed Neo4j server from the spring boot starter -> gs-accessing-neo4j-data-rest http://spring.io/guides/gs/accessing-neo4j-data-rest/ The server installation is default via Homebrew. Gradle Build…
code
  • 4,073
  • 3
  • 27
  • 47
1
vote
1 answer

Spring Data Rest - Cross-Application Rest API

So let's assume I have two applications, the Person application that manages people, and the Pants application that manages Pants. In the Person application the Domain object Person has a List pantsId that refers to the id of a pair of pants from…
Ben M
  • 1,833
  • 1
  • 15
  • 24
1
vote
1 answer

spring-data-rest-webmvc 2.0.0 - RepositoryRestExporterServlet missing

I'm trying to create a REST web service with spring-data-rest-webmvc 2.0.0. I'm following the handbook "Spring in Practice" where you use the version 1.0.0. In this handbook, it define the exporter servlet in web.xml as below: ... …
Zio Panzu
  • 57
  • 2
  • 11
1
vote
1 answer

Unrecognized field "_links" since the 2.0.0.RC1 of Spring Data REST

On one side, I have just update the version of spring-data-rest-webmc to the latest 2.0.0.RC1 version of my server. In this version, the json format change to an HAL format. On the other side, I have a client which use the spring-hateoas library…
bwilcox
  • 629
  • 1
  • 6
  • 14
1
vote
1 answer

How do I get Spring Data REST 2.0 RC1 to work?

I got Spring Data REST 1.1.0.M1 working, but would like to try version 2.0. Here's my POM:
Neil McGuigan
  • 46,580
  • 12
  • 123
  • 152
1
vote
2 answers

findBy URI not working in Spring Data Rest

By default, in Spring Data Rest the @Id of the entity is not exposed. In line with the REST rules, we're supposed to use the URI of the resource to refer to it. Given this assumption, the findBy queries should work if you pass a URI to them, but…
ivan
  • 11
  • 3
1
vote
1 answer

Spring Security / rolesAllowed / antMatchers

I am using Spring Data REST and I have a find method in my repository: public List findByLastNameOrderByLastNameAsc(@Param("lastName") String lastName); I am trying to add security to the method, but no luck. In my DB, I have 1 user with…
user1459641
  • 458
  • 6
  • 17
1
vote
1 answer

Spring Data Rest, Many to one

I'm building an application using Spring Data Rest. i have a Many to One relationship backed by a non-nullable foreign key. Which is the correct way to add an element on the "Many" side of the relationship using the REST API?
Andres
  • 10,561
  • 4
  • 45
  • 63
1
vote
0 answers

Maven Project works, Gradle version of same code... not?

Update Originally there was a Tomcat exception upon initialization of my gradle build's war file. After some help from the author, it is now deploying and running albiet partially. This may be due to a bug in Gradle. Editing with the updated…
Erik
  • 2,782
  • 3
  • 34
  • 64
1
vote
0 answers

I am getting 'org/neo4j/kernel/impl/core/RelationshipTypeHolder ' error while Running spring data neo4j configuration

I have changed dependency of neo4j-kernel version but still getting this issue. Please suggest to me how to get rid out of this issue. Below are my pom, spring configuration and error console. Dependency in pom :
1
vote
2 answers

Spring Data REST example that doesn't use root for mapping

I cannot figure out where to modify the Spring Data REST service so that it is NOT in root / I'm looking over the JavaDoc for RepositoryRestMvcConfiguration , but if anyone has an idea I'd appreciate some guidance. My…
Erik
  • 2,782
  • 3
  • 34
  • 64
1
vote
3 answers

Spring Data Rest bootstrap issue

I'm writing a rest service with spring-data-rest. And I face an exception that I don't know how to fix. I have the following Application configuration @Configuration @ComponentScan(basePackageClasses =…
Cyril Gavrailov
  • 466
  • 3
  • 6
1
vote
2 answers

Spring Data REST: Silent failure when adding entity relationship

Fellow Spring Data REST enthusiasts, I am running my Spring Data REST 1.1 application, and I am attempting use curl to add an entity relationship using the "text/uri-list" Content-type, as described in the link: Example-API-usage-with-curl. curl -v…