> For the complete documentation index, see [llms.txt](https://developer.harness.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.harness.io/continuous-delivery/troubleshooting-and-resources/armory/general/orca-with-sql-high-memory-usage-tables-information-dive.md).

# Orca with SQL high memory usage / Tables information dive

Important Tables:- orchestration\_stages: Task Stage Executions (ref back to orchestrations)

* orchestrations: Tasks (in Tasks tab)(e.g. Save Pipeline Task)
* pipeline\_stages: Stage Executions (ref back to pipelines)
* pipelines: Pipeline ExecutionsTo Remove Pipeline Executions:- Create temporary tables with the IDs of rows to remove: CREATE TEMPORARY TABLE old\_pipelines SELECT id FROM pipelines WHERE (updated\_at / 1000) Why Why: For each pipeline execution Orca saves data.Each time a user loads an application pipeline view (and hence it's executions) Orca loads said executionsIf a user selects to show even more executions Orca fetches that data.Spinnaker can run smooth and fine for all your applications but one, that can be due that said application pipelines are run more often or have bigger artifacts or are run on a loop or are in the form of parent-child with multiple children or grandchildren. Why why why: Orca stores the entire execution in a single column "body". If a pipeline calls another pipeline ALL the execution of parent pipeline is stored in the child pipeline data instead of an id pointing to said data.

What to avoid:

Recurring pipelines: `A pipeline calling itself grows significantly big rather quick. For a small footprint pipeline with 10kb artifacts your pipeline you can reach 30MB rows in SQL in 10 iterations.` Each bake stage saves the baked artifact 4 times on SQL Each Deploy Stage saves ALL artifacts 2 times on SQL (ALL of them, not just the one used for the deploy)
