Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Greetings!
I would like to know if we have any API to capture the logging mode for the tasks. Ex to find if the tasks are set to verbose logging mode
You could consider ExportTask your API. Parse the result for:
cmd.replication_definition->tasks->[yourtaskname]->loggers
You'll need to read the list of returned loggers element, scanning for 'DETAILED DEBUG' or other values as desired. See sample summary below.
Hein
"cmd.replication_definition": {
"tasks": [{
"task": {
"name": "xxx",...
},
"source": { ... },
"targets": { ... },
"manipulations": [{ ... }],
"task_settings": { ... },
"loggers": {
"$type": "RepTaskLoggers",
"TARGET_APPLY": "DETAILED_DEBUG",
"SOURCE_CAPTURE": "INFO" .... }
}],
"databases": [{ ...
Hello @sukanya09 ,
Thanks for your question. I don't see any API that helps with determining if verbose logging is on or not.
I see this in the Replicate User Guide>> https://help.qlik.com/en-US/replicate/May2023/Content/Replicate/Main/Appendix%20-%20Add-On%20SDK/log...
Also In Enterprise Manager, you can see the amount of disk space being used:
disk_usage_mb |
The current utilization of disk space, in MB. A task's disk utilization is sampled every minute. |
As I don't see the exact need, feel free to open an enhancement request and Submit an idea into Ideation :
You may also want to get the assistance of our Professional Services team.
Hope this helps.
Sincerely
BarbF.
You could consider ExportTask your API. Parse the result for:
cmd.replication_definition->tasks->[yourtaskname]->loggers
You'll need to read the list of returned loggers element, scanning for 'DETAILED DEBUG' or other values as desired. See sample summary below.
Hein
"cmd.replication_definition": {
"tasks": [{
"task": {
"name": "xxx",...
},
"source": { ... },
"targets": { ... },
"manipulations": [{ ... }],
"task_settings": { ... },
"loggers": {
"$type": "RepTaskLoggers",
"TARGET_APPLY": "DETAILED_DEBUG",
"SOURCE_CAPTURE": "INFO" .... }
}],
"databases": [{ ...
Thanks. I can find it in the JSON
In general Replicate only puts non-default items in the JSON export. A) it makes for shorter JSON tiles B) If a 'better' default is developed over time, it will be picked up C) it might make conversions easier.
As a script writer it is fairly annoying though and you more or less need to know what to expect and what the absence of something means.
>>> Do you know if we have any similar way to find out the tasks with Full load set to ON ?
Case in point... fullload enabled TRUE is the default and NOT present in general (allthough tolerated) . The absence of the element "common_settings": { ... }, "full_load_enabled": false, ... means fullload is ON.
For the logging in the @sukanya09 case it seems ANY element present under loggers is 'suspect' and needs to be reported for potential excessive logging as a starting point. Next scripting step may be to add exceptions for logger element/taskname combinations which are approved.
Alternatively, use a dummy task with ALL logging enabled, export, and establish a list of possible tag/values to expect.
Hein.