diff --git a/cloudquery/plugin_v3/plugin_pb2.py b/cloudquery/plugin_v3/plugin_pb2.py index bef548d..02d7713 100644 --- a/cloudquery/plugin_v3/plugin_pb2.py +++ b/cloudquery/plugin_v3/plugin_pb2.py @@ -25,7 +25,7 @@ from google.protobuf import timestamp_pb2 as google_dot_protobuf_dot_timestamp__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n!cloudquery/plugin_v3/plugin.proto\x12\x14\x63loudquery.plugin.v3\x1a\x1fgoogle/protobuf/timestamp.proto\".\n\x07GetName\x1a\t\n\x07Request\x1a\x18\n\x08Response\x12\x0c\n\x04name\x18\x01 \x01(\t\"4\n\nGetVersion\x1a\t\n\x07Request\x1a\x1b\n\x08Response\x12\x0f\n\x07version\x18\x01 \x01(\t\"P\n\rGetSpecSchema\x1a\t\n\x07Request\x1a\x34\n\x08Response\x12\x18\n\x0bjson_schema\x18\x01 \x01(\tH\x00\x88\x01\x01\x42\x0e\n\x0c_json_schema\"Y\n\x04Init\x1a\x45\n\x07Request\x12\x0c\n\x04spec\x18\x01 \x01(\x0c\x12\x15\n\rno_connection\x18\x02 \x01(\x08\x12\x15\n\rinvocation_id\x18\x03 \x01(\t\x1a\n\n\x08Response\"v\n\tGetTables\x1aM\n\x07Request\x12\x0e\n\x06tables\x18\x01 \x03(\t\x12\x13\n\x0bskip_tables\x18\x02 \x03(\t\x12\x1d\n\x15skip_dependent_tables\x18\x03 \x01(\x08\x1a\x1a\n\x08Response\x12\x0e\n\x06tables\x18\x01 \x03(\x0c\"\xb2\x07\n\x04Sync\x1a\x1f\n\rMessageInsert\x12\x0e\n\x06record\x18\x01 \x01(\x0c\x1a$\n\x13MessageMigrateTable\x12\r\n\x05table\x18\x01 \x01(\x0c\x1a\xa4\x01\n\x13MessageDeleteRecord\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12;\n\x0cwhere_clause\x18\x02 \x03(\x0b\x32%.cloudquery.plugin.v3.PredicatesGroup\x12<\n\x0ftable_relations\x18\x03 \x03(\x0b\x32#.cloudquery.plugin.v3.TableRelation\x1a\x31\n\x0cMessageError\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12\r\n\x05\x65rror\x18\x02 \x01(\t\x1a\x38\n\x0e\x42\x61\x63kendOptions\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12\x12\n\nconnection\x18\x02 \x01(\t\x1a\xae\x02\n\x07Request\x12\x0e\n\x06tables\x18\x01 \x03(\t\x12\x13\n\x0bskip_tables\x18\x02 \x03(\t\x12\x1d\n\x15skip_dependent_tables\x18\x03 \x01(\x08\x12\x1b\n\x13\x64\x65terministic_cq_id\x18\x04 \x01(\x08\x12:\n\x07\x62\x61\x63kend\x18\x05 \x01(\x0b\x32).cloudquery.plugin.v3.Sync.BackendOptions\x12<\n\x05shard\x18\x06 \x01(\x0b\x32(.cloudquery.plugin.v3.Sync.Request.ShardH\x00\x88\x01\x01\x12\x19\n\x11withErrorMessages\x18\x07 \x01(\x08\x1a#\n\x05Shard\x12\x0b\n\x03num\x18\x01 \x01(\x05\x12\r\n\x05total\x18\x02 \x01(\x05\x42\x08\n\x06_shard\x1a\x9d\x02\n\x08Response\x12G\n\rmigrate_table\x18\x01 \x01(\x0b\x32..cloudquery.plugin.v3.Sync.MessageMigrateTableH\x00\x12:\n\x06insert\x18\x02 \x01(\x0b\x32(.cloudquery.plugin.v3.Sync.MessageInsertH\x00\x12G\n\rdelete_record\x18\x03 \x01(\x0b\x32..cloudquery.plugin.v3.Sync.MessageDeleteRecordH\x00\x12\x38\n\x05\x65rror\x18\x04 \x01(\x0b\x32\'.cloudquery.plugin.v3.Sync.MessageErrorH\x00\x42\t\n\x07message\"<\n\x04Read\x1a\x18\n\x07Request\x12\r\n\x05table\x18\x01 \x01(\x0c\x1a\x1a\n\x08Response\x12\x0e\n\x06record\x18\x01 \x01(\x0c\"9\n\rTableRelation\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12\x14\n\x0cparent_table\x18\x02 \x01(\t\"{\n\tPredicate\x12:\n\x08operator\x18\x01 \x01(\x0e\x32(.cloudquery.plugin.v3.Predicate.Operator\x12\x0e\n\x06\x63olumn\x18\x02 \x01(\t\x12\x0e\n\x06record\x18\x03 \x01(\x0c\"\x12\n\x08Operator\x12\x06\n\x02\x45Q\x10\x00\"\xb2\x01\n\x0fPredicatesGroup\x12I\n\rgrouping_type\x18\x01 \x01(\x0e\x32\x32.cloudquery.plugin.v3.PredicatesGroup.GroupingType\x12\x33\n\npredicates\x18\x02 \x03(\x0b\x32\x1f.cloudquery.plugin.v3.Predicate\"\x1f\n\x0cGroupingType\x12\x07\n\x03\x41ND\x10\x00\x12\x06\n\x02OR\x10\x01\"\xc3\x05\n\x05Write\x1a;\n\x13MessageMigrateTable\x12\r\n\x05table\x18\x01 \x01(\x0c\x12\x15\n\rmigrate_force\x18\x02 \x01(\x08\x1a\x1f\n\rMessageInsert\x12\x0e\n\x06record\x18\x01 \x01(\x0c\x1a\x7f\n\x12MessageDeleteStale\x12\x11\n\x05table\x18\x01 \x01(\x0c\x42\x02\x18\x01\x12\x13\n\x0bsource_name\x18\x02 \x01(\t\x12-\n\tsync_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x12\n\ntable_name\x18\x04 \x01(\t\x1a\xa4\x01\n\x13MessageDeleteRecord\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12;\n\x0cwhere_clause\x18\x02 \x03(\x0b\x32%.cloudquery.plugin.v3.PredicatesGroup\x12<\n\x0ftable_relations\x18\x03 \x03(\x0b\x32#.cloudquery.plugin.v3.TableRelation\x1a\xa7\x02\n\x07Request\x12H\n\rmigrate_table\x18\x01 \x01(\x0b\x32/.cloudquery.plugin.v3.Write.MessageMigrateTableH\x00\x12;\n\x06insert\x18\x02 \x01(\x0b\x32).cloudquery.plugin.v3.Write.MessageInsertH\x00\x12@\n\x06\x64\x65lete\x18\x03 \x01(\x0b\x32..cloudquery.plugin.v3.Write.MessageDeleteStaleH\x00\x12H\n\rdelete_record\x18\x04 \x01(\x0b\x32/.cloudquery.plugin.v3.Write.MessageDeleteRecordH\x00\x42\t\n\x07message\x1a\n\n\x08Response\"B\n\tTransform\x1a\x19\n\x07Request\x12\x0e\n\x06record\x18\x01 \x01(\x0c\x1a\x1a\n\x08Response\x12\x0e\n\x06record\x18\x01 \x01(\x0c\"H\n\x0fTransformSchema\x1a\x19\n\x07Request\x12\x0e\n\x06schema\x18\x01 \x01(\x0c\x1a\x1a\n\x08Response\x12\x0e\n\x06schema\x18\x01 \x01(\x0c\"\x1e\n\x05\x43lose\x1a\t\n\x07Request\x1a\n\n\x08Response\"y\n\x0eTestConnection\x1a\x17\n\x07Request\x12\x0c\n\x04spec\x18\x01 \x01(\x0c\x1aN\n\x08Response\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x14\n\x0c\x66\x61ilure_code\x18\x02 \x01(\t\x12\x1b\n\x13\x66\x61ilure_description\x18\x03 \x01(\t\"\xc1\x08\n\x0c\x41ssessTables\x1a\x31\n\tTablePair\x12\x11\n\told_table\x18\x01 \x01(\x0c\x12\x11\n\tnew_table\x18\x02 \x01(\x0c\x1a\x42\n\x08\x45vidence\x12\x17\n\x0fsynthetic_value\x18\x01 \x01(\t\x12\x0e\n\x06\x62\x65\x66ore\x18\x02 \x01(\t\x12\r\n\x05\x61\x66ter\x18\x03 \x01(\t\x1a\x80\x02\n\rColumnFinding\x12\x13\n\x0b\x63olumn_name\x18\x01 \x01(\t\x12=\n\x08\x63\x61tegory\x18\x02 \x01(\x0e\x32+.cloudquery.plugin.v3.AssessTables.Category\x12\x10\n\x08old_type\x18\x03 \x01(\t\x12\x10\n\x08new_type\x18\x04 \x01(\t\x12\x1a\n\x12safe_mode_behavior\x18\x05 \x01(\t\x12\x1c\n\x14\x66orced_mode_behavior\x18\x06 \x01(\t\x12=\n\x08\x65vidence\x18\x07 \x03(\x0b\x32+.cloudquery.plugin.v3.AssessTables.Evidence\x1a\xc1\x02\n\x0cTableFinding\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12=\n\x08\x63\x61tegory\x18\x02 \x01(\x0e\x32+.cloudquery.plugin.v3.AssessTables.Category\x12\x1a\n\x12safe_mode_behavior\x18\x03 \x01(\t\x12\x1c\n\x14\x66orced_mode_behavior\x18\x04 \x01(\t\x12\x41\n\x07\x63olumns\x18\x05 \x03(\x0b\x32\x30.cloudquery.plugin.v3.AssessTables.ColumnFinding\x12=\n\x08\x65vidence\x18\x06 \x03(\x0b\x32+.cloudquery.plugin.v3.AssessTables.Evidence\x12\"\n\x1aincomplete_coverage_reason\x18\x07 \x01(\t\x1a^\n\x07Request\x12<\n\x06tables\x18\x01 \x03(\x0b\x32,.cloudquery.plugin.v3.AssessTables.TablePair\x12\x15\n\rmigrate_force\x18\x02 \x01(\x08\x1aK\n\x08Response\x12?\n\x06tables\x18\x01 \x03(\x0b\x32/.cloudquery.plugin.v3.AssessTables.TableFinding\"\xc5\x01\n\x08\x43\x61tegory\x12\x14\n\x10\x43\x41TEGORY_UNKNOWN\x10\x00\x12\x16\n\x12\x43\x41TEGORY_NO_CHANGE\x10\x01\x12%\n!CATEGORY_AUTOMATICALLY_MIGRATABLE\x10\x02\x12&\n\"CATEGORY_MANUAL_MIGRATION_REQUIRED\x10\x03\x12\x1a\n\x16\x43\x41TEGORY_TABLE_REMOVED\x10\x04\x12 \n\x1c\x43\x41TEGORY_FILE_SCHEMA_CHANGED\x10\x05\x32\xe0\t\n\x06Plugin\x12X\n\x07GetName\x12%.cloudquery.plugin.v3.GetName.Request\x1a&.cloudquery.plugin.v3.GetName.Response\x12\x61\n\nGetVersion\x12(.cloudquery.plugin.v3.GetVersion.Request\x1a).cloudquery.plugin.v3.GetVersion.Response\x12j\n\rGetSpecSchema\x12+.cloudquery.plugin.v3.GetSpecSchema.Request\x1a,.cloudquery.plugin.v3.GetSpecSchema.Response\x12O\n\x04Init\x12\".cloudquery.plugin.v3.Init.Request\x1a#.cloudquery.plugin.v3.Init.Response\x12^\n\tGetTables\x12\'.cloudquery.plugin.v3.GetTables.Request\x1a(.cloudquery.plugin.v3.GetTables.Response\x12Q\n\x04Sync\x12\".cloudquery.plugin.v3.Sync.Request\x1a#.cloudquery.plugin.v3.Sync.Response0\x01\x12Q\n\x04Read\x12\".cloudquery.plugin.v3.Read.Request\x1a#.cloudquery.plugin.v3.Read.Response0\x01\x12T\n\x05Write\x12#.cloudquery.plugin.v3.Write.Request\x1a$.cloudquery.plugin.v3.Write.Response(\x01\x12\x62\n\tTransform\x12\'.cloudquery.plugin.v3.Transform.Request\x1a(.cloudquery.plugin.v3.Transform.Response(\x01\x30\x01\x12p\n\x0fTransformSchema\x12-.cloudquery.plugin.v3.TransformSchema.Request\x1a..cloudquery.plugin.v3.TransformSchema.Response\x12R\n\x05\x43lose\x12#.cloudquery.plugin.v3.Close.Request\x1a$.cloudquery.plugin.v3.Close.Response\x12m\n\x0eTestConnection\x12,.cloudquery.plugin.v3.TestConnection.Request\x1a-.cloudquery.plugin.v3.TestConnection.Response\x12g\n\x0c\x41ssessTables\x12*.cloudquery.plugin.v3.AssessTables.Request\x1a+.cloudquery.plugin.v3.AssessTables.ResponseBS\n\x17io.cloudquery.plugin.v3P\x01Z6github.com/cloudquery/plugin-pb-go/pb/plugin/v3;pluginb\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n!cloudquery/plugin_v3/plugin.proto\x12\x14\x63loudquery.plugin.v3\x1a\x1fgoogle/protobuf/timestamp.proto\".\n\x07GetName\x1a\t\n\x07Request\x1a\x18\n\x08Response\x12\x0c\n\x04name\x18\x01 \x01(\t\"4\n\nGetVersion\x1a\t\n\x07Request\x1a\x1b\n\x08Response\x12\x0f\n\x07version\x18\x01 \x01(\t\"P\n\rGetSpecSchema\x1a\t\n\x07Request\x1a\x34\n\x08Response\x12\x18\n\x0bjson_schema\x18\x01 \x01(\tH\x00\x88\x01\x01\x42\x0e\n\x0c_json_schema\"q\n\x04Init\x1a\x45\n\x07Request\x12\x0c\n\x04spec\x18\x01 \x01(\x0c\x12\x15\n\rno_connection\x18\x02 \x01(\x08\x12\x15\n\rinvocation_id\x18\x03 \x01(\t\x1a\"\n\x08Response\x12\x16\n\x0esupports_flush\x18\x01 \x01(\x08\"v\n\tGetTables\x1aM\n\x07Request\x12\x0e\n\x06tables\x18\x01 \x03(\t\x12\x13\n\x0bskip_tables\x18\x02 \x03(\t\x12\x1d\n\x15skip_dependent_tables\x18\x03 \x01(\x08\x1a\x1a\n\x08Response\x12\x0e\n\x06tables\x18\x01 \x03(\x0c\"\xb9\x08\n\x04Sync\x1a\x1f\n\rMessageInsert\x12\x0e\n\x06record\x18\x01 \x01(\x0c\x1a$\n\x13MessageMigrateTable\x12\r\n\x05table\x18\x01 \x01(\x0c\x1a\xa4\x01\n\x13MessageDeleteRecord\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12;\n\x0cwhere_clause\x18\x02 \x03(\x0b\x32%.cloudquery.plugin.v3.PredicatesGroup\x12<\n\x0ftable_relations\x18\x03 \x03(\x0b\x32#.cloudquery.plugin.v3.TableRelation\x1a\x31\n\x0cMessageError\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12\r\n\x05\x65rror\x18\x02 \x01(\t\x1a#\n\x11MessageCheckpoint\x12\x0e\n\x06record\x18\x01 \x01(\x0c\x1a\x38\n\x0e\x42\x61\x63kendOptions\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12\x12\n\nconnection\x18\x02 \x01(\t\x1a\xcc\x02\n\x07Request\x12\x0e\n\x06tables\x18\x01 \x03(\t\x12\x13\n\x0bskip_tables\x18\x02 \x03(\t\x12\x1d\n\x15skip_dependent_tables\x18\x03 \x01(\x08\x12\x1b\n\x13\x64\x65terministic_cq_id\x18\x04 \x01(\x08\x12:\n\x07\x62\x61\x63kend\x18\x05 \x01(\x0b\x32).cloudquery.plugin.v3.Sync.BackendOptions\x12<\n\x05shard\x18\x06 \x01(\x0b\x32(.cloudquery.plugin.v3.Sync.Request.ShardH\x00\x88\x01\x01\x12\x19\n\x11withErrorMessages\x18\x07 \x01(\x08\x12\x1c\n\x14supports_checkpoints\x18\x08 \x01(\x08\x1a#\n\x05Shard\x12\x0b\n\x03num\x18\x01 \x01(\x05\x12\r\n\x05total\x18\x02 \x01(\x05\x42\x08\n\x06_shard\x1a\xe1\x02\n\x08Response\x12G\n\rmigrate_table\x18\x01 \x01(\x0b\x32..cloudquery.plugin.v3.Sync.MessageMigrateTableH\x00\x12:\n\x06insert\x18\x02 \x01(\x0b\x32(.cloudquery.plugin.v3.Sync.MessageInsertH\x00\x12G\n\rdelete_record\x18\x03 \x01(\x0b\x32..cloudquery.plugin.v3.Sync.MessageDeleteRecordH\x00\x12\x38\n\x05\x65rror\x18\x04 \x01(\x0b\x32\'.cloudquery.plugin.v3.Sync.MessageErrorH\x00\x12\x42\n\ncheckpoint\x18\x05 \x01(\x0b\x32,.cloudquery.plugin.v3.Sync.MessageCheckpointH\x00\x42\t\n\x07message\"<\n\x04Read\x1a\x18\n\x07Request\x12\r\n\x05table\x18\x01 \x01(\x0c\x1a\x1a\n\x08Response\x12\x0e\n\x06record\x18\x01 \x01(\x0c\"9\n\rTableRelation\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12\x14\n\x0cparent_table\x18\x02 \x01(\t\"{\n\tPredicate\x12:\n\x08operator\x18\x01 \x01(\x0e\x32(.cloudquery.plugin.v3.Predicate.Operator\x12\x0e\n\x06\x63olumn\x18\x02 \x01(\t\x12\x0e\n\x06record\x18\x03 \x01(\x0c\"\x12\n\x08Operator\x12\x06\n\x02\x45Q\x10\x00\"\xb2\x01\n\x0fPredicatesGroup\x12I\n\rgrouping_type\x18\x01 \x01(\x0e\x32\x32.cloudquery.plugin.v3.PredicatesGroup.GroupingType\x12\x33\n\npredicates\x18\x02 \x03(\x0b\x32\x1f.cloudquery.plugin.v3.Predicate\"\x1f\n\x0cGroupingType\x12\x07\n\x03\x41ND\x10\x00\x12\x06\n\x02OR\x10\x01\"\xd8\x06\n\x05Write\x1a;\n\x13MessageMigrateTable\x12\r\n\x05table\x18\x01 \x01(\x0c\x12\x15\n\rmigrate_force\x18\x02 \x01(\x08\x1a\x1f\n\rMessageInsert\x12\x0e\n\x06record\x18\x01 \x01(\x0c\x1a\x7f\n\x12MessageDeleteStale\x12\x11\n\x05table\x18\x01 \x01(\x0c\x42\x02\x18\x01\x12\x13\n\x0bsource_name\x18\x02 \x01(\t\x12-\n\tsync_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x12\n\ntable_name\x18\x04 \x01(\t\x1a\xa4\x01\n\x13MessageDeleteRecord\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12;\n\x0cwhere_clause\x18\x02 \x03(\x0b\x32%.cloudquery.plugin.v3.PredicatesGroup\x12<\n\x0ftable_relations\x18\x03 \x03(\x0b\x32#.cloudquery.plugin.v3.TableRelation\x1a\x1a\n\x0cMessageFlush\x12\n\n\x02id\x18\x01 \x01(\x04\x1a\xe2\x02\n\x07Request\x12H\n\rmigrate_table\x18\x01 \x01(\x0b\x32/.cloudquery.plugin.v3.Write.MessageMigrateTableH\x00\x12;\n\x06insert\x18\x02 \x01(\x0b\x32).cloudquery.plugin.v3.Write.MessageInsertH\x00\x12@\n\x06\x64\x65lete\x18\x03 \x01(\x0b\x32..cloudquery.plugin.v3.Write.MessageDeleteStaleH\x00\x12H\n\rdelete_record\x18\x04 \x01(\x0b\x32/.cloudquery.plugin.v3.Write.MessageDeleteRecordH\x00\x12\x39\n\x05\x66lush\x18\x05 \x01(\x0b\x32(.cloudquery.plugin.v3.Write.MessageFlushH\x00\x42\t\n\x07message\x1aH\n\x08Response\x12\x10\n\x08\x66lush_id\x18\x01 \x01(\x04\x12\x13\n\x0b\x66lush_error\x18\x02 \x01(\t\x12\x15\n\rfailed_tables\x18\x03 \x03(\t\"B\n\tTransform\x1a\x19\n\x07Request\x12\x0e\n\x06record\x18\x01 \x01(\x0c\x1a\x1a\n\x08Response\x12\x0e\n\x06record\x18\x01 \x01(\x0c\"H\n\x0fTransformSchema\x1a\x19\n\x07Request\x12\x0e\n\x06schema\x18\x01 \x01(\x0c\x1a\x1a\n\x08Response\x12\x0e\n\x06schema\x18\x01 \x01(\x0c\"\x1e\n\x05\x43lose\x1a\t\n\x07Request\x1a\n\n\x08Response\"y\n\x0eTestConnection\x1a\x17\n\x07Request\x12\x0c\n\x04spec\x18\x01 \x01(\x0c\x1aN\n\x08Response\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x14\n\x0c\x66\x61ilure_code\x18\x02 \x01(\t\x12\x1b\n\x13\x66\x61ilure_description\x18\x03 \x01(\t\"\xc1\x08\n\x0c\x41ssessTables\x1a\x31\n\tTablePair\x12\x11\n\told_table\x18\x01 \x01(\x0c\x12\x11\n\tnew_table\x18\x02 \x01(\x0c\x1a\x42\n\x08\x45vidence\x12\x17\n\x0fsynthetic_value\x18\x01 \x01(\t\x12\x0e\n\x06\x62\x65\x66ore\x18\x02 \x01(\t\x12\r\n\x05\x61\x66ter\x18\x03 \x01(\t\x1a\x80\x02\n\rColumnFinding\x12\x13\n\x0b\x63olumn_name\x18\x01 \x01(\t\x12=\n\x08\x63\x61tegory\x18\x02 \x01(\x0e\x32+.cloudquery.plugin.v3.AssessTables.Category\x12\x10\n\x08old_type\x18\x03 \x01(\t\x12\x10\n\x08new_type\x18\x04 \x01(\t\x12\x1a\n\x12safe_mode_behavior\x18\x05 \x01(\t\x12\x1c\n\x14\x66orced_mode_behavior\x18\x06 \x01(\t\x12=\n\x08\x65vidence\x18\x07 \x03(\x0b\x32+.cloudquery.plugin.v3.AssessTables.Evidence\x1a\xc1\x02\n\x0cTableFinding\x12\x12\n\ntable_name\x18\x01 \x01(\t\x12=\n\x08\x63\x61tegory\x18\x02 \x01(\x0e\x32+.cloudquery.plugin.v3.AssessTables.Category\x12\x1a\n\x12safe_mode_behavior\x18\x03 \x01(\t\x12\x1c\n\x14\x66orced_mode_behavior\x18\x04 \x01(\t\x12\x41\n\x07\x63olumns\x18\x05 \x03(\x0b\x32\x30.cloudquery.plugin.v3.AssessTables.ColumnFinding\x12=\n\x08\x65vidence\x18\x06 \x03(\x0b\x32+.cloudquery.plugin.v3.AssessTables.Evidence\x12\"\n\x1aincomplete_coverage_reason\x18\x07 \x01(\t\x1a^\n\x07Request\x12<\n\x06tables\x18\x01 \x03(\x0b\x32,.cloudquery.plugin.v3.AssessTables.TablePair\x12\x15\n\rmigrate_force\x18\x02 \x01(\x08\x1aK\n\x08Response\x12?\n\x06tables\x18\x01 \x03(\x0b\x32/.cloudquery.plugin.v3.AssessTables.TableFinding\"\xc5\x01\n\x08\x43\x61tegory\x12\x14\n\x10\x43\x41TEGORY_UNKNOWN\x10\x00\x12\x16\n\x12\x43\x41TEGORY_NO_CHANGE\x10\x01\x12%\n!CATEGORY_AUTOMATICALLY_MIGRATABLE\x10\x02\x12&\n\"CATEGORY_MANUAL_MIGRATION_REQUIRED\x10\x03\x12\x1a\n\x16\x43\x41TEGORY_TABLE_REMOVED\x10\x04\x12 \n\x1c\x43\x41TEGORY_FILE_SCHEMA_CHANGED\x10\x05\x32\xbe\n\n\x06Plugin\x12X\n\x07GetName\x12%.cloudquery.plugin.v3.GetName.Request\x1a&.cloudquery.plugin.v3.GetName.Response\x12\x61\n\nGetVersion\x12(.cloudquery.plugin.v3.GetVersion.Request\x1a).cloudquery.plugin.v3.GetVersion.Response\x12j\n\rGetSpecSchema\x12+.cloudquery.plugin.v3.GetSpecSchema.Request\x1a,.cloudquery.plugin.v3.GetSpecSchema.Response\x12O\n\x04Init\x12\".cloudquery.plugin.v3.Init.Request\x1a#.cloudquery.plugin.v3.Init.Response\x12^\n\tGetTables\x12\'.cloudquery.plugin.v3.GetTables.Request\x1a(.cloudquery.plugin.v3.GetTables.Response\x12Q\n\x04Sync\x12\".cloudquery.plugin.v3.Sync.Request\x1a#.cloudquery.plugin.v3.Sync.Response0\x01\x12Q\n\x04Read\x12\".cloudquery.plugin.v3.Read.Request\x1a#.cloudquery.plugin.v3.Read.Response0\x01\x12T\n\x05Write\x12#.cloudquery.plugin.v3.Write.Request\x1a$.cloudquery.plugin.v3.Write.Response(\x01\x12\x62\n\tTransform\x12\'.cloudquery.plugin.v3.Transform.Request\x1a(.cloudquery.plugin.v3.Transform.Response(\x01\x30\x01\x12p\n\x0fTransformSchema\x12-.cloudquery.plugin.v3.TransformSchema.Request\x1a..cloudquery.plugin.v3.TransformSchema.Response\x12R\n\x05\x43lose\x12#.cloudquery.plugin.v3.Close.Request\x1a$.cloudquery.plugin.v3.Close.Response\x12m\n\x0eTestConnection\x12,.cloudquery.plugin.v3.TestConnection.Request\x1a-.cloudquery.plugin.v3.TestConnection.Response\x12g\n\x0c\x41ssessTables\x12*.cloudquery.plugin.v3.AssessTables.Request\x1a+.cloudquery.plugin.v3.AssessTables.Response\x12\\\n\x0bWriteStream\x12#.cloudquery.plugin.v3.Write.Request\x1a$.cloudquery.plugin.v3.Write.Response(\x01\x30\x01\x42S\n\x17io.cloudquery.plugin.v3P\x01Z6github.com/cloudquery/plugin-pb-go/pb/plugin/v3;pluginb\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -54,105 +54,109 @@ _globals['_GETSPECSCHEMA_RESPONSE']._serialized_start=222 _globals['_GETSPECSCHEMA_RESPONSE']._serialized_end=274 _globals['_INIT']._serialized_start=276 - _globals['_INIT']._serialized_end=365 + _globals['_INIT']._serialized_end=389 _globals['_INIT_REQUEST']._serialized_start=284 _globals['_INIT_REQUEST']._serialized_end=353 - _globals['_INIT_RESPONSE']._serialized_start=114 - _globals['_INIT_RESPONSE']._serialized_end=124 - _globals['_GETTABLES']._serialized_start=367 - _globals['_GETTABLES']._serialized_end=485 - _globals['_GETTABLES_REQUEST']._serialized_start=380 - _globals['_GETTABLES_REQUEST']._serialized_end=457 - _globals['_GETTABLES_RESPONSE']._serialized_start=459 - _globals['_GETTABLES_RESPONSE']._serialized_end=485 - _globals['_SYNC']._serialized_start=488 - _globals['_SYNC']._serialized_end=1434 - _globals['_SYNC_MESSAGEINSERT']._serialized_start=496 - _globals['_SYNC_MESSAGEINSERT']._serialized_end=527 - _globals['_SYNC_MESSAGEMIGRATETABLE']._serialized_start=529 - _globals['_SYNC_MESSAGEMIGRATETABLE']._serialized_end=565 - _globals['_SYNC_MESSAGEDELETERECORD']._serialized_start=568 - _globals['_SYNC_MESSAGEDELETERECORD']._serialized_end=732 - _globals['_SYNC_MESSAGEERROR']._serialized_start=734 - _globals['_SYNC_MESSAGEERROR']._serialized_end=783 - _globals['_SYNC_BACKENDOPTIONS']._serialized_start=785 - _globals['_SYNC_BACKENDOPTIONS']._serialized_end=841 - _globals['_SYNC_REQUEST']._serialized_start=844 - _globals['_SYNC_REQUEST']._serialized_end=1146 - _globals['_SYNC_REQUEST_SHARD']._serialized_start=1101 - _globals['_SYNC_REQUEST_SHARD']._serialized_end=1136 - _globals['_SYNC_RESPONSE']._serialized_start=1149 - _globals['_SYNC_RESPONSE']._serialized_end=1434 - _globals['_READ']._serialized_start=1436 - _globals['_READ']._serialized_end=1496 - _globals['_READ_REQUEST']._serialized_start=1444 - _globals['_READ_REQUEST']._serialized_end=1468 - _globals['_READ_RESPONSE']._serialized_start=1470 - _globals['_READ_RESPONSE']._serialized_end=1496 - _globals['_TABLERELATION']._serialized_start=1498 - _globals['_TABLERELATION']._serialized_end=1555 - _globals['_PREDICATE']._serialized_start=1557 - _globals['_PREDICATE']._serialized_end=1680 - _globals['_PREDICATE_OPERATOR']._serialized_start=1662 - _globals['_PREDICATE_OPERATOR']._serialized_end=1680 - _globals['_PREDICATESGROUP']._serialized_start=1683 - _globals['_PREDICATESGROUP']._serialized_end=1861 - _globals['_PREDICATESGROUP_GROUPINGTYPE']._serialized_start=1830 - _globals['_PREDICATESGROUP_GROUPINGTYPE']._serialized_end=1861 - _globals['_WRITE']._serialized_start=1864 - _globals['_WRITE']._serialized_end=2571 - _globals['_WRITE_MESSAGEMIGRATETABLE']._serialized_start=1873 - _globals['_WRITE_MESSAGEMIGRATETABLE']._serialized_end=1932 - _globals['_WRITE_MESSAGEINSERT']._serialized_start=496 - _globals['_WRITE_MESSAGEINSERT']._serialized_end=527 - _globals['_WRITE_MESSAGEDELETESTALE']._serialized_start=1967 - _globals['_WRITE_MESSAGEDELETESTALE']._serialized_end=2094 - _globals['_WRITE_MESSAGEDELETERECORD']._serialized_start=568 - _globals['_WRITE_MESSAGEDELETERECORD']._serialized_end=732 - _globals['_WRITE_REQUEST']._serialized_start=2264 - _globals['_WRITE_REQUEST']._serialized_end=2559 - _globals['_WRITE_RESPONSE']._serialized_start=114 - _globals['_WRITE_RESPONSE']._serialized_end=124 - _globals['_TRANSFORM']._serialized_start=2573 - _globals['_TRANSFORM']._serialized_end=2639 - _globals['_TRANSFORM_REQUEST']._serialized_start=2586 - _globals['_TRANSFORM_REQUEST']._serialized_end=2611 - _globals['_TRANSFORM_RESPONSE']._serialized_start=1470 - _globals['_TRANSFORM_RESPONSE']._serialized_end=1496 - _globals['_TRANSFORMSCHEMA']._serialized_start=2641 - _globals['_TRANSFORMSCHEMA']._serialized_end=2713 - _globals['_TRANSFORMSCHEMA_REQUEST']._serialized_start=2660 - _globals['_TRANSFORMSCHEMA_REQUEST']._serialized_end=2685 - _globals['_TRANSFORMSCHEMA_RESPONSE']._serialized_start=2687 - _globals['_TRANSFORMSCHEMA_RESPONSE']._serialized_end=2713 - _globals['_CLOSE']._serialized_start=2715 - _globals['_CLOSE']._serialized_end=2745 + _globals['_INIT_RESPONSE']._serialized_start=355 + _globals['_INIT_RESPONSE']._serialized_end=389 + _globals['_GETTABLES']._serialized_start=391 + _globals['_GETTABLES']._serialized_end=509 + _globals['_GETTABLES_REQUEST']._serialized_start=404 + _globals['_GETTABLES_REQUEST']._serialized_end=481 + _globals['_GETTABLES_RESPONSE']._serialized_start=483 + _globals['_GETTABLES_RESPONSE']._serialized_end=509 + _globals['_SYNC']._serialized_start=512 + _globals['_SYNC']._serialized_end=1593 + _globals['_SYNC_MESSAGEINSERT']._serialized_start=520 + _globals['_SYNC_MESSAGEINSERT']._serialized_end=551 + _globals['_SYNC_MESSAGEMIGRATETABLE']._serialized_start=553 + _globals['_SYNC_MESSAGEMIGRATETABLE']._serialized_end=589 + _globals['_SYNC_MESSAGEDELETERECORD']._serialized_start=592 + _globals['_SYNC_MESSAGEDELETERECORD']._serialized_end=756 + _globals['_SYNC_MESSAGEERROR']._serialized_start=758 + _globals['_SYNC_MESSAGEERROR']._serialized_end=807 + _globals['_SYNC_MESSAGECHECKPOINT']._serialized_start=809 + _globals['_SYNC_MESSAGECHECKPOINT']._serialized_end=844 + _globals['_SYNC_BACKENDOPTIONS']._serialized_start=846 + _globals['_SYNC_BACKENDOPTIONS']._serialized_end=902 + _globals['_SYNC_REQUEST']._serialized_start=905 + _globals['_SYNC_REQUEST']._serialized_end=1237 + _globals['_SYNC_REQUEST_SHARD']._serialized_start=1192 + _globals['_SYNC_REQUEST_SHARD']._serialized_end=1227 + _globals['_SYNC_RESPONSE']._serialized_start=1240 + _globals['_SYNC_RESPONSE']._serialized_end=1593 + _globals['_READ']._serialized_start=1595 + _globals['_READ']._serialized_end=1655 + _globals['_READ_REQUEST']._serialized_start=1603 + _globals['_READ_REQUEST']._serialized_end=1627 + _globals['_READ_RESPONSE']._serialized_start=1629 + _globals['_READ_RESPONSE']._serialized_end=1655 + _globals['_TABLERELATION']._serialized_start=1657 + _globals['_TABLERELATION']._serialized_end=1714 + _globals['_PREDICATE']._serialized_start=1716 + _globals['_PREDICATE']._serialized_end=1839 + _globals['_PREDICATE_OPERATOR']._serialized_start=1821 + _globals['_PREDICATE_OPERATOR']._serialized_end=1839 + _globals['_PREDICATESGROUP']._serialized_start=1842 + _globals['_PREDICATESGROUP']._serialized_end=2020 + _globals['_PREDICATESGROUP_GROUPINGTYPE']._serialized_start=1989 + _globals['_PREDICATESGROUP_GROUPINGTYPE']._serialized_end=2020 + _globals['_WRITE']._serialized_start=2023 + _globals['_WRITE']._serialized_end=2879 + _globals['_WRITE_MESSAGEMIGRATETABLE']._serialized_start=2032 + _globals['_WRITE_MESSAGEMIGRATETABLE']._serialized_end=2091 + _globals['_WRITE_MESSAGEINSERT']._serialized_start=520 + _globals['_WRITE_MESSAGEINSERT']._serialized_end=551 + _globals['_WRITE_MESSAGEDELETESTALE']._serialized_start=2126 + _globals['_WRITE_MESSAGEDELETESTALE']._serialized_end=2253 + _globals['_WRITE_MESSAGEDELETERECORD']._serialized_start=592 + _globals['_WRITE_MESSAGEDELETERECORD']._serialized_end=756 + _globals['_WRITE_MESSAGEFLUSH']._serialized_start=2422 + _globals['_WRITE_MESSAGEFLUSH']._serialized_end=2448 + _globals['_WRITE_REQUEST']._serialized_start=2451 + _globals['_WRITE_REQUEST']._serialized_end=2805 + _globals['_WRITE_RESPONSE']._serialized_start=2807 + _globals['_WRITE_RESPONSE']._serialized_end=2879 + _globals['_TRANSFORM']._serialized_start=2881 + _globals['_TRANSFORM']._serialized_end=2947 + _globals['_TRANSFORM_REQUEST']._serialized_start=2894 + _globals['_TRANSFORM_REQUEST']._serialized_end=2919 + _globals['_TRANSFORM_RESPONSE']._serialized_start=1629 + _globals['_TRANSFORM_RESPONSE']._serialized_end=1655 + _globals['_TRANSFORMSCHEMA']._serialized_start=2949 + _globals['_TRANSFORMSCHEMA']._serialized_end=3021 + _globals['_TRANSFORMSCHEMA_REQUEST']._serialized_start=2968 + _globals['_TRANSFORMSCHEMA_REQUEST']._serialized_end=2993 + _globals['_TRANSFORMSCHEMA_RESPONSE']._serialized_start=2995 + _globals['_TRANSFORMSCHEMA_RESPONSE']._serialized_end=3021 + _globals['_CLOSE']._serialized_start=3023 + _globals['_CLOSE']._serialized_end=3053 _globals['_CLOSE_REQUEST']._serialized_start=103 _globals['_CLOSE_REQUEST']._serialized_end=112 _globals['_CLOSE_RESPONSE']._serialized_start=114 _globals['_CLOSE_RESPONSE']._serialized_end=124 - _globals['_TESTCONNECTION']._serialized_start=2747 - _globals['_TESTCONNECTION']._serialized_end=2868 + _globals['_TESTCONNECTION']._serialized_start=3055 + _globals['_TESTCONNECTION']._serialized_end=3176 _globals['_TESTCONNECTION_REQUEST']._serialized_start=284 _globals['_TESTCONNECTION_REQUEST']._serialized_end=307 - _globals['_TESTCONNECTION_RESPONSE']._serialized_start=2790 - _globals['_TESTCONNECTION_RESPONSE']._serialized_end=2868 - _globals['_ASSESSTABLES']._serialized_start=2871 - _globals['_ASSESSTABLES']._serialized_end=3960 - _globals['_ASSESSTABLES_TABLEPAIR']._serialized_start=2887 - _globals['_ASSESSTABLES_TABLEPAIR']._serialized_end=2936 - _globals['_ASSESSTABLES_EVIDENCE']._serialized_start=2938 - _globals['_ASSESSTABLES_EVIDENCE']._serialized_end=3004 - _globals['_ASSESSTABLES_COLUMNFINDING']._serialized_start=3007 - _globals['_ASSESSTABLES_COLUMNFINDING']._serialized_end=3263 - _globals['_ASSESSTABLES_TABLEFINDING']._serialized_start=3266 - _globals['_ASSESSTABLES_TABLEFINDING']._serialized_end=3587 - _globals['_ASSESSTABLES_REQUEST']._serialized_start=3589 - _globals['_ASSESSTABLES_REQUEST']._serialized_end=3683 - _globals['_ASSESSTABLES_RESPONSE']._serialized_start=3685 - _globals['_ASSESSTABLES_RESPONSE']._serialized_end=3760 - _globals['_ASSESSTABLES_CATEGORY']._serialized_start=3763 - _globals['_ASSESSTABLES_CATEGORY']._serialized_end=3960 - _globals['_PLUGIN']._serialized_start=3963 - _globals['_PLUGIN']._serialized_end=5211 + _globals['_TESTCONNECTION_RESPONSE']._serialized_start=3098 + _globals['_TESTCONNECTION_RESPONSE']._serialized_end=3176 + _globals['_ASSESSTABLES']._serialized_start=3179 + _globals['_ASSESSTABLES']._serialized_end=4268 + _globals['_ASSESSTABLES_TABLEPAIR']._serialized_start=3195 + _globals['_ASSESSTABLES_TABLEPAIR']._serialized_end=3244 + _globals['_ASSESSTABLES_EVIDENCE']._serialized_start=3246 + _globals['_ASSESSTABLES_EVIDENCE']._serialized_end=3312 + _globals['_ASSESSTABLES_COLUMNFINDING']._serialized_start=3315 + _globals['_ASSESSTABLES_COLUMNFINDING']._serialized_end=3571 + _globals['_ASSESSTABLES_TABLEFINDING']._serialized_start=3574 + _globals['_ASSESSTABLES_TABLEFINDING']._serialized_end=3895 + _globals['_ASSESSTABLES_REQUEST']._serialized_start=3897 + _globals['_ASSESSTABLES_REQUEST']._serialized_end=3991 + _globals['_ASSESSTABLES_RESPONSE']._serialized_start=3993 + _globals['_ASSESSTABLES_RESPONSE']._serialized_end=4068 + _globals['_ASSESSTABLES_CATEGORY']._serialized_start=4071 + _globals['_ASSESSTABLES_CATEGORY']._serialized_end=4268 + _globals['_PLUGIN']._serialized_start=4271 + _globals['_PLUGIN']._serialized_end=5613 # @@protoc_insertion_point(module_scope) diff --git a/cloudquery/plugin_v3/plugin_pb2.pyi b/cloudquery/plugin_v3/plugin_pb2.pyi index 17aecff..b209bc9 100644 --- a/cloudquery/plugin_v3/plugin_pb2.pyi +++ b/cloudquery/plugin_v3/plugin_pb2.pyi @@ -58,8 +58,10 @@ class Init(_message.Message): invocation_id: str def __init__(self, spec: _Optional[bytes] = ..., no_connection: bool = ..., invocation_id: _Optional[str] = ...) -> None: ... class Response(_message.Message): - __slots__ = () - def __init__(self) -> None: ... + __slots__ = ("supports_flush",) + SUPPORTS_FLUSH_FIELD_NUMBER: _ClassVar[int] + supports_flush: bool + def __init__(self, supports_flush: bool = ...) -> None: ... def __init__(self) -> None: ... class GetTables(_message.Message): @@ -108,6 +110,11 @@ class Sync(_message.Message): table_name: str error: str def __init__(self, table_name: _Optional[str] = ..., error: _Optional[str] = ...) -> None: ... + class MessageCheckpoint(_message.Message): + __slots__ = ("record",) + RECORD_FIELD_NUMBER: _ClassVar[int] + record: bytes + def __init__(self, record: _Optional[bytes] = ...) -> None: ... class BackendOptions(_message.Message): __slots__ = ("table_name", "connection") TABLE_NAME_FIELD_NUMBER: _ClassVar[int] @@ -116,7 +123,7 @@ class Sync(_message.Message): connection: str def __init__(self, table_name: _Optional[str] = ..., connection: _Optional[str] = ...) -> None: ... class Request(_message.Message): - __slots__ = ("tables", "skip_tables", "skip_dependent_tables", "deterministic_cq_id", "backend", "shard", "withErrorMessages") + __slots__ = ("tables", "skip_tables", "skip_dependent_tables", "deterministic_cq_id", "backend", "shard", "withErrorMessages", "supports_checkpoints") class Shard(_message.Message): __slots__ = ("num", "total") NUM_FIELD_NUMBER: _ClassVar[int] @@ -131,6 +138,7 @@ class Sync(_message.Message): BACKEND_FIELD_NUMBER: _ClassVar[int] SHARD_FIELD_NUMBER: _ClassVar[int] WITHERRORMESSAGES_FIELD_NUMBER: _ClassVar[int] + SUPPORTS_CHECKPOINTS_FIELD_NUMBER: _ClassVar[int] tables: _containers.RepeatedScalarFieldContainer[str] skip_tables: _containers.RepeatedScalarFieldContainer[str] skip_dependent_tables: bool @@ -138,18 +146,21 @@ class Sync(_message.Message): backend: Sync.BackendOptions shard: Sync.Request.Shard withErrorMessages: bool - def __init__(self, tables: _Optional[_Iterable[str]] = ..., skip_tables: _Optional[_Iterable[str]] = ..., skip_dependent_tables: bool = ..., deterministic_cq_id: bool = ..., backend: _Optional[_Union[Sync.BackendOptions, _Mapping]] = ..., shard: _Optional[_Union[Sync.Request.Shard, _Mapping]] = ..., withErrorMessages: bool = ...) -> None: ... + supports_checkpoints: bool + def __init__(self, tables: _Optional[_Iterable[str]] = ..., skip_tables: _Optional[_Iterable[str]] = ..., skip_dependent_tables: bool = ..., deterministic_cq_id: bool = ..., backend: _Optional[_Union[Sync.BackendOptions, _Mapping]] = ..., shard: _Optional[_Union[Sync.Request.Shard, _Mapping]] = ..., withErrorMessages: bool = ..., supports_checkpoints: bool = ...) -> None: ... class Response(_message.Message): - __slots__ = ("migrate_table", "insert", "delete_record", "error") + __slots__ = ("migrate_table", "insert", "delete_record", "error", "checkpoint") MIGRATE_TABLE_FIELD_NUMBER: _ClassVar[int] INSERT_FIELD_NUMBER: _ClassVar[int] DELETE_RECORD_FIELD_NUMBER: _ClassVar[int] ERROR_FIELD_NUMBER: _ClassVar[int] + CHECKPOINT_FIELD_NUMBER: _ClassVar[int] migrate_table: Sync.MessageMigrateTable insert: Sync.MessageInsert delete_record: Sync.MessageDeleteRecord error: Sync.MessageError - def __init__(self, migrate_table: _Optional[_Union[Sync.MessageMigrateTable, _Mapping]] = ..., insert: _Optional[_Union[Sync.MessageInsert, _Mapping]] = ..., delete_record: _Optional[_Union[Sync.MessageDeleteRecord, _Mapping]] = ..., error: _Optional[_Union[Sync.MessageError, _Mapping]] = ...) -> None: ... + checkpoint: Sync.MessageCheckpoint + def __init__(self, migrate_table: _Optional[_Union[Sync.MessageMigrateTable, _Mapping]] = ..., insert: _Optional[_Union[Sync.MessageInsert, _Mapping]] = ..., delete_record: _Optional[_Union[Sync.MessageDeleteRecord, _Mapping]] = ..., error: _Optional[_Union[Sync.MessageError, _Mapping]] = ..., checkpoint: _Optional[_Union[Sync.MessageCheckpoint, _Mapping]] = ...) -> None: ... def __init__(self) -> None: ... class Read(_message.Message): @@ -236,20 +247,33 @@ class Write(_message.Message): where_clause: _containers.RepeatedCompositeFieldContainer[PredicatesGroup] table_relations: _containers.RepeatedCompositeFieldContainer[TableRelation] def __init__(self, table_name: _Optional[str] = ..., where_clause: _Optional[_Iterable[_Union[PredicatesGroup, _Mapping]]] = ..., table_relations: _Optional[_Iterable[_Union[TableRelation, _Mapping]]] = ...) -> None: ... + class MessageFlush(_message.Message): + __slots__ = ("id",) + ID_FIELD_NUMBER: _ClassVar[int] + id: int + def __init__(self, id: _Optional[int] = ...) -> None: ... class Request(_message.Message): - __slots__ = ("migrate_table", "insert", "delete", "delete_record") + __slots__ = ("migrate_table", "insert", "delete", "delete_record", "flush") MIGRATE_TABLE_FIELD_NUMBER: _ClassVar[int] INSERT_FIELD_NUMBER: _ClassVar[int] DELETE_FIELD_NUMBER: _ClassVar[int] DELETE_RECORD_FIELD_NUMBER: _ClassVar[int] + FLUSH_FIELD_NUMBER: _ClassVar[int] migrate_table: Write.MessageMigrateTable insert: Write.MessageInsert delete: Write.MessageDeleteStale delete_record: Write.MessageDeleteRecord - def __init__(self, migrate_table: _Optional[_Union[Write.MessageMigrateTable, _Mapping]] = ..., insert: _Optional[_Union[Write.MessageInsert, _Mapping]] = ..., delete: _Optional[_Union[Write.MessageDeleteStale, _Mapping]] = ..., delete_record: _Optional[_Union[Write.MessageDeleteRecord, _Mapping]] = ...) -> None: ... + flush: Write.MessageFlush + def __init__(self, migrate_table: _Optional[_Union[Write.MessageMigrateTable, _Mapping]] = ..., insert: _Optional[_Union[Write.MessageInsert, _Mapping]] = ..., delete: _Optional[_Union[Write.MessageDeleteStale, _Mapping]] = ..., delete_record: _Optional[_Union[Write.MessageDeleteRecord, _Mapping]] = ..., flush: _Optional[_Union[Write.MessageFlush, _Mapping]] = ...) -> None: ... class Response(_message.Message): - __slots__ = () - def __init__(self) -> None: ... + __slots__ = ("flush_id", "flush_error", "failed_tables") + FLUSH_ID_FIELD_NUMBER: _ClassVar[int] + FLUSH_ERROR_FIELD_NUMBER: _ClassVar[int] + FAILED_TABLES_FIELD_NUMBER: _ClassVar[int] + flush_id: int + flush_error: str + failed_tables: _containers.RepeatedScalarFieldContainer[str] + def __init__(self, flush_id: _Optional[int] = ..., flush_error: _Optional[str] = ..., failed_tables: _Optional[_Iterable[str]] = ...) -> None: ... def __init__(self) -> None: ... class Transform(_message.Message): diff --git a/cloudquery/plugin_v3/plugin_pb2_grpc.py b/cloudquery/plugin_v3/plugin_pb2_grpc.py index 5eb174c..f6b3573 100644 --- a/cloudquery/plugin_v3/plugin_pb2_grpc.py +++ b/cloudquery/plugin_v3/plugin_pb2_grpc.py @@ -99,6 +99,11 @@ def __init__(self, channel): request_serializer=cloudquery_dot_plugin__v3_dot_plugin__pb2.AssessTables.Request.SerializeToString, response_deserializer=cloudquery_dot_plugin__v3_dot_plugin__pb2.AssessTables.Response.FromString, _registered_method=True) + self.WriteStream = channel.stream_stream( + '/cloudquery.plugin.v3.Plugin/WriteStream', + request_serializer=cloudquery_dot_plugin__v3_dot_plugin__pb2.Write.Request.SerializeToString, + response_deserializer=cloudquery_dot_plugin__v3_dot_plugin__pb2.Write.Response.FromString, + _registered_method=True) class PluginServicer(object): @@ -199,6 +204,17 @@ def AssessTables(self, request, context): context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') + def WriteStream(self, request_iterator, context): + """Write resources, like Write, and also accept Write.MessageFlush. + The plugin sends one Write.Response per Write.MessageFlush, once it has tried to commit every message sent before + the flush. Write.Response.flush_error is set if some messages sent since the previous flush may not have been + committed. + Only use it with plugins that set Init.Response.supports_flush. + """ + context.set_code(grpc.StatusCode.UNIMPLEMENTED) + context.set_details('Method not implemented!') + raise NotImplementedError('Method not implemented!') + def add_PluginServicer_to_server(servicer, server): rpc_method_handlers = { @@ -267,6 +283,11 @@ def add_PluginServicer_to_server(servicer, server): request_deserializer=cloudquery_dot_plugin__v3_dot_plugin__pb2.AssessTables.Request.FromString, response_serializer=cloudquery_dot_plugin__v3_dot_plugin__pb2.AssessTables.Response.SerializeToString, ), + 'WriteStream': grpc.stream_stream_rpc_method_handler( + servicer.WriteStream, + request_deserializer=cloudquery_dot_plugin__v3_dot_plugin__pb2.Write.Request.FromString, + response_serializer=cloudquery_dot_plugin__v3_dot_plugin__pb2.Write.Response.SerializeToString, + ), } generic_handler = grpc.method_handlers_generic_handler( 'cloudquery.plugin.v3.Plugin', rpc_method_handlers) @@ -628,3 +649,30 @@ def AssessTables(request, timeout, metadata, _registered_method=True) + + @staticmethod + def WriteStream(request_iterator, + target, + options=(), + channel_credentials=None, + call_credentials=None, + insecure=False, + compression=None, + wait_for_ready=None, + timeout=None, + metadata=None): + return grpc.experimental.stream_stream( + request_iterator, + target, + '/cloudquery.plugin.v3.Plugin/WriteStream', + cloudquery_dot_plugin__v3_dot_plugin__pb2.Write.Request.SerializeToString, + cloudquery_dot_plugin__v3_dot_plugin__pb2.Write.Response.FromString, + options, + channel_credentials, + insecure, + call_credentials, + compression, + wait_for_ready, + timeout, + metadata, + _registered_method=True)