-
Notifications
You must be signed in to change notification settings - Fork 38
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
api to run configured profiles #74
Conversation
@@ -37,7 +37,7 @@ docker-build: | |||
. \ | |||
|| exit 1; \ | |||
done | |||
sudo rm -rf vendor | |||
rm -rf vendor |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wondering why we had added sudo. and do you see any issues with sudo ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure when we added it. but when we try to run on the laptop with sudo it asks for password. so thought better to remove it. not needed in any case.
profile/httprouter/handler.go
Outdated
func HTTPExecuteConfigProfile(c *gin.Context) { | ||
|
||
logger.HttpLog.Infoln("ExecuteConfigProfile API called") | ||
//var prof profCtx.Profile |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you want to get rid of commented code ?
profile/httprouter/handler.go
Outdated
profileWaitGrp.Wait() | ||
} | ||
|
||
c.JSON(http.StatusOK, gin.H{}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I realized yesterday that if profile takes lot of time then GUI waits for long time. Perhaps you respond to GUI immediately and then continue execution in background. If new API request comes while previous execution is still in progress then response with 200 again.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should send the result of the execution in the response. had done it in the gui branch. will merge to this. its better than sending empty response.
3ee02ff
to
7cc9d1c
Compare
7cc9d1c
to
a0e5dfa
Compare
No description provided.