spotify/magnolify

Support Datastore entity keys

nevillelyh opened this issue · 0 comments

Possibly through a field annotation.
https://cloud.google.com/datastore/docs/concepts/entities
https://github.com/googleapis/googleapis/blob/master/google/datastore/v1beta3/entity.proto

For something like Person(@key email: String, name: String, age: Int)

  • partition_id
    • project_id: "" or from class level @projectId("my-project") annotation
    • namespace_id "", case class namespace, or from class level @namespace("com.myorg") annotation
  • path (repeated but we can allow only 1 level for simplicity?)
    • kind: case class name or from class level @kind annotation
    • id/name: Int/String field value