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 connector.version as build property #121

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

mr-bat
Copy link
Collaborator

@mr-bat mr-bat commented Nov 8, 2023

No description provided.

@mr-bat
Copy link
Collaborator Author

mr-bat commented Nov 8, 2023

/gcbrun

@halio-g
Copy link
Collaborator

halio-g commented Nov 8, 2023

/gcbrun

@halio-g
Copy link
Collaborator

halio-g commented Nov 8, 2023

/gcbrun

Properties buildProperties = new Properties();
buildProperties.load(
SpannerUtils.class.getResourceAsStream("/spark-spanner-connector.properties"));
System.out.println(buildProperties.getProperty("connector.version"));
Copy link
Member

Choose a reason for hiding this comment

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

Please don't use System.out.println(), replace it with logger

System.out.println(buildProperties.getProperty("connector.version"));
return buildProperties;
} finally {
System.out.println("FAILED");
Copy link
Member

Choose a reason for hiding this comment

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

Please don't use System.out.println(), replace it with logger

@@ -0,0 +1,2 @@
#connector.version=${project.version}
connector.version=3.1
Copy link
Member

Choose a reason for hiding this comment

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

Any reason for that? the idea is to track the connector's version for the user agent

SpannerUtils.class.getResourceAsStream("/spark-spanner-connector.properties"));
return buildProperties;
} finally {
return new Properties();
Copy link
Member

Choose a reason for hiding this comment

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

This will fail line 74

@halio-g
Copy link
Collaborator

halio-g commented Nov 15, 2023

Let's revert the pr. Since it's out of date.

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.

4 participants