Skip to content

Instantly share code, notes, and snippets.

@svenhakvoort
Last active May 17, 2020 15:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save svenhakvoort/9ff6c01ca9d30da5d13f85806a5b460c to your computer and use it in GitHub Desktop.
Save svenhakvoort/9ff6c01ca9d30da5d13f85806a5b460c to your computer and use it in GitHub Desktop.
DemoModel
package com.example.demographql.model
import com.expediagroup.graphql.annotations.GraphQLID
import org.springframework.data.annotation.Id
import java.util.*
data class Demo(
val someText: String
) {
@GraphQLID @Id
var id: String = UUID.randomUUID().toString()
}
package com.example.demographql.repository
import com.example.demographql.model.Demo
import org.springframework.data.mongodb.repository.ReactiveMongoRepository
import org.springframework.stereotype.Repository
@Repository
interface DemoRepository: ReactiveMongoRepository<Demo, String> {
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment