-
Notifications
You must be signed in to change notification settings - Fork 820
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
Enhance Logs readability of SDK Conformance Tests #1453
Conversation
Build Succeeded 👏 Build Id: ba75c5bb-4540-4194-8836-ab2e69062782 The following development artifacts have been built, and will exist for the next 30 days:
A preview of the website (the last 30 builds are retained): To install this version:
|
416d785
to
08fb8dc
Compare
Build Succeeded 👏 Build Id: c8cc227f-f1f0-4550-aa3d-df41d49362b4 The following development artifacts have been built, and will exist for the next 30 days:
A preview of the website (the last 30 builds are retained): To install this version:
|
Build Succeeded 👏 Build Id: d9602fd4-1665-44fe-86cc-195ff6d3fb8c The following development artifacts have been built, and will exist for the next 30 days:
A preview of the website (the last 30 builds are retained): To install this version:
|
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.
LGTM! Happy to approve once we are out of feature freeze!
@@ -15,8 +15,8 @@ | |||
# limitations under the License. | |||
|
|||
cd /go/src/agones.dev/agones/test/sdk/nodejs | |||
npm install | |||
npm rebuild | |||
npm install --quiet |
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.
Nice!
RUN curl -sL https://deb.nodesource.com/setup_12.x | bash - && \ | ||
apt-get install -y nodejs | ||
apt-get install -qq -y nodejs |
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.
Also nice! Good idea to reduce the noise!
@@ -143,7 +143,7 @@ run-sdk-conformance-no-build: FEATURE_GATES ?= | |||
run-sdk-conformance-no-build: ensure-agones-sdk-image | |||
run-sdk-conformance-no-build: ensure-build-sdk-image | |||
DOCKER_RUN_ARGS="--net host -e AGONES_SDK_GRPC_PORT=$(GRPC_PORT) -e AGONES_SDK_HTTP_PORT=$(HTTP_PORT) -e FEATURE_GATES=$(FEATURE_GATES) $(DOCKER_RUN_ARGS)" COMMAND=sdktest $(MAKE) run-sdk-command & \ | |||
docker run -p $(GRPC_PORT):$(GRPC_PORT) -p $(HTTP_PORT):$(HTTP_PORT) -e "FEATURE_GATES=$(FEATURE_GATES)" -e "ADDRESS=" -e "TEST=$(TESTS)" -e "TIMEOUT=$(TIMEOUT)" -e "DELAY=$(DELAY)" \ | |||
docker run -p $(GRPC_PORT):$(GRPC_PORT) -p $(HTTP_PORT):$(HTTP_PORT) -e "FEATURE_GATES=$(FEATURE_GATES)" -e "ADDRESS=" -e "TEST=$(TESTS)" -e "SDK_NAME=$(SDK_FOLDER)" -e "TIMEOUT=$(TIMEOUT)" -e "DELAY=$(DELAY)" \ |
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.
🙌
gsState: agonesv1.GameServerStateScheduled, | ||
} | ||
l.logger = runtime.NewLoggerWithType(l) |
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.
Nice addition!
// SetSdkName set SDK name to be added to the logs | ||
func (l *LocalSDKServer) SetSdkName(sdkName string) { | ||
l.testSdkName = sdkName | ||
l.logger = l.logger.WithField("sdkName", l.testSdkName) |
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.
Perfect. Love it.
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.
Thanks now at least logs from local SDK server would be labeled with SDK name. Hope to label SDK test clients in the future (second half of logs).
Remove noisy npm and apt-get logs.
08fb8dc
to
56ffd4c
Compare
New changes are detected. LGTM label has been removed. |
Rebased to a fresh master, no changes to the code were made. |
Build Failed 😱 Build Id: 1b39bfff-48e0-42df-a0b4-a8c1a7facd42 To get permission to view the Cloud Build view, join the agones-discuss Google Group. |
e291318
to
fff3356
Compare
Build Succeeded 👏 Build Id: dab77125-f1ab-486f-961f-d740cd530a40 The following development artifacts have been built, and will exist for the next 30 days:
A preview of the website (the last 30 builds are retained): To install this version:
|
pkg/sdkserver/localsdk.go
Outdated
// recordRequest append request name to slice | ||
func (l *LocalSDKServer) recordRequest(request string) { | ||
if l.testMode { | ||
l.testMutex.Lock() | ||
defer l.testMutex.Unlock() | ||
l.requestSequence = append(l.requestSequence, request) | ||
} | ||
if l.testSdkName != "" { | ||
l.logger.Debugf("Received %s requets", request) |
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.
Typo: request
Build Succeeded 👏 Build Id: 6a74bca0-1b66-408e-bff8-e50149a65920 The following development artifacts have been built, and will exist for the next 30 days:
A preview of the website (the last 30 builds are retained): To install this version:
|
pkg/sdkserver/localsdk.go
Outdated
if _, ok := aSet[v]; !ok { | ||
l.logger.Infof("Found an element which was not expected %s", v) |
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.
.WithField().Error() ?
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.
Thanks, here definitely should go an error, as well as this helps me to identify one fmt.Print
usage.
fff3356
to
189e307
Compare
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: akremsa, aLekSer, markmandel The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@akremsa: changing LGTM is restricted to collaborators In response to this: Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Build Succeeded 👏 Build Id: 12e9fd85-fd9c-413e-a4a2-c2fe488230fa The following development artifacts have been built, and will exist for the next 30 days:
A preview of the website (the last 30 builds are retained): To install this version:
|
Add more detaied logging for local SDK server. Make npm and apt-get less noisy. apt-get install openjdk-8-jre spares about 25% of output. For googleforgames#1452 . * SDK conformance tests - enhance logging Remove noisy npm and apt-get logs. * Use logrus.Entry to tag all local SDK logs. * Simple ParseEnvFlags test.
Add more detaied logging for local SDK server. Make
npm
andapt-get
less noisy.apt-get install openjdk-8-jre
spares about 25% of output.For #1452 .