5 Aug 2022

Using argument "adskDebug" to troubleshot failure job of Design Automation

Default blog image

Debugging the Design Automation job is always a challenge since all the work is done in the cloud engine, and the Design Automation cloud sandbox will be destroyed as soon as the job is finished.

A couple months ago, our Design Automation engineering team implemented a new feature to enable the user to collect debugging info for DA jobs, this was used only by Autodesk internal users. But we found it is a very useful feature, and could help external Design Automation developers to diagnose their failed jobs much easier, so we decided to make it public to everyone. And the flag works for all the Design Automation engines. 

The flag is very straightforward to be used, just add the following argument when you post your DA workitem,

"adskDebug": {
     "uploadJobFolder": true
 }

As one of Revit engine example, the workitem payload is like:

{
    "activityId": "Revit.RvtIOCountItActivity2022+prod",
    "arguments": {
        "rvtFile": {
                "url": "…/sample.rvt",
                "verb": "get"
            },
        "countItParams": {
                "url": "data:application/json,{'walls': false, 'floors': true, 'doors': true, 'windows': true}"
            },
        "result": {
                "url": "…/result.txt",
                "verb": "put"
            },
        "adskDebug": {
                "uploadJobFolder": true
            }
    }
}

With this argument, when the job failed, developer can get a link to a zip file by "debugInfoUrl" from the response of GET Workitem as follow for an example(it can be either found from the report log file):

Debug Info Url

 

By downloading the zip file, you will see it contains debugging bits, e.g. Revit journals, downloaded inputs, etc., this helps a lot to track what happened on the Design Automation cloud engine.

Debug Info

 

Related Article


Posted By

Zhong Wu

Zhong Wu started his career in Autodesk since 2006 on AutoCAD Architecture as a software developer with more than 6 years working experience. After that, Zhong moved to Autodesk Development Network(now is renamed to Forge Partner Development) team as a Developer Advocate mainly focus on the API support/consultant for Maya/MotionBuilder, and started to contribute in Forge evangelism and support with the growing...