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: SQL Server - sqlServerRequestsV2- added s.[login_name] #9955

Conversation

princebansal
Copy link

Required for all PRs:

This PR is an extension to #8351. Currently sqlServerRequestsV2 in sqlqueriesV2.go doesn't give SQL login name and only nt_user_name.
resolves #
This PR will add s.login_name in the output which will be helpful in logging the SQL server login name.

@telegraf-tiger
Copy link
Contributor

Thanks so much for the pull request!
🤝 ✒️ Just a reminder that the CLA has not yet been signed, and we'll need it before merging. Please sign the CLA when you get a chance, then post a comment here saying !signed-cla

@telegraf-tiger telegraf-tiger bot added the fix pr to fix corresponding bug label Oct 19, 2021
@princebansal
Copy link
Author

!signed-cla

@princebansal princebansal changed the title SQL Server - sqlServerRequestsV2- added s.[login_name] Feat: SQL Server - sqlServerRequestsV2- added s.[login_name] Oct 19, 2021
@princebansal
Copy link
Author

@denzilribeiro @sspaink Can you have a look at this and merge it? Need this flag urgently for our use case.

@sspaink
Copy link
Contributor

sspaink commented Oct 19, 2021

Can you rebase your pull request with master? The CI is out of date and we are now using Go 1.17. The PR itself looks good, thanks for the contribution.

@princebansal princebansal force-pushed the feature/login-name-sql-server-requests branch from 3914058 to 56bf149 Compare October 19, 2021 18:55
@princebansal
Copy link
Author

@sspaink Thanks for the quick revert and approval. I have rebased the branch with master. Can we go ahead with the merge?
Also after merge, how will the release work? Is there a way I can use the latest build with these changes right away, or will I have to wait for the next release cycle?

@sspaink sspaink added the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Oct 19, 2021
@sspaink
Copy link
Contributor

sspaink commented Oct 19, 2021

@princebansal before it can be merged it will need to be reviewed by another member of the core Telegraf team, I've labeled the pr with ready for final review so it will be reviewed soon. The telegraf-tiger bot just posted the artifacts containing your fix that you can use immediately so you don't have to wait for the next release cycle. Once it is merged into master there are also nightly artifacts built that you can begin using (you can find those here: https://github.com/influxdata/telegraf/blob/master/docs/NIGHTLIES.md).

@sspaink
Copy link
Contributor

sspaink commented Oct 19, 2021

The Semantic Pull Request is failing because the commit in the pr doesn't abide to the conventional commit message. Can you amend the commit message to contain feat: as well? Thanks!

@princebansal princebansal force-pushed the feature/login-name-sql-server-requests branch from 56bf149 to b5fc7d4 Compare October 20, 2021 07:40
@princebansal
Copy link
Author

@sspaink Thanks again for the update. I have amended the commit message to the correct format.
Regarding the release:
I am actually using the base docker image of telegraf for my use case. Will the nightly docker image also be published upon the merge in master?
Also if none of this works, when is next release being planned?

Thanks!

@princebansal
Copy link
Author

@Hipska Can you please review this?

@Hipska
Copy link
Contributor

Hipska commented Oct 21, 2021

I cannot approve this PR since the README states this:

Version 2 (query_version=2): Being deprecated, All future development will be under configuration option database_type.

So please make updates to the specific database type instead of version2.

@princebansal
Copy link
Author

@Hipska Thanks a lot for that pointer. I saw that by specifying database_type="AzureSQLDB" in telegraf-conf.conf, I was able to get login_name since login_name is already included in https://github.com/influxdata/telegraf/blob/master/plugins/inputs/sqlserver/azuresqlqueries.go.

I think we can close this PR. :)

@Hipska Hipska closed this Oct 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix pr to fix corresponding bug ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants