Warm tip: This article is reproduced from serverfault.com, please click

Best way to pass lengthy parameter to a Work Item

发布于 2021-02-22 16:07:31

I would like to generate Revit files via DesignAutomation API, prefilled with Types and Layers that come from an external data source.

The source can contain +10k types, and i would like to know what is the best approach to feed this data to the Work Item. Can i run into limitations regarding processing time or size? How can i estimate cloud credit cost of such a process?

If i upload it to a Bucket can the addin code access it? Are there any examples for using Bucket this way?

I could also build it into the plugin code if necessary, but would like to avoid this.

Any hints appreciated.

update: So i could not find a way to include the lengthy json file itself in the initial work item request, i had to create a web service that provides an endpoint from which Forge can download the json file(s).

Questioner
bitwise
Viewed
1
Ashwin ShivaShankar 2021-02-23 00:52:27

Can i run into limitations regarding processing time or size? How can i estimate cloud credit cost of such a process?

What you're looking for may be here - service limits. You may run into limits regarding processing time, but since the limitProcessingTimeSec includes download and upload time for workitems you can change this value if you are running into issues.

The source can contain +10k types, and i would like to know what is the best approach to feed this data to the Work Item.

If you would like to download extra information for a WorkItem at the beginning of a job you are able to bundle it in a zip file which then gets unzipped by the service. If you're looking for specific quotas to make sure you are not going over, you can see the quota limit here.

If i upload it to a Bucket can the addin code access it? Are there any examples for using Bucket this way?

If you'd like to access an external file while the job is running, you can look at the onDemand input here.