-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GraphQL + ElasticSearch #533
Comments
Client-side Resources: |
Particularly relevant; an ElasticSearch query builder DSL: https://github.com/elastic/elasticsearch-ruby/tree/master/elasticsearch-dsl |
|
This is what I've been loosely following for dynamically generating the schema for FieldItems: http://graphql-ruby.org/schema/dynamic_schema.html |
We'll be using Rails's built-in API key functionality to authenticate API users: http://api.rubyonrails.org/classes/ActiveRecord/SecureToken/ClassMethods.html |
Good rundown of GraphQL Query core concepts with proper terminology: https://dev-blog.apollodata.com/the-anatomy-of-a-graphql-query-6dffa9e9e747 |
This will yield a huge benefit over how I was doing things: http://graphql-ruby.org/types/abstract_types.html We can now group together a bunch of disparate |
And an invaluable explanation of Interfaces and Unions: https://medium.com/the-graphqlhub/graphql-tour-interfaces-and-unions-7dd5be35de0d |
The approach I'm taking tonight (which should hopefully work) is to dynamically define Fields for all |
For a truly clean query interface (dynamic, per-user schemas and fields that don't rely on field hiding), we need to wait for the GraphQL-Ruby author to merge rmosolgo/graphql-ruby#1037. This is almost a complete rewrite of the library that will allow us to pass arguments into an |
Something nifty I'd found but forgot to link to: https://github.com/karmi/es-rails-example |
And then GraphCMS comes along and blows our API out of the water.. https://graphiql.graphcms.com/simple/v1/swapi We'll get there, though! |
Decently hefty Rails example: https://github.com/howtographql/graphql-ruby |
Sane structure guideline to help clean up our |
|
Partially resolved by #536. Keeping this issue open to plan future refactors and features. |
JIRA:
https://careerbuilder.atlassian.net/browse/CE-307 (GraphQL)
https://careerbuilder.atlassian.net/browse/CE-160 (ElasticSearch Infrastructure)
https://careerbuilder.atlassian.net/browse/CE-503 (ElasticSearch FieldType Mappings)
MVP Features:
ContentItems
,FieldItems
,Fields
,Users
andTenants
, with basic arguments (find by ID)ObjectTypes
ActiveRecord backend, no ElasticSearch utilization yet.ElasticSearch required for release of Advice & ResourcesNo Sorting/Filtering/SearchingFiltering and searching required for release of Advice & ResourcesNo PaginationPagination required for release of Advice & ResourcesHelpful resources:
https://github.com/ConsultingMD/graphql-preloadFor ActiveRecord onlyThe text was updated successfully, but these errors were encountered: