Search in sources :

Example 1 with SchemaRegistrySingle

use of org.apache.apex.malhar.lib.appdata.schemas.SchemaRegistrySingle in project apex-malhar by apache.

the class AbstractAppDataSnapshotServer method setup.

@SuppressWarnings("unchecked")
@Override
public void setup(OperatorContext context) {
    super.setup(context);
    setupSchema();
    schemaRegistry = new SchemaRegistrySingle(schema);
    // Setup for query processing
    setupQueryProcessor();
    queryDeserializerFactory = new MessageDeserializerFactory(SchemaQuery.class, DataQuerySnapshot.class);
    queryDeserializerFactory.setContext(DataQuerySnapshot.class, schemaRegistry);
    resultSerializerFactory = new MessageSerializerFactory(resultFormatter);
    queryProcessor.setup(context);
}
Also used : DataQuerySnapshot(org.apache.apex.malhar.lib.appdata.schemas.DataQuerySnapshot) SchemaRegistrySingle(org.apache.apex.malhar.lib.appdata.schemas.SchemaRegistrySingle) MessageSerializerFactory(org.apache.apex.malhar.lib.appdata.query.serde.MessageSerializerFactory) MessageDeserializerFactory(org.apache.apex.malhar.lib.appdata.query.serde.MessageDeserializerFactory) SchemaQuery(org.apache.apex.malhar.lib.appdata.schemas.SchemaQuery)

Aggregations

MessageDeserializerFactory (org.apache.apex.malhar.lib.appdata.query.serde.MessageDeserializerFactory)1 MessageSerializerFactory (org.apache.apex.malhar.lib.appdata.query.serde.MessageSerializerFactory)1 DataQuerySnapshot (org.apache.apex.malhar.lib.appdata.schemas.DataQuerySnapshot)1 SchemaQuery (org.apache.apex.malhar.lib.appdata.schemas.SchemaQuery)1 SchemaRegistrySingle (org.apache.apex.malhar.lib.appdata.schemas.SchemaRegistrySingle)1