AvroEntityComposer entityComposer = new AvroEntityComposer(readSchema,
true);
AvroEntitySerDe entitySerDe = new AvroEntitySerDe(entityComposer,
readSchema, writeSchema, true);
KeySerDe keySerDe = new AvroKeySerDe(keySchema.getAvroSchema(), keySchema.getPartitionStrategy());
return new BaseEntityMapper(keySchema, readSchema, keySerDe, entitySerDe);
} else {
KeySerDe keySerDe = new AvroKeySerDe(keySchema.getAvroSchema(), keySchema.getPartitionStrategy());
AvroEntityComposer entityComposer = new AvroEntityComposer(readSchema,
false);
AvroEntitySerDe entitySerDe = new AvroEntitySerDe(entityComposer,
readSchema, writeSchema, false);
return new BaseEntityMapper(keySchema, readSchema, keySerDe, entitySerDe);
}
}