Close the Server Connection
The SDK observes the complete model using the mobx library. This means that any change you make to the model is immediately synced with the working copy on the server. Sending changes to the server happens in the background and automatically, so there is no explicit commit. However, sending changes might take a while and your script should not end before all changes are flushed. In particular, changes are by default sent in batches of 1000 or after 200ms, whichever happens first. To wait until all changes are submitted to the server, use the closeConnection
function of the model
object.
This example shows the function closeConnection
, which you can invoke when working with a workingCopy
instance as a last step before the final commit:
|
|
Continue with How to Find Things in the Model.
Feedback
Was this page helpful?
Glad to hear it! Thank you for your response.
Sorry to hear that. Please tell us how we can improve.