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

Tweaks to Client SDK reference #3541

Merged

Conversation

markmandel
Copy link
Member

What type of PR is this?

Uncomment only one /kind <> line, press enter to put that in a new line, and remove leading whitespace from that line:

/kind breaking
/kind bug
/kind cleanup

/kind documentation

/kind feature
/kind hotfix
/kind release

What this PR does / Why we need it:

Went through the SDK reference:

  • Reduced documentation length by setting top level comments or removing what (I think) are redundant statements to make consumption and comprehension easier.
  • Some of the docs were Go SDK specific. Made it more generic (mostly around return of booleans), as different languages may handle SDK commands slightly differently.
  • Put player tracking under counter and lists, since counters and lists is the replacement
  • Added a note on counters and lists replacing player tracking.
  • Consistency with capitalisation.

Which issue(s) this PR fixes:

Work on #2716

Special notes for your reviewer:

Please let me know if you disagree with any of the changes.


This function removes the specific string value string from a List's values.

An error is returned if the string does not exist in the list.
Copy link
Member Author

Choose a reason for hiding this comment

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

(not for this release, just food for thought) - depending on feedback, we may want to revisit some of the handling of thing like returning an error if the value is already in the list. I feel like a non-error return of false (or language equivalent) in this scenario is a better developer experience, since we can't do very good cross platform enumeration of different types of errors? 🤔

Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm thinking it would probably make most sense just to move this all over to the specific Go SDK reference, since that's really what these methods are.

Copy link
Member Author

Choose a reason for hiding this comment

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

We always have a high level reference that is (generally) the basis for all language SDK guides. This makes building language agnostic integration guides easier, and general concept onboarding also easier, since we don't have to duplicate as much language across language SDK references.

Copy link
Member Author

Choose a reason for hiding this comment

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

Or are you saying, let's just move the existing test over to the Go SDK? (now I read your comment again @igooch )

My point was more - we might want to tweak the Go SDK itself in terms of how it does error handling vs boolean returns, which may impact how the backing gRPC/REST client operates. But like I said - not for this release, just something to think about. I might file an issue for discussion after playing with this more once it's released.

Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm talking about the reference guide modified in this PR, not any test. These methods are specific to the Go client.

Copy link
Member Author

Choose a reason for hiding this comment

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

These methods are specific to the Go client.

They are also specific to what will be built for the other language SDKs as well. That's why I made them more generic, so they could be used as the conceptual basis for pretty much all language SDKs.

The Go SDK will have it's own generated docs for it's own language specific reference.

Copy link
Member Author

Choose a reason for hiding this comment

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

For example, we link off to https://pkg.go.dev/agones.dev/agones/sdks/go#Alpha.GetListCapacity (which already got generated in the last release)

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: fd42e6a0-3bae-4822-b156-f317a3f97bd7

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@markmandel
Copy link
Member Author

site/search/index.html
  Non-OK status: 404 --- site/search/index.html --> https://www.youtube.com/playlist?list=PLhkWKwFGACw2dFpdmwxOyUCzlGP2-n7uF
  Non-OK status: 404 --- site/search/index.html --> https://www.youtube.com/playlist?list=PLhkWKwFGACw2dFpdmwxOyUCzlGP2-n7uF

okay, so that's a blocker. Looking at a fix now.

@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: 15edb576-3c13-4506-ba05-165456c10b16

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:

  • git fetch https://github.com/googleforgames/agones.git pull/3541/head:pr_3541 && git checkout pr_3541
  • helm install agones ./install/helm/agones --namespace agones-system --set agones.image.registry=us-docker.pkg.dev/agones-images/ci --set agones.image.tag=1.37.0-dev-89bb821-amd64

Went through the SDK reference:

* Reduced documentation length by setting top level comments or
removing what (I think) are redundant statements to make consumption and
comprehension easier.
* Some of the docs were Go SDK specific. Made it more generic (mostly
around return of booleans), as different languages may handle SDK
commands slightly differently.
* Put player tracking under counter and lists, since counters and lists
is the replacement
* Added a note on counters and lists replacing player tracking.
* Consistency with capitalisation.

Work on googleforgames#2716
@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: f52224d7-304e-4ef6-be01-b72a8df49693

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@markmandel
Copy link
Member Author

generic-1.28 was flaking a bunch

VERBOSE:         	Test:       	TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.989" level=info msg="Length of pod list is 3" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.990" level=info msg="Name of extensions pod 0: agones-extensions-7b5b7ff4bc-mgx9m" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.990" level=info msg="Host IP 10.138.0.102" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.990" level=info msg="Pod IPs [{10.72.11.11}]" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.990" level=info msg="Name of extensions pod 1: agones-extensions-7df9784b69-px9g7" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.990" level=info msg="Host IP 10.138.0.24" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.990" level=info msg="Pod IPs [{10.72.9.38}]" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.990" level=info msg="Name of extensions pod 2: agones-extensions-7df9784b69-v9c4c" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.990" level=info msg="Host IP 10.138.0.80" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.991" level=info msg="Pod IPs [{10.72.5.17}]" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-14 22:54:55.991" level=info msg="Removing one of the Extensions Pods: agones-extensions-7df9784b69-px9g7" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: panic: test timed out after 10m0s
VERBOSE: running tests:
VERBOSE: 	TestGameServerCreationAfterDeletingOneExtensionsPod (10m0s)

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 109f00ec-ed32-421e-b9f9-85d13a479bad

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@markmandel
Copy link
Member Author

Okay, this seems like a consistent failure... weird.

VERBOSE:         	Error Trace:	/go/src/agones.dev/agones/test/e2e/extensions/high_availability_test.go:36
VERBOSE:         	Error:      	Received unexpected error:
VERBOSE:         	            	context deadline exceeded
VERBOSE:         	Test:       	TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.398" level=info msg="Length of pod list is 4" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.398" level=info msg="Name of extensions pod 0: agones-extensions-575b9b8b85-hhstl" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.398" level=info msg="Host IP 10.138.0.24" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.398" level=info msg="Pod IPs [{10.72.9.45}]" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.398" level=info msg="Name of extensions pod 1: agones-extensions-5d8d46b879-2ljnr" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.398" level=info msg="Host IP 10.138.0.80" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.399" level=info msg="Pod IPs [{10.72.5.40}]" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.399" level=info msg="Name of extensions pod 2: agones-extensions-5d8d46b879-gwzv8" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.399" level=info msg="Host IP 10.138.0.80" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.399" level=info msg="Pod IPs [{10.72.5.41}]" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.399" level=info msg="Name of extensions pod 3: agones-extensions-7b5b7ff4bc-mgx9m" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.399" level=info msg="Host IP 10.138.0.102" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.399" level=info msg="Pod IPs [{10.72.11.11}]" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: time="2023-12-15 00:34:39.399" level=info msg="Removing one of the Extensions Pods: agones-extensions-5d8d46b879-2ljnr" test=TestGameServerCreationAfterDeletingOneExtensionsPod
VERBOSE: panic: test timed out after 10m0s
VERBOSE: running tests:
VERBOSE: 	TestGameServerCreationAfterDeletingOneExtensionsPod (10m0s)
VERBOSE: 
VERBOSE: goroutine 647 [running]:
VERBOSE: testing.(*M).startAlarm.func1()
VERBOSE: 	/usr/local/go/src/testing/testing.go:2241 +0x219
VERBOSE: created by time.goFunc
VERBOSE: 	/usr/local/go/src/time/sleep.go:176 +0x48

@markmandel
Copy link
Member Author

I cleared out the 1.28-generic cluster, let's see if that improves things.

@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: 88e81639-1ea3-43a0-8a05-b57a6dd29533

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:

  • git fetch https://github.com/googleforgames/agones.git pull/3541/head:pr_3541 && git checkout pr_3541
  • helm install agones ./install/helm/agones --namespace agones-system --set agones.image.registry=us-docker.pkg.dev/agones-images/ci --set agones.image.tag=1.37.0-dev-0175ea2-amd64

@roberthbailey
Copy link
Member

LGTM (but not going to merge yet to give @igooch a chance to respond to your comments).

@roberthbailey roberthbailey merged commit 66caba4 into googleforgames:main Dec 15, 2023
4 checks passed
@markmandel markmandel deleted the docs/update-sdk-reference branch January 3, 2024 04:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/documentation Documentation for Agones size/M
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants