@@ -911,7 +911,76 @@ value {
911911 env.TestWaitNotification (runtime, txId);
912912 TestGetExport (runtime, txId, " /MyRoot" );
913913
914- TestImport (runtime, txId, " /MyRoot" , Sprintf (R"(
914+ TestImport (runtime, ++txId, " /MyRoot" , Sprintf (R"(
915+ ImportFromS3Settings {
916+ endpoint: "localhost:%d"
917+ scheme: HTTP
918+ items {
919+ source_prefix: "Backup1"
920+ destination_path: "/MyRoot/Restored"
921+ }
922+ }
923+ )" , port));
924+ env.TestWaitNotification (runtime, txId);
925+ TestGetImport (runtime, txId, " /MyRoot" );
926+ }
927+
928+ Y_UNIT_TEST (ExportImportUuid) {
929+ TTestBasicRuntime runtime;
930+ TTestEnv env (runtime, TTestEnvOptions ().EnableTablePgTypes (true ));
931+ ui64 txId = 100 ;
932+
933+ TestCreateTable (runtime, ++txId, " /MyRoot" , R"(
934+ Name: "Table"
935+ Columns { Name: "key" Type: "Uint32" }
936+ Columns { Name: "value" Type: "Uuid" }
937+ KeyColumnNames: ["key"]
938+ )" );
939+ env.TestWaitNotification (runtime, txId);
940+
941+ {
942+ TString tablePath = " /MyRoot/Table" ;
943+ int partitionIdx = 0 ;
944+
945+ auto tableDesc = DescribePath (runtime, tablePath, true , true );
946+ const auto & tablePartitions = tableDesc.GetPathDescription ().GetTablePartitions ();
947+ UNIT_ASSERT (partitionIdx < tablePartitions.size ());
948+ const ui64 datashardTabletId = tablePartitions[partitionIdx].GetDatashardId ();
949+
950+ NKikimrMiniKQL::TResult result;
951+ TString error;
952+ NKikimrProto::EReplyStatus status = LocalMiniKQL (runtime, datashardTabletId, Sprintf (R"(
953+ (
954+ (let key '( '('key (Uint32 '%d) ) ) )
955+ (let row '( '('value (Uuid '"%s") ) ) )
956+ (return (AsList (UpdateRow '__user__%s key row) ))
957+ )
958+ )" , 1 , " 0123456789012345" , " Table" ), result, error);
959+
960+ UNIT_ASSERT_VALUES_EQUAL_C (status, NKikimrProto::EReplyStatus::OK, error);
961+ UNIT_ASSERT_VALUES_EQUAL (error, " " );
962+ }
963+
964+ TPortManager portManager;
965+ const ui16 port = portManager.GetPort ();
966+
967+ TS3Mock s3Mock ({}, TS3Mock::TSettings (port));
968+ UNIT_ASSERT (s3Mock.Start ());
969+
970+ TestExport (runtime, ++txId, " /MyRoot" , Sprintf (R"(
971+ ExportToS3Settings {
972+ endpoint: "localhost:%d"
973+ scheme: HTTP
974+ items {
975+ source_path: "/MyRoot/Table"
976+ destination_prefix: "Backup1"
977+ }
978+ }
979+ )" , port));
980+ env.TestWaitNotification (runtime, txId);
981+ TestGetExport (runtime, txId, " /MyRoot" );
982+
983+ TestImport (runtime, ++txId, " /MyRoot" , Sprintf (R"(
915984 ImportFromS3Settings {
916985 endpoint: "localhost:%d"
917986 scheme: HTTP
0 commit comments