jcrProvider = new DefaultProvider();
repository = new TransientRepository();
JcrCollectionAdapter cp = new JcrCollectionAdapter();
cp.setTitle("My Entries");
cp.setAuthor("Apache Abdera");
cp.setCollectionNodePath("entries");
cp.setRepository(repository);
cp.setCredentials(new SimpleCredentials("username", "pass".toCharArray()));
cp.setHref("feed");
cp.initialize();
SimpleWorkspaceInfo wkspc = new SimpleWorkspaceInfo();
wkspc.setTitle("JCR Workspace");
wkspc.addCollection(cp);
jcrProvider.addWorkspace(wkspc);