Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add max-connections annotation #546

Merged
merged 9 commits into from Sep 28, 2017
Merged

Add max-connections annotation #546

merged 9 commits into from Sep 28, 2017

Conversation

diptadas
Copy link
Contributor

No description provided.

sadlil
sadlil previously approved these changes Sep 26, 2017
@@ -21,6 +21,7 @@ import (
apiv1 "k8s.io/client-go/pkg/api/v1"
apps "k8s.io/client-go/pkg/apis/apps/v1beta1"
extensions "k8s.io/client-go/pkg/apis/extensions/v1beta1"
"strconv"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

run a ./hack/make.py

@@ -27,6 +29,11 @@ type HttpServerHandler struct {
}

func (h HttpServerHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
if delay, err := strconv.Atoi(r.URL.Query().Get("delay")); err == nil {
fmt.Println("delay", delay)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove fmt.Print

@@ -50,6 +57,11 @@ type HttpsServerHandler struct {
}

func (h HttpsServerHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
if delay, err := strconv.Atoi(r.URL.Query().Get("delay")); err == nil {
fmt.Println("delay", delay)
time.Sleep(time.Second * time.Duration(delay))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

strconv.Atoi use time.ParseDuration() that parse string to Duration, that could also support 10s

@tamalsaha tamalsaha merged commit 6c34cf6 into master Sep 28, 2017
@tamalsaha tamalsaha deleted the maxconn branch September 28, 2017 10:47
tamalsaha pushed a commit that referenced this pull request Dec 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants