Skip to content

Commit

Permalink
fix: chartRef fetch in historical deployment triggers (#4654)
Browse files Browse the repository at this point in the history
  • Loading branch information
kartik-579 committed Feb 11, 2024
1 parent 977690b commit 488f955
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion internal/sql/repository/DeploymentTemplateRepository.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func (impl DeploymentTemplateRepositoryImpl) FetchDeploymentHistoryWithChartRefs
limit := 15

query := "select p.id as pipeline_id, dth.id as deployment_template_history_id," +
" wfr.finished_on, wfr.status, ceco.chart_id, c.chart_version FROM cd_workflow_runner wfr" +
" wfr.finished_on, wfr.status, c.chart_ref_id, c.chart_version FROM cd_workflow_runner wfr" +
" JOIN cd_workflow wf ON wf.id = wfr.cd_workflow_id JOIN pipeline p ON p.id = wf.pipeline_id" +
" JOIN deployment_template_history dth ON dth.deployed_on = wfr.started_on " +
"JOIN pipeline_config_override pco ON pco.cd_workflow_id = wf.id " +
Expand Down
2 changes: 1 addition & 1 deletion pkg/pipeline/WorkflowDagExecutor.go
Original file line number Diff line number Diff line change
Expand Up @@ -3852,7 +3852,7 @@ func (impl *WorkflowDagExecutorImpl) GetEnvOverrideByTriggerType(overrideRequest
}
//getting chart_ref by id
_, span = otel.Tracer("orchestrator").Start(ctx, "chartRefRepository.FindByVersionAndName")
chartRefDto, err := impl.chartRefService.FindByVersionAndName(templateName, templateVersion)
chartRefDto, err := impl.chartRefService.FindByVersionAndName(templateVersion, templateName)
span.End()
if err != nil {
impl.logger.Errorw("error in getting chartRef by version and name", "err", err, "version", templateVersion, "name", templateName)
Expand Down

0 comments on commit 488f955

Please sign in to comment.