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

feat: Bump Up datastore dep to v1.17.0 and Golang version to 1.21 #446

Merged
merged 2 commits into from
Jun 13, 2024

Conversation

Zurvarian
Copy link
Contributor

@Zurvarian Zurvarian commented Jun 11, 2024

What type of PR is this?

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

/kind fix
/kind build
/kind chore
/kind ci
/kind docs
/kind style
/kind refactor
/kind perf
/kind test

/kind feat

What this PR does / Why we need it:
It increases the version of the Datastore dependency to v1.17.0 and Golang version to 1.21
This required to have access to Datastore traces in OpenTelemetry.

Which issue(s) this PR fixes:

Closes #445

Special notes for your reviewer:
Tested locally, here is an example of the new traces being exposed.
imagen

Note that sensible details have been removed.

@vasconcelosvcd
Copy link
Collaborator

/gcbrun

@ghost
Copy link

ghost commented Jun 11, 2024

@Zurvarian

From the go.mod:

go 1.21
toolchain go1.21.9

The build container is complaining about an invalid statement with toolchain:

Step #3: go build -o build/server cmd/server/main.go
Step #3: go: errors parsing go.mod:
Step #3: /workspace/go.mod:5: unknown directive: toolchain
Step #3: make: *** [Makefile:48: build/server] Error 1

I suspect that we will need to ask google to create a new build container with the 1.21 golang version and toolchain for the CI pipeline to pass.

@vasconcelosvcd
Copy link
Collaborator

vasconcelosvcd commented Jun 11, 2024

@Zurvarian

From the go.mod:

go 1.21
toolchain go1.21.9

The build container is complaining about an invalid statement with toolchain:

Step #3: go build -o build/server cmd/server/main.go
Step #3: go: errors parsing go.mod:
Step #3: /workspace/go.mod:5: unknown directive: toolchain
Step #3: make: *** [Makefile:48: build/server] Error 1

I suspect that we will need to ask google to create a new build container with the 1.21 golang version and toolchain for the CI pipeline to pass.

@loranger2k @Zurvarian I think it's a matter of upgrading the cloudrun job file here

https://github.com/googleforgames/open-saves/blob/cec978851b6b6d0fe5479271d9c6a48f5448fd80/cloudbuild.yaml#L49C17-L49C23

@Zurvarian
Copy link
Contributor Author

Thanks for the updates, I missed the builder part.

Indeed the toolchain is a new feature from Golang 1.21 on-wards, meant to fix the exact version the code must be compiled with.
I did fix this in the Docker image, but wasn't aware of the builder.

Once we have a compatible builder I'll update the file mentioned by @vasconcelosvcd

@mbychkowski
Copy link
Collaborator

@Zurvarian just updated the golang builder to 1.21.

I think you will also need to update the cloudbuild.yaml in this PR for _BUILDER variable to 1.21

Then we can retry the build

@Zurvarian
Copy link
Contributor Author

/gcbrun

1 similar comment
@vasconcelosvcd
Copy link
Collaborator

/gcbrun

Copy link
Collaborator

@vasconcelosvcd vasconcelosvcd left a comment

Choose a reason for hiding this comment

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

LGTM

@Zurvarian Zurvarian closed this Jun 13, 2024
@Zurvarian Zurvarian reopened this Jun 13, 2024
@vasconcelosvcd
Copy link
Collaborator

/gcbrun

@vasconcelosvcd vasconcelosvcd merged commit be2588f into googleforgames:main Jun 13, 2024
4 checks passed
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.

3 participants