Arjan van Wieringen
08/19/2022, 9:51 AMRepositoryRestResourceUUID@Entity()
class Account(
    @Id var id: UUID,
    var name: String
)
@RepositoryRestResource(path="accounts", collectionResourceRel = "accounts")
interface AccountRepository : CrudRepository<Account, UUID> {
}
@Bean
fun initializeDatabase(accountRepository: AccountRepository) = ApplicationRunner {
    accountRepository.save(Account(id = UUID.randomUUID(), name = "Test"))
    <http://logger.info|logger.info>("Initialized test data")
}{
  "_embedded": {
    "accounts": [
      {
        "name": "Test",
        "_links": {
          "self": {
            "href": "<http://localhost:8080/accounts/4c12f420-6189-4abd-a970-573ba2e0ca23>"
          },
          "account": {
            "href": "<http://localhost:8080/accounts/4c12f420-6189-4abd-a970-573ba2e0ca23>"
          }
        }
      }
    ]
  },
  "_links": {
    "self": {
      "href": "<http://localhost:8080/accounts>"
    },
    "profile": {
      "href": "<http://localhost:8080/profile/accounts>"
    }
  }
}Resolved [org.springframework.data.rest.webmvc.ResourceNotFoundException: EntityRepresentationModel not found!]@Column(columnDefinition = "BINARY(16)")