Skip to content

route result -- add paths #14

@eyston

Description

@eyston

a result should contain the following paths:

  • request: the pathsets requested
    • get
    • set
    • call
  • matched: the unoptimized pathsets that the router handled
    • get
    • set
    • call
  • unhandled: the pathsets that did not match any router paths
  • optimized: the optimized pathsets
  • invalidate: the pathsets that should be removed from any client cache

Purpose

request

Not sure if useful, but what the hell, why not.

matched

The idea is I could run these paths against the result and get the denormalized view of the result. This might be hard because we don't really keep track of what optimized paths originate from. Instead we can probably cheat and say "which paths from request does the cache include" and use that. It would cheat because any short circuits early in a path would make all sub-paths match. Might be able to work around this using 'unhandled' in combination with 'request'.

set and call could foil all of this.

the two main uses of this would be to support a 'pull' like syntax which would return a denormalized view of the result and then client callbacks where a callback on set or call could return the denormalized view.

unhandled

This would be useful for composing routers -- run router A, run all 'unhandled' results from A on router B. Right now we throw this information away ... but we have it!

optimized

This should be the easiest one -- we are already doing it although it is sorta goofy (lots of empty paths show up ... figure that out dummy).

invaldiate

Used by call to delete stuff from client caches -- already impl, just keep it~

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions