the resource should probably be self-aware of the path it is instantiated on, otherwise it's impossible for it to produce a response with a rel=self link
it could also just call the dispatcher, which would search in the dispatch config for a resource match, but if the resource is served from multiple locations, then which is the canonical location?
temp idea: canonical_uri callback
the resource should probably be self-aware of the path it is instantiated on, otherwise it's impossible for it to produce a response with a rel=self link
it could also just call the dispatcher, which would search in the dispatch config for a resource match, but if the resource is served from multiple locations, then which is the canonical location?
temp idea: canonical_uri callback