Functions: Usage, Considerations and Best Practices

Updated 3 months ago by Copado Solutions

Copado enables you to run functions for multiple purposes and in multiple scenarios. However, there are some limitations and things to consider.

In this article, you can find relevant information about considerations and best practices when executing a function and how function usage works. 

Usage

Copado provides a monthly free execution time (150 minutes) to enable you to test and execute functions. If you use up your free execution time, you need to get additional execution time to continue working with functions.

If you get access to the full functionality, that includes a high monthly execution time which should be enough to suit your needs.

What happens if you exceed your monthly execution time? If you are trying to run a function and have exceeded the monthly execution time, Copado will display an error message. To get additional execution time, you need to contact your customer success manager.

 If you are widely using functions and have Copado installed in a sandbox, you may hit Salesforce’s ContentPublication limit. This limit is reset every 24 hours. If you want to avoid it, you can reach out to Salesforce and get this limit increased. For more information about this, review Salesforce’s documentation.

Considerations

  • With functions, you can build and run your own scripts. The person who builds a custom script is the sole owner of that script, and Copado is not responsible for any undesired consequences the execution of a custom script may have in your orgs.
  • Similarly, if you clone any of the out-of-the-box functions provided by Copado, Copado won’t be responsible for any unwanted outcome the execution of these functions may have.
  • Copado doesn’t provide support for custom scripts. If you encounter any issues while executing a custom script, you can review the functions log in the Result record to troubleshoot the issues further.

Best Practices & Recommendations

  • It is recommended that edit access to functions be restricted to the right users (e.g., only release managers should have access to functions in production).
  • You should test your functions in a sandbox environment first and not directly in production.
  • It is recommended that you have a Git repository where you can store functions and have version control.


How did we do?