@@ -345,14 +345,15 @@ class DatasetService {
345
345
private updateDruidDataSource = async ( draftDataset : Record < string , any > , transaction : Transaction , existingDatasource : Record < string , any > ) => {
346
346
347
347
const liveDataset = await this . getDataset ( draftDataset . dataset_id , [ "id" , "api_version" ] , true ) ;
348
- const { created_by, updated_by, dataset_id, api_version } = draftDataset ;
348
+ const { created_by, updated_by, dataset_id, id } = draftDataset ;
349
349
const allFields = await tableGenerator . getAllFields ( draftDataset , "druid" ) ;
350
350
const ingestionSpec = tableGenerator . getDruidIngestionSpec ( draftDataset , allFields , existingDatasource . datasource_ref ) ;
351
351
let draftDatasource = existingDatasource
352
352
_ . set ( draftDatasource , "ingestion_spec" , ingestionSpec )
353
353
_ . set ( draftDatasource , "created_by" , created_by ) ;
354
354
_ . set ( draftDatasource , "updated_by" , updated_by ) ;
355
355
_ . set ( draftDatasource , "type" , "druid" ) ;
356
+ _ . set ( draftDatasource , "dataset_id" , id ) ;
356
357
if ( _ . get ( liveDataset , "api_version" ) === "v1" ) {
357
358
_ . set ( draftDatasource , "datasource" , dataset_id )
358
359
}
0 commit comments