Fix volume sync order. (#1340)
This commit is contained in:
		
							parent
							
								
									c1c0d5faa1
								
							
						
					
					
						commit
						772f0ca771
					
				|  | @ -53,6 +53,11 @@ func (c *Cluster) Sync(newSpec *acidv1.Postgresql) error { | |||
| 		return err | ||||
| 	} | ||||
| 
 | ||||
| 	// sync volume may already transition volumes to gp3, if iops/throughput or type is specified
 | ||||
| 	if err = c.syncVolumes(); err != nil { | ||||
| 		return err | ||||
| 	} | ||||
| 
 | ||||
| 	if c.OpConfig.EnableEBSGp3Migration { | ||||
| 		err = c.executeEBSMigration() | ||||
| 		if nil != err { | ||||
|  | @ -60,10 +65,6 @@ func (c *Cluster) Sync(newSpec *acidv1.Postgresql) error { | |||
| 		} | ||||
| 	} | ||||
| 
 | ||||
| 	if err = c.syncVolumes(); err != nil { | ||||
| 		return err | ||||
| 	} | ||||
| 
 | ||||
| 	if err = c.enforceMinResourceLimits(&c.Spec); err != nil { | ||||
| 		err = fmt.Errorf("could not enforce minimum resource limits: %v", err) | ||||
| 		return err | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue