(client safeWriteClient, tables map[string]bool, sourceName string, syncTime time.Time)
| 811 | } |
| 812 | |
| 813 | func deleteStale(client safeWriteClient, tables map[string]bool, sourceName string, syncTime time.Time) error { |
| 814 | for tableName := range tables { |
| 815 | if err := client.Send(&plugin.Write_Request{ |
| 816 | Message: &plugin.Write_Request_Delete{ |
| 817 | Delete: &plugin.Write_MessageDeleteStale{ |
| 818 | SourceName: sourceName, |
| 819 | SyncTime: timestamppb.New(syncTime), |
| 820 | TableName: tableName, |
| 821 | }, |
| 822 | }, |
| 823 | }); err != nil { |
| 824 | return err |
| 825 | } |
| 826 | } |
| 827 | |
| 828 | return nil |
| 829 | } |
| 830 | |
| 831 | // createTableNameSchema creates a minimal Arrow schema containing only table metadata |
| 832 | // This schema can be processed through the same transformation pipeline as MigrateTable |
no test coverage detected