Defining relationships and filter parameters for agent-based queries
I made some assertion somewhere in the past that minimizing the number of links between resources as well as maximizing the flexibility of those links seemed like a good general rule of thumb.
In the current schema, we have a lot of this sort of thing:
inventoriedEconomicResources(resourceClassification: URL, page: Int): [EconomicResource]
searchInventoriedEconomicResources(searchString: String): [EconomicResource]
My intention is to merge all these relationship groups together into single fields (in the above case, inventoriedEconomicResources
) and provide all parameters as options to a single resolver. Does this sound like the correct approach?