RE: Moving forward with hydra:filter (ISSUE-45)

On Monday, November 30, 2015 7:30 PM, Dietrich Schulten wrote:
> UriTemplate has many more ways to expand query parameters than name-value.
> Some examples:
> * Param names can be repeated if they have an explode (*) modifier and a
>   list is used to expand them. What does it mean when I query
>   firstname=Ruben&firstname=Markus? Is that an OR query? My first
>   impulse is to say yes, but... 

We need to define what multiple values mean in general (if we allow them)...


> * Param values can be comma-separated when they were expanded from a list.
>   What does that mean? 

... how they are serialized is a secondary concern.


> * Param values can be truncated with a prefix modifier like {?var:3}. 
>   Is that a startsWith query? Or is that not allowed in a :filter? 

I would say it has no special meaning in the context of our hydra:filter discussions. If the server thinks the first 3 characters are enough, good.


> * Param names with * can also be applied to associative arrays so that
>   one param name can 'explode' to a list of attribute-value pairs. What
>   is the relationship between the exploded params - AND?

I would say this is out of scope (at least for now). The whole concept of associative arrays doesn't really exist in our data model (you could argue it corresponds to property-value pairs which share the same subject)


> * Does :filter only work with query params or can we also use other
>   expansions like path-style aka matrix parameters?

Sure, why not?


> We either have to restrict :filter to the exact param expansions it
> supports or think through the possibilities of Level 4 UriTemplate queries.

We should definitely look at this but I don't think we need to support everything level 4 URI templates have to offer. Or do you disagree?


--
Markus Lanthaler
@markuslanthaler

Received on Sunday, 6 December 2015 22:39:57 UTC