syncbase: Change id encoding in store keys to preserve sorting.

Changed id encoding in store keys from the wire encoding
encodeName("<blessing>,<name>") to "<blessing>\0<name>\0".
The new encoding preserves the natural sort order (lexicographically,
first by blessing, then by name).

The new encoding removes the need for sorting when scanning databases,
collections, and rows.

Syncgroups use a hash in keys instead; changed syncgroup sort routine
to sort by blessing first instead of name first, added test to confirm.

MultiPart: 3/3
Change-Id: Ic32cbda622b88edab9a2ff6c67697efb8385ff8d
diff --git a/lib/src/main/java/io/v/v23/syncbase/util/Util.java b/lib/src/main/java/io/v/v23/syncbase/util/Util.java
index cff0476..aa23cac 100644
--- a/lib/src/main/java/io/v/v23/syncbase/util/Util.java
+++ b/lib/src/main/java/io/v/v23/syncbase/util/Util.java
@@ -5,9 +5,6 @@
 package io.v.v23.syncbase.util;
 
 import com.google.common.base.Charsets;
-import com.google.common.base.Function;
-import com.google.common.collect.Ordering;
-import com.google.common.util.concurrent.Futures;
 import com.google.common.util.concurrent.ListenableFuture;
 import io.v.impl.google.naming.NamingUtil;
 import io.v.v23.InputChannel;
@@ -173,20 +170,14 @@
             VContext context, String parentFullName) {
         InputChannel<GlobReply> input =
                 V.getNamespace(context).glob(context, NamingUtil.join(parentFullName, "*"));
-        return VFutures.withUserLandChecks(context,
-                Futures.transform(InputChannels.asList(InputChannels.transform(context, input,
+        return VFutures.withUserLandChecks(context, InputChannels.asList(
+                InputChannels.transform(context, input,
                         new InputChannels.TransformFunction<GlobReply, Id>() {
                             @Override
                             public Id apply(GlobReply from) throws VException {
                                 return idFromGlobReply(from);
                             }
-                        })), new Function<List<Id>, List<Id>>() {
-                    @Override
-                    public List<Id> apply(List<Id> input) {
-                        return Ordering.from(new IdComparator())
-                                .immutableSortedCopy(input);
-                    }
-                }));
+                        })));
     }
 
     private static Id idFromGlobReply(GlobReply reply) throws VException {