- From: James M Snell <jasnell@gmail.com>
- Date: Thu, 21 Aug 2014 12:29:54 -0700
- To: "activity-streams@googlegroups.com" <activity-streams@googlegroups.com>
- Cc: "public-socialweb@w3.org" <public-socialweb@w3.org>
On Thu, Aug 21, 2014 at 12:10 PM, Owen Shepherd <owen.shepherd@e43.eu> wrote: [snip] > > Precedent from some AS1 deployments is that link rel "self" is used in cases > where the "id" property is a non-dereferencable URL to point to the activity > streams document for this resource. As an example, see > https://gist.github.com/oshepherd/8c879449b3a55316cd73 (which is taken from > the real world example of Pump.io) > This precedent is just fine with the suggested change. > Three things I'd like to see: > > What is the algorithm for finding the dereferencable to an ActivityStreams > document URI? { "self": { "id": "http://example.org/foo", "mediaType": "application/activity+json" } } > What is the algorithm for finding the dereferencable to a human readable > document URI? { "alternate": { "id": "http://example.org/foo", "mediaType": "text/html" } } > What is the algorithm for finding the embedded content URI? (For image, > video, etc objects) { "image": { "id": "http://example.org/foo.jpg", "mediaType": "image/jpeg" } } "self", "alternate" and "image" are all link relations. If necessary, because of how Link Values are defined, we can also do: { "self": [ { "id": "http://example.org/foo", "mediaType": "application/activity+json" }, { "id": "http://example.org/foo.html", "mediaType": "text/html" } ], "image": "http://example.org/foo.jpg" } Again, you look for the link relations you care about, then look for the mediaType you care about. The algorithm really is not all that complicated. > > For AS1, these are: > > obj["links"]["self"]["href"] || obj["id"] > obj["url"] (unless it's a collection, in which case you're screwed - > SPECBUG!) > obj[type]["url"] > > As much as I appreciate simplifying the spec, we should make sure that use > of the spec remains simple. I am not convinced that this is the case for > some of the changes in AS2 > Such as? > --- > > As a side note: I'm not a fan of the way that AS2 seems to be causing > unnamed Objects to proliferate where in AS1 Media Links would have been > used. We should remember the distinction between objects - things which form > the vertices of a graph (or, which on a website would have distinct web > pages) and the embedded content thereof - what AS1 called media links. > > This is very important to the many applications and clients which place the > objects as distinct entries in a database, because this proliferation of > objects makes their lives so much harder. > Can you please give some concrete examples? I'll see if I can explain the rationale for the changes using those examples. - James > > Owen Shepherd > http://owenshepherd.net | owen.shepherd@e43.eu > > -- > You received this message because you are subscribed to the Google Groups > "Activity Streams" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to activity-streams+unsubscribe@googlegroups.com. > To post to this group, send email to activity-streams@googlegroups.com. > Visit this group at http://groups.google.com/group/activity-streams. > For more options, visit https://groups.google.com/d/optout.
Received on Thursday, 21 August 2014 19:30:42 UTC