Deleting SQL lines from Deployment Database

cbahls's Avatar

cbahls

26 Jan, 2018 02:51 PM

Hello,

We are using octopus to deploy a health check. It runs every minute, therefore creating 1440 lines everyday. I was wondering if deleting those lines from the SQL table would cause any issues.

Please advise.
Thanks!

  1. Support Staff 1 Posted by Michael Compton on 29 Jan, 2018 09:26 AM

    Michael Compton's Avatar

    Hi, thanks for getting in touch with this question.

    Before I give you any advice, I just want to clarify what you are asking. Firstly, are you running a health check as part of a machine policy every minute (or is it part of a deployment). Also, can you let me know why the rows are an issue for you and which table and rows you are referring to.

    In general, deleting from the database can have unintended consequences, and if there is a setting that helps achieve what you require I'll help you set it up.

    Michael

  2. 2 Posted by cbahls on 12 Feb, 2018 03:07 PM

    cbahls's Avatar

    We are utilizing Octopus to execute PowerShell scripts that are a part of a deployment being executed every minute. We wrote a task scheduler that handle this. The rows that are of a concern are in the deployment database. A line is being written every deployment. In this case we are deploying every minute and writing approximate 1440 lines per day. We don’t need the logs for the deployment of the health script and would like to eliminate them from that table. Is there a way to set it up to not write it out to the database?

  3. Support Staff 3 Posted by Michael Compton on 13 Feb, 2018 01:16 AM

    Michael Compton's Avatar

    Hi,

    If you want to delete the whole deployment and it's associated logs from Octopus. The best way is to use the Deployment delete endpoint in the Web API. Check out the swagger docs at [YourOctopusServerURL]/swaggerui/.

    We've also got a new feature coming for recurring scheduled deployments, which might be of interest to you. You can read about it here. We are planning to release it in our March release.

    Michael

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac