Builds new models with added slowstart server parameter.

>From 7638bf05e36f3ae890e4d023acbfeb60bee4b802 Mon Sep 17 00:00:00 2001
From: Stefan Scheglmann <scheglm...@strato.de>
Date: Thu, 30 Apr 2020 13:05:49 +0200
Subject: [PATCH] MINOR: server: adds slowstart parameter

Newly generated models, adding support for slowstart paramter in
servers. Generated from updated haproxy-spec.yml from updated
dataplaneapi-specification.
---
 server.go | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

diff --git a/server.go b/server.go
index ae99d90..5fbd5c7 100644
--- a/server.go
+++ b/server.go
@@ -153,6 +153,10 @@ type Server struct {
        // Enum: [enabled disabled]
        SendProxyV2 string `json:"send-proxy-v2,omitempty"`

+       // slowstart
+       // Pattern: ^[1-9][0-9]*(us|ms|s|m|h|d)$
+       Slowstart string `json:"slowstart,omitempty"`
+
        // sni
        // Pattern: ^[^\s]+$
        Sni string `json:"sni,omitempty"`
@@ -277,6 +281,10 @@ func (m *Server) Validate(formats strfmt.Registry) error {
                res = append(res, err)
        }

+       if err := m.validateSlowstart(formats); err != nil {
+               res = append(res, err)
+       }
+
        if err := m.validateSni(formats); err != nil {
                res = append(res, err)
        }
@@ -918,6 +926,19 @@ func (m *Server) validateSendProxyV2(formats 
strfmt.Registry) error {
        return nil
 }

+func (m *Server) validateSlowstart(formats strfmt.Registry) error {
+
+       if swag.IsZero(m.Slowstart) { // not required
+               return nil
+       }
+
+       if err := validate.Pattern("slowstart", "body", string(m.Slowstart), 
`^[1-9][0-9]*(us|ms|s|m|h|d)$`); err != nil {
+               return err
+       }
+
+       return nil
+}
+
 func (m *Server) validateSni(formats strfmt.Registry) error {

        if swag.IsZero(m.Sni) { // not required
--
2.20.1 (Apple Git-117)

--

Kind regards,

Stefan Scheglmann
PAAS Developer

E-mail   scheglm...@strato.de
Website  www.strato.com

STRATO AG | Pascalstra├če 10 | 10587 Berlin | Germany

The mandatory information can be found here 
https://www.strato-hosting.co.uk/imprint/

Reply via email to