@Override
    public Long read(JsonReader in) throws IOException {
      checkArgument(in instanceof BsonReader, "Should be BsonReader, not some other JsonReader");
      return ((BsonReader) in).unwrap().readDateTime();
    }
Use this adapter (not registered by factory, default Gson adapter is used otherwise) to
delagate marshaling of {@link BigDecimal} to {@link Decimal128} type in mongo.
@return {@code BigDecimal <==> Decimal128} adapter
mongo/src/org/immutables/mongo/types/TypeAdapters.java