workspace.setTitle("resource");
String href = request.getRequestURL().toString();
href = href.substring(0, href.length() - "/atomsvc".length());
Collection collection = workspace.addCollection("collection", "atom/feed");
collection.setTitle("entries");
collection.setAttributeValue("href", href);
collection.setAccept("entry");
collection.addCategories().setFixed(false);