Skip to content

Configuration: implement application name, version and client id #554

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

Merged

Conversation

dkropachev
Copy link
Collaborator

@dkropachev dkropachev commented Jun 5, 2025

Make driver report application name, version and client id to server on startup message.

Fixes: #553

Tested:

cqlsh> SELECT client_options FROM system_views.clients;

 client_options
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
                                                                                                          {'CQL_VERSION': '3.4.7', 'DRIVER_NAME': 'DataStax Python Driver', 'DRIVER_VERSION': '3.29.0'}
                                                                                                          {'CQL_VERSION': '3.4.7', 'DRIVER_NAME': 'DataStax Python Driver', 'DRIVER_VERSION': '3.29.0'}
 {'APPLICATION_NAME': 'app_name', 'APPLICATION_VERSION': 'app_version', 'CLIENT_ID': 'client_id', 'CQL_VERSION': '3.0.0', 'DRIVER_NAME': 'ScyllaDB Java Driver', 'DRIVER_VERSION': '3.11.5.8-SNAPSHOT'}
 {'APPLICATION_NAME': 'app_name', 'APPLICATION_VERSION': 'app_version', 'CLIENT_ID': 'client_id', 'CQL_VERSION': '3.0.0', 'DRIVER_NAME': 'ScyllaDB Java Driver', 'DRIVER_VERSION': '3.11.5.8-SNAPSHOT'}

Make driver report application name, version and client id to server on
startup message.
@dkropachev dkropachev force-pushed the dk/553-3x-report-application-information-to-server branch from 56fddc5 to 1315a0e Compare June 5, 2025 03:17
@dkropachev dkropachev self-assigned this Jun 5, 2025
@dkropachev dkropachev requested a review from Bouncheck June 5, 2025 03:19
Copy link
Collaborator

@Bouncheck Bouncheck left a comment

Choose a reason for hiding this comment

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

Two points:
If the CLIENT_ID is not explicitly set, it should be randomly generated, right?

How can user later cross check the CLIENT_ID with the information he obtains from the tables? Should it be logged somewhere once at the start of the session?

@dkropachev
Copy link
Collaborator Author

Two points: If the CLIENT_ID is not explicitly set, it should be randomly generated, right?

No, user get to generate it on they own.

How can user later cross check the CLIENT_ID with the information he obtains from the tables? Should it be logged somewhere once at the start of the session?

It is their job, depends on deployment, on what they want, they may not use it at all.

@dkropachev dkropachev requested a review from Bouncheck June 5, 2025 12:32
Copy link
Collaborator

@Bouncheck Bouncheck left a comment

Choose a reason for hiding this comment

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

If it's meant to be set by the user only then I think it looks ok.

Having it randomly generated if unset could preempt some back and forth in case of user issues, but not having it on by default also saves some bytes.

@dkropachev dkropachev merged commit 53d626f into scylla-3.x Jun 5, 2025
10 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