@@ -286,13 +286,15 @@ func (dg *mqlAwsCodedeployDeploymentGroup) onPremisesInstanceTagFilters() ([]int
286286
287287func (dg * mqlAwsCodedeployDeploymentGroup ) lastSuccessfulDeployment () (* mqlAwsCodedeployDeployment , error ) {
288288 if dg .sdkData .LastSuccessfulDeployment == nil || dg .sdkData .LastSuccessfulDeployment .DeploymentId == nil {
289+ dg .LastSuccessfulDeployment = plugin.TValue [* mqlAwsCodedeployDeployment ]{State : plugin .StateIsSet | plugin .StateIsNull }
289290 return nil , nil
290291 }
291292 return getDeploymentResource (dg .MqlRuntime , dg .Region .Data , & dg .ApplicationName .Data , & dg .DeploymentGroupName .Data , dg .sdkData .LastSuccessfulDeployment .DeploymentId )
292293}
293294
294295func (dg * mqlAwsCodedeployDeploymentGroup ) lastAttemptedDeployment () (* mqlAwsCodedeployDeployment , error ) {
295296 if dg .sdkData .LastAttemptedDeployment == nil || dg .sdkData .LastAttemptedDeployment .DeploymentId == nil {
297+ dg .LastAttemptedDeployment = plugin.TValue [* mqlAwsCodedeployDeployment ]{State : plugin .StateIsSet | plugin .StateIsNull }
296298 return nil , nil
297299 }
298300 return getDeploymentResource (dg .MqlRuntime , dg .Region .Data , & dg .ApplicationName .Data , & dg .DeploymentGroupName .Data , dg .sdkData .LastAttemptedDeployment .DeploymentId )
@@ -320,10 +322,7 @@ func (dg *mqlAwsCodedeployDeploymentGroup) loadBalancerInfo() (interface{}, erro
320322}
321323
322324func (d * mqlAwsCodedeployDeployment ) id () (string , error ) {
323- // Deployments are identified by their ID, which is unique within an AWS account and region.
324- // Construct a synthetic ARN-like ID for uniqueness if needed, or use DeploymentId.
325- // Using DeploymentId as it's the primary identifier returned by the API for a specific deployment.
326- return d .DeploymentId .Data , nil
325+ return d .Arn .Data , nil
327326}
328327
329328type mqlAwsCodedeployDeploymentInternal struct {
@@ -382,9 +381,9 @@ func listDeployments(runtime *plugin.Runtime, region string, appName, dgName *st
382381 var nextToken * string
383382 for {
384383 listInput := & codedeploy.ListDeploymentsInput {
385- ApplicationName : appName ,
386- // DeploymentGroupName: dgName,
387- NextToken : nextToken ,
384+ ApplicationName : appName ,
385+ DeploymentGroupName : dgName ,
386+ NextToken : nextToken ,
388387 }
389388 // Potentially filter by IncludeOnlyStatuses for active ones if desired
390389 // listInput.IncludeOnlyStatuses = []codedeploytypes.DeploymentStatus{DeploymentStatusInProgress, DeploymentStatusQueued, DeploymentStatusReady}
0 commit comments