You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 8, 2023. It is now read-only.
In this case, the source is Elastic Search but it can be any other data source including graphQL, REST etc.
Having it this way we can pretty nicely merge different data sources - eg. having a list function from the WordPress module we can add even something like category.posts() to get the blog posts along with the products for a specific category
Kind of Schema Stitching or FederationBUT over different data sources - Stichting REST, Database whatever with the GraphQL - so the list function becomes a universal data source no matter wich service
It's an idea similar to DataResolvers from Vue Storefront - but it's simpler.
I guess we could extend the module API adding something like this:
@ResuBaka this is something you could be realy interested in - this API will let us to attract integration developers to add their integrations as modules to SFAPI
@ResuBaka maybe instead of ModuleDataProvider singleton we should have some Registry object available thru the context as well? I guess we should avoid singletons
Related: #23 - having this registry of data fetching functions all in the same format we can easily switch between output and query formats (graphql, odata, rest)
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
What is the motivation for adding/enhancing this feature?
If we managed to introduce a single standard of
list
function between resolvers it could be a potentially nice feature to re-use between modules.Take this
list
products it's then used for listing category productsIn this case, the source is Elastic Search but it can be any other data source including graphQL, REST etc.
Having it this way we can pretty nicely merge different data sources - eg. having a list function from the WordPress module we can add even something like
category.posts()
to get the blog posts along with the products for a specific categoryKind of Schema Stitching or Federation BUT over different data sources - Stichting REST, Database whatever with the GraphQL - so the
list
function becomes a universal data source no matter wich serviceIt's an idea similar to
DataResolvers
from Vue Storefront - but it's simpler.I guess we could extend the module API adding something like this:
so on the module level the user can call something like this:
... so then - from the other module user could call something like:
The text was updated successfully, but these errors were encountered: