Search in sources :

Example 11 with LineageWriter

use of io.cdap.cdap.data2.metadata.writer.LineageWriter in project cdap by caskdata.

the class DistributedProgramContainerModule method configure.

@Override
protected void configure() {
    List<Module> modules = getCoreModules();
    RuntimeMonitorType runtimeMonitorType = SystemArguments.getRuntimeMonitorType(cConf, programOpts);
    modules.add(RuntimeMonitors.getRemoteAuthenticatorModule(runtimeMonitorType, programOpts));
    install(Modules.override(modules).with(new AbstractModule() {

        @Override
        protected void configure() {
            // Overrides the LineageWriter, UsageWriter to write to TMS instead
            bind(LineageWriter.class).to(MessagingLineageWriter.class);
            bind(FieldLineageWriter.class).to(MessagingLineageWriter.class);
            bind(UsageWriter.class).to(MessagingUsageWriter.class);
            // Overrides the metadata store to be no-op (programs never access it directly)
            bind(MetadataStorage.class).to(NoopMetadataStorage.class);
        }
    }));
    bind(RuntimeMonitorType.class).toInstance(runtimeMonitorType);
}
Also used : RuntimeMonitorType(io.cdap.cdap.runtime.spi.RuntimeMonitorType) UsageWriter(io.cdap.cdap.data2.registry.UsageWriter) MessagingUsageWriter(io.cdap.cdap.data2.registry.MessagingUsageWriter) FieldLineageWriter(io.cdap.cdap.data2.metadata.writer.FieldLineageWriter) LineageWriter(io.cdap.cdap.data2.metadata.writer.LineageWriter) MessagingLineageWriter(io.cdap.cdap.data2.metadata.writer.MessagingLineageWriter) MetadataStorage(io.cdap.cdap.spi.metadata.MetadataStorage) NoopMetadataStorage(io.cdap.cdap.spi.metadata.noop.NoopMetadataStorage) Module(com.google.inject.Module) SecureStoreClientModule(io.cdap.cdap.security.guice.SecureStoreClientModule) ConfigModule(io.cdap.cdap.common.guice.ConfigModule) NamespaceQueryAdminModule(io.cdap.cdap.common.namespace.guice.NamespaceQueryAdminModule) SystemDatasetRuntimeModule(io.cdap.cdap.data.runtime.SystemDatasetRuntimeModule) CoreSecurityModule(io.cdap.cdap.security.guice.CoreSecurityModule) DFSLocationModule(io.cdap.cdap.common.guice.DFSLocationModule) KafkaLogAppenderModule(io.cdap.cdap.logging.guice.KafkaLogAppenderModule) MessagingClientModule(io.cdap.cdap.messaging.guice.MessagingClientModule) RemoteLogAppenderModule(io.cdap.cdap.logging.guice.RemoteLogAppenderModule) CoreSecurityRuntimeModule(io.cdap.cdap.security.guice.CoreSecurityRuntimeModule) AuthorizationEnforcementModule(io.cdap.cdap.security.authorization.AuthorizationEnforcementModule) KafkaClientModule(io.cdap.cdap.common.guice.KafkaClientModule) ZKClientModule(io.cdap.cdap.common.guice.ZKClientModule) TMSLogAppenderModule(io.cdap.cdap.logging.guice.TMSLogAppenderModule) AuditModule(io.cdap.cdap.data2.audit.AuditModule) IOModule(io.cdap.cdap.common.guice.IOModule) ZKDiscoveryModule(io.cdap.cdap.common.guice.ZKDiscoveryModule) MetricsClientRuntimeModule(io.cdap.cdap.metrics.guice.MetricsClientRuntimeModule) AbstractModule(com.google.inject.AbstractModule) AbstractModule(com.google.inject.AbstractModule) FieldLineageWriter(io.cdap.cdap.data2.metadata.writer.FieldLineageWriter)

Aggregations

LineageWriter (io.cdap.cdap.data2.metadata.writer.LineageWriter)11 LineageStoreReader (io.cdap.cdap.data2.metadata.lineage.LineageStoreReader)10 Test (org.junit.Test)10 Store (io.cdap.cdap.app.store.Store)8 DefaultLineageStoreReader (io.cdap.cdap.data2.metadata.lineage.DefaultLineageStoreReader)8 Lineage (io.cdap.cdap.data2.metadata.lineage.Lineage)8 Relation (io.cdap.cdap.data2.metadata.lineage.Relation)8 BasicLineageWriter (io.cdap.cdap.data2.metadata.writer.BasicLineageWriter)8 TransactionRunner (io.cdap.cdap.spi.data.transaction.TransactionRunner)8 ProgramRunId (io.cdap.cdap.proto.id.ProgramRunId)6 FieldLineageWriter (io.cdap.cdap.data2.metadata.writer.FieldLineageWriter)3 MessagingLineageWriter (io.cdap.cdap.data2.metadata.writer.MessagingLineageWriter)3 ApplicationSpecification (io.cdap.cdap.api.app.ApplicationSpecification)2 Operation (io.cdap.cdap.api.lineage.field.Operation)2 ReadOperation (io.cdap.cdap.api.lineage.field.ReadOperation)2 TransformOperation (io.cdap.cdap.api.lineage.field.TransformOperation)2 WriteOperation (io.cdap.cdap.api.lineage.field.WriteOperation)2 ScheduleProgramInfo (io.cdap.cdap.api.workflow.ScheduleProgramInfo)2 WorkflowActionNode (io.cdap.cdap.api.workflow.WorkflowActionNode)2 WorkflowNode (io.cdap.cdap.api.workflow.WorkflowNode)2