yahoo / elide

Elide is a Java library that lets you stand up a GraphQL/JSON-API web service with minimal effort.

Home Page:https://elide.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

7.0.0-pr6 error: Unknown collection

manosbatsis opened this issue · comments

My entity:

@Entity
@Table(name = "account")
@Include(name = "account", friendlyName = "Account")
@Subscription
class Account {
    @Id
    @Column(length = 16, unique = true, nullable = false, updatable = false)
    var id: UUID = UUID.randomUUID()

    @Column(length = 16, unique = true, nullable = false)
    var owner: UUID = UUID.randomUUID()
}

Request:

Request method:     POST
Request URI:        http://localhost:40789/api/account
Headers:            Accept=*/*
                    Content-Type=application/vnd.api+json; charset=ISO-8859-1
Body:
{
    "data": {
        "type": "account",
        "id": "a1e11f99-a9b7-47e3-b980-58bc66c78086",
        "attributes": {
            "owner": "ae1c2795-1cce-4259-97fe-e806b05e9251"
        }
    }
}

Response:

{
    "errors": [
        {
            "detail": "Unknown collection my.package.Account"
        }
    ]
}
  • Elide version used: Elide 7.0.0-pr6 (spring boot starter)
  • Environment name and version:
    • OpenJDK Runtime Environment (build 17.0.8.1+1-Ubuntu-0ubuntu122.04)
    • Kotlin 1.8.10
    • Spring 6.0.9
    • Spring Boot 3.1.0

Bah, my bad. Had a bad @EntityScan that effectively ignored the entity.