mirror of
				https://github.com/optim-enterprises-bv/vault.git
				synced 2025-10-31 02:28:09 +00:00 
			
		
		
		
	 6b0c692385
			
		
	
	6b0c692385
	
	
	
		
			
			This endpoint causes the node it's hit to step down from active duty. It's a noop if the node isn't active or not running in HA mode. The node will wait one second before attempting to reacquire the lock, to give other nodes a chance to grab it. Fixes #1093
		
			
				
	
	
		
			11 lines
		
	
	
		
			187 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			11 lines
		
	
	
		
			187 B
		
	
	
	
		
			Go
		
	
	
	
	
	
| package api
 | |
| 
 | |
| func (c *Sys) StepDown() error {
 | |
| 	r := c.c.NewRequest("PUT", "/v1/sys/step-down")
 | |
| 	resp, err := c.c.RawRequest(r)
 | |
| 	if err == nil {
 | |
| 		defer resp.Body.Close()
 | |
| 	}
 | |
| 	return err
 | |
| }
 |