Given this Query type we generate all the nested types you need. By annotating with attributes you can add additional behavior on top of it.
publicclassQuery{[UsePaging][UseSelection]// <--- creates the projections on the database[UseSorting][UseFiltering]publicIQueryable<Jedi>GetJedis([Service]DBContextctx)=>ctx.Jedis.AsQueryable()}
I actually got it working with the BookAPI example on the ms site, and the startwars example repo. I basically just followed the BookAPI tutorial until they started talking about controllers, then looked at the starwars repo and implemented a resolver that used the BookService that was connected to mongo, instead of the in-memory repository, and then implemented the types for the book and query and hooked it all up in startup.
I'll go through the workshop repo and see how it compares to what I did to see if I was on the right track, and start learning about all the other stuff.
Regarding projections:
Given this Query type we generate all the nested types you need. By annotating with attributes you can add additional behavior on top of it.
When you now execute this query
This SQL statement is executed:
Thank you for info and redirect to the repo.
I actually got it working with the BookAPI example on the ms site, and the startwars example repo. I basically just followed the BookAPI tutorial until they started talking about controllers, then looked at the starwars repo and implemented a resolver that used the
BookService
that was connected to mongo, instead of the in-memory repository, and then implemented the types for the book and query and hooked it all up in startup.I'll go through the workshop repo and see how it compares to what I did to see if I was on the right track, and start learning about all the other stuff.
Thank you kindly!
Join the slack channel if you have any questions, you get usually an answer real quickly :)