[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
One of the things that seems to come up repeatedly when designing APP
apps is the concept of hierarchical collections. I'm wondering if
people think there is a best practice here and if folks think we should
agree on a standard way of doing this.
Since I'm a practical guy, I thought I might lead with a few use cases. Other folks can debunk/expand on them if they wish.
- A way to browse around/create/delete collections of atom entries. For instance, I might want to list out a collection of collections. One of these collections might be a collection which represents a set of media entries which represent application resources (JARs, schemas, configurations). This is one of my primary uses cases at the moment as we (MuleSource, WSO2, and possibly some others) are trying to come up with a standard way to allow people to browse what is in our registry/repository products.
- A forum which contains topics which contain messages (I saw a
thread on this earlier on the mailing list, but didn't see any
suggestions about how the entries should look).
- A customer account which is associated with a collection of purchase orders and a collection of customer contacts.
A couple ideas have been floating around that I've seen:
1. Embed a <collection> in an atom entry
<collection href="" href="http://example.com/customers/acme/contacts">http://example.com/customers/acme/contacts" rel="contacts">
<collection href="" href="http://example.com/customers/acme/purchase-orders">http://example.com/customers/acme/purchase-orders" rel="purchase-orders">
this case I'm using a rel attribute to describe what relationship this
collection has to the atom entry. Granted my example does not follow
the <link> rel attribute rules here as those values are not
registered, but you get the idea.
2. Use <link> relationships
<link rel="some-defined-child-collection-relationship" href=""></entry>
the customer/PO/Contact example I could define my own rel attributes.
Downside here is that it'd be really nice to have a title inside the
feed saying what this thing was.
3. Don't use AtomPub, use XXX (i.e. WebDAV)
Maybe APP is the
wrong thing for this, but I'm really looking to take advantage of the
I'm sure I'm missing a thousand details here, so it'll be interesting to hear what the group has to say :-)