Update with new mongo client async API changes

I think we should pull this work in as master doesn't even compile. There are still some failing tests, but I think it's mostly bugs the mongo guys need to fix.


On Thu, Nov 20, 2014 at 8:55 AM, Tim Fox <notifications@github.com> 
wrote:
> In 
> ext-mongo/src/main/java/io/vertx/ext/mongo/impl/codec/VertxCodecRegistry.java:
> 
> > +import io.vertx.core.json.JsonObject;
> > +import io.vertx.ext.mongo.impl.codec.json.JsonObjectCodec;
> > +import org.bson.codecs.Codec;
> > +import org.bson.codecs.configuration.CodecRegistry;
> > +
> > +/**
> > + * @author <a href="mailto:nscavell@redhat.com">Nick Scavelli</a>
> > + */
> > +public class VertxCodecRegistry implements CodecRegistry {
> > +  private Codec<JsonObject> jsonObjectCodec = new 
> JsonObjectCodec();
> > +
> > +  @Override
> > +  @SuppressWarnings("unchecked")
> > +  public <T> Codec<T> get(Class<T> clazz) {
> > +    if (clazz == JsonObject.class) {
> > +      return (Codec<T>) jsonObjectCodec;
> Don't we support JsonArray too?
> 
Not at the codec level. Mongo saves documents, which looks for 
'document' codecs. Obviously we support JsonArray when it's inside a 
JsonObject, but users aren't saving JsonArray's.
> —
> Reply to this email directly or view it on GitHub.
> 
=