@@ -136,7 +136,7 @@ def insert_csv_files(
136136 report_level = ReportLevel .FailuresAndSuccesses ,
137137 additional_properties = {"ignoreFirstRecord" : "true" },
138138 )
139- LOGGER .info (T ("coal.logs.ingestion .ingesting" ).format (table = filename ))
139+ LOGGER .info (T ("coal.services.adx .ingesting" ).format (table = filename ))
140140 results : IngestionResult = ingest_client .ingest_from_file (fd , ingestion_properties )
141141 ingestion_ids [str (results .source_id )] = filename
142142 if wait :
@@ -149,14 +149,14 @@ def insert_csv_files(
149149 ):
150150 count += 1
151151 if count > wait_limit :
152- LOGGER .warning (T ("coal.logs.ingestion .max_retry" ))
152+ LOGGER .warning (T ("coal.services.adx .max_retry" ))
153153 break
154154 LOGGER .info (
155- T ("coal.logs.ingestion .waiting_results" ).format (duration = wait_duration , count = count , limit = wait_limit )
155+ T ("coal.services.adx .waiting_results" ).format (duration = wait_duration , count = count , limit = wait_limit )
156156 )
157157 time .sleep (wait_duration )
158158
159- LOGGER .info (T ("coal.logs.ingestion .status" ))
159+ LOGGER .info (T ("coal.services.adx .status" ))
160160 for _id , status in check_ingestion_status (ingest_client , source_ids = list (ingestion_ids .keys ())):
161161 color = (
162162 "red"
@@ -166,10 +166,10 @@ def insert_csv_files(
166166 else "bright_black"
167167 )
168168 LOGGER .info (
169- T ("coal.logs.ingestion .status_report" ).format (table = ingestion_ids [_id ], status = status .name , color = color )
169+ T ("coal.services.adx .status_report" ).format (table = ingestion_ids [_id ], status = status .name , color = color )
170170 )
171171 else :
172- LOGGER .info (T ("coal.logs.ingestion .no_wait" ))
172+ LOGGER .info (T ("coal.services.adx .no_wait" ))
173173
174174
175175def send_runner_data (
@@ -205,13 +205,13 @@ def send_runner_data(
205205 queries = construct_create_query (csv_data )
206206 kusto_client , ingest_client = initialize_clients (adx_uri , adx_ingest_uri )
207207 for k , v in queries .items ():
208- LOGGER .info (T ("coal.logs.ingestion .creating_table" ).format (query = v ))
208+ LOGGER .info (T ("coal.services.adx .creating_table" ).format (table_name = k , database = database_name ))
209209 r : KustoResponseDataSet = run_query (kusto_client , database_name , v )
210210 if r .errors_count == 0 :
211- LOGGER .info (T ("coal.logs.ingestion .table_created" ).format (table = k ))
211+ LOGGER .info (T ("coal.services.adx .table_created" ).format (table_name = k ))
212212 else :
213- LOGGER .error (T ("coal.logs.ingestion .table_creation_failed" ).format (table = k ))
214- LOGGER .error (T ("coal.logs.ingestion .exceptions" ).format (exceptions = r .get_exceptions ()))
213+ LOGGER .error (T ("coal.services.adx .table_creation_failed" ).format (table_name = k , database = database_name ))
214+ LOGGER .error (T ("coal.services.adx .exceptions" ).format (exceptions = r .get_exceptions ()))
215215 raise RuntimeError (f"Failed to create table { k } " )
216216 insert_csv_files (
217217 files_data = csv_data ,
0 commit comments