Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
GOKULAKANNAN
Creator II
Creator II

How to extract the log of an application reload using automation in qlik SAAS

Is there any way to extract the logs from reload of an application using qlik automation?

Labels (2)
9 Replies
ACorona
Contributor III
Contributor III

Looks like you could use an API call inside an automation to get the reload logs
https://community.qlik.com/t5/Qlik-Application-Automation/Accessing-Detailed-Reload-Logs-using-Qlik-...

GOKULAKANNAN
Creator II
Creator II
Author

Thanks for the reply,

I have tried but am getting 500 error, I have used a RAW API request, where am 

https://mytenant.region.qlikcloud.com/api/v1/apps/APPID/reloads/logs/RELOADID as path and using the block mentioned by replacing APP ID, but still its not working

Shai_E
Support
Support

Hi @GOKULAKANNAN 

Any chance you can show an image of the block settings?

Thanks

GOKULAKANNAN
Creator II
Creator II
Author

@Shai_E ,

Its just a simple block, 

Start block followed by RAW API request block, and inside API request block i have given the body as mentioned the above thread

Shai_E
Support
Support

Hi @GOKULAKANNAN 

For me it worked fine with no issues, i used the Qlik Cloud Services - Raw API Request

This is the configuration i used

For path: 

apps/66b0bc29-3aea-4775-b651-cd387aca72f9/reloads/logs/66324014e4563ecb7517e48e

Method: GET 

Did you do the same but with your ids?

 

Thanks

 

 

GOKULAKANNAN
Creator II
Creator II
Author

Hi @Shai_E , I think i have missed to add the ID's, is there any possibility to get the logs from the scheduled task/events in qliksense saas through Automation.

Am looking for a possible solution where if a scheduled task fails it should store the log in a GCS buckets. can we create a automation for this? 

Shai_E
Support
Support

Hi @GOKULAKANNAN 

I assume you mean a scheduled task = reload, if that is the case you can create an automation:

- Set the start block to webhook run mode

Set the connector to Qlik Cloud Services

Set the event to App Reload Finished

- from there you can filter specific app ids that this event will trigger for, as well as the status of the reload

From there you can work on the rest of the functionality

GOKULAKANNAN
Creator II
Creator II
Author

Hi @Shai_E , Could you please ping me the automation which you are using, and also after extracting how can we write those to a file and store it in GCS bucket. We do have blocks for GCS, but am little confused which one to use.Could you please help me with that.

GOKULAKANNAN
Creator II
Creator II
Author

Hi @Shai_E 

my workflow looks like below

GOKULAKANNAN_0-1714740391805.png

and using this as a raw input in the RAW API request

{"blocks":[{"id":"D1A8C9BF-3E56-4DFF-9AE5-671327C860B0","type":"StartBlock","disabled":false,"name":"Start","displayName":"Start","comment":"","childId":"EF6C586A-700B-4DD8-A811-B5C2B716C3F3","inputs":[{"id":"run_mode","value":"manual","type":"select","structure":{}}],"settings":[],"collapsed":[{"name":"loop","isCollapsed":false}],"x":0,"y":0},{"id":"7A4EB57F-63E3-4281-8431-18D9A638121E","type":"EndpointBlock","disabled":false,"name":"rawAPIRequest","displayName":"Qlik Cloud Services - Raw API Request","comment":"","childId":null,"inputs":[{"id":"4add8960-2078-11ec-be2c-7fc55d771fe6","value":"apps/aaaaaaaaa-bbbb-cccc-dddddddddddd/reloads/logs/{$.listReloads.item.id}","type":"string","structure":[]},{"id":"3b992a40-2072-11ec-9f0e-ed01586a7e1b","value":"3ba1eed0-2072-11ec-aa67-f118ee53373a","type":"select","displayValue":"GET","structure":[]},{"id":"3b8b9090-2072-11ec-8c77-5195fbb0ca65","value":[{"key":null,"value":null}],"type":"object","mode":"keyValue","structure":[]},{"id":"993585d0-2839-11ec-b431-df4deed6c1ae","value":[{"key":null,"value":null}],"type":"object","mode":"keyValue","structure":[]}],"settings":[{"id":"blendr_on_error","value":"stop","type":"select","structure":[]},{"id":"cache","value":"0","type":"select","structure":[]},{"id":"automations_censor_data","value":false,"type":"checkbox","structure":[]}],"collapsed":[{"name":"loop","isCollapsed":false}],"x":0,"y":280,"datasourcetype_guid":"61a87510-c7a3-11ea-95da-0fb0c241e75c","endpoint_guid":"3b75dd80-2072-11ec-9043-3b2aff6123af","endpoint_role":"get"},{"id":"EF6C586A-700B-4DD8-A811-B5C2B716C3F3","type":"EndpointBlock","disabled":false,"name":"listReloads","displayName":"Qlik Cloud Services - List Reloads","comment":"","childId":null,"inputs":[{"id":"f287df70-e713-11ea-b5c2-9fdc86b669cb","value":"aaaaaaaaa-bbbb-cccc-dddddddddddd","type":"string","structure":{}}],"settings":[{"id":"maxitemcount","value":"1","type":"string","structure":{}},{"id":"blendr_on_error","value":"stop","type":"select","structure":{}},{"id":"cache","value":"0","type":"select","structure":{}},{"id":"automations_censor_data","value":false,"type":"checkbox","structure":{}}],"collapsed":[{"name":"loop","isCollapsed":false}],"x":0,"y":280,"loopBlockId":"7A4EB57F-63E3-4281-8431-18D9A638121E","datasourcetype_guid":"61a87510-c7a3-11ea-95da-0fb0c241e75c","endpoint_guid":"b3239a30-e713-11ea-be5a-1f4e73bc4bd3","endpoint_role":"list"}],"variables":[]}

I have updated the APP Id as well, but still am getting 500 error, could you please help with that.