You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "zeroshade (via GitHub)" <gi...@apache.org> on 2024/02/07 17:17:23 UTC

[PR] chore(snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

zeroshade opened a new pull request, #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525

   To help Snowflake track adoption and usage of the ADBC driver, we can explicitly add a prefix to any client application name to indicate the ADBC driver is the source of the requests.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "zeroshade (via GitHub)" <gi...@apache.org>.
zeroshade commented on PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#issuecomment-1932528418

   My intent was to prefix to the users choice so we can still track it, but I'm fine with just having it not override at all if we think that's better.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "zeroshade (via GitHub)" <gi...@apache.org>.
zeroshade commented on PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#issuecomment-1932533560

   gosnowflake has an internal application name that is not externally changeable so regardless of the User's application name, snowflake can track it's coming from the Go driver. So they don't need to prefix


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "lidavidm (via GitHub)" <gi...@apache.org>.
lidavidm commented on PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#issuecomment-1932532096

   IMO if gosnowflake doesn't prefix we shouldn't either (does it?); and in Go and Python we should set defaults if they're not set by the user (so Snowflake can track the Go/Python drivers otherwise)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "lidavidm (via GitHub)" <gi...@apache.org>.
lidavidm commented on code in PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#discussion_r1481866896


##########
python/adbc_driver_snowflake/adbc_driver_snowflake/__init__.py:
##########
@@ -131,7 +131,10 @@ def connect(
     kwargs = (db_kwargs or {}).copy()
     if uri is not None:
         kwargs["uri"] = uri
-    kwargs.setdefault(DatabaseOptions.APPLICATION_NAME, "[ADBC][Python]")
+    appname = kwargs.get(DatabaseOptions.APPLICATION_NAME.value, "")
+    kwargs[DatabaseOptions.APPLICATION_NAME.value] = (
+        f"[ADBC][Python-{__version__}]" + appname

Review Comment:
   ```suggestion
           f"[ADBC][Python-{__version__}]{appname}"
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "lidavidm (via GitHub)" <gi...@apache.org>.
lidavidm commented on code in PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#discussion_r1481829808


##########
python/adbc_driver_snowflake/adbc_driver_snowflake/__init__.py:
##########
@@ -131,6 +131,7 @@ def connect(
     kwargs = (db_kwargs or {}).copy()
     if uri is not None:
         kwargs["uri"] = uri
+    kwargs[DatabaseOptions.APPLICATION_NAME] = "[ADBC][Python]" + kwargs.get(DatabaseOptions.APPLICATION_NAME, "")

Review Comment:
   Use `dict.setdefault` so that we don't override the user choice?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "zeroshade (via GitHub)" <gi...@apache.org>.
zeroshade merged PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "zeroshade (via GitHub)" <gi...@apache.org>.
zeroshade commented on code in PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#discussion_r1481833476


##########
python/adbc_driver_snowflake/adbc_driver_snowflake/__init__.py:
##########
@@ -131,6 +131,7 @@ def connect(
     kwargs = (db_kwargs or {}).copy()
     if uri is not None:
         kwargs["uri"] = uri
+    kwargs[DatabaseOptions.APPLICATION_NAME] = "[ADBC][Python]" + kwargs.get(DatabaseOptions.APPLICATION_NAME, "")

Review Comment:
   I wanted to prefix it to the user choice if they had one set



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "zeroshade (via GitHub)" <gi...@apache.org>.
zeroshade commented on code in PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#discussion_r1481845757


##########
go/adbc/driver/snowflake/snowflake_database.go:
##########


Review Comment:
   good point, i intended to do so and forgot lol



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "lidavidm (via GitHub)" <gi...@apache.org>.
lidavidm commented on PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#issuecomment-1932545925

   > > Ah...and we can't get access to that?
   > 
   > Yeap. We can't get access to that unfortunately. They said the preferred method would be to pass it as the application name or prefix the user's choice.
   
   Ah, sorry...if they are OK with prefixing the user's choice then I'm ok with that too.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "lidavidm (via GitHub)" <gi...@apache.org>.
lidavidm commented on code in PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#discussion_r1481843220


##########
go/adbc/driver/snowflake/snowflake_database.go:
##########


Review Comment:
   nit: should we set a default in Go, too?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "lidavidm (via GitHub)" <gi...@apache.org>.
lidavidm commented on PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#issuecomment-1932532676

   If only there were separate user-agent and application fields


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] chore(snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#issuecomment-1932519525

   :warning: Please follow the [Conventional Commits format in CONTRIBUTING.md](https://github.com/apache/arrow-adbc/blob/main/CONTRIBUTING.md) for PR titles.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "zeroshade (via GitHub)" <gi...@apache.org>.
zeroshade commented on PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#issuecomment-1932541206

   > Ah...and we can't get access to that?
   
   Yeap. We can't get access to that unfortunately. They said the preferred method would be to pass it as the application name or prefix the user's choice.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(go/adbc/driver/snowflake): add '[ADBC]' to snowflake application name [arrow-adbc]

Posted by "lidavidm (via GitHub)" <gi...@apache.org>.
lidavidm commented on PR #1525:
URL: https://github.com/apache/arrow-adbc/pull/1525#issuecomment-1932539505

   Ah...and we can't get access to that? :sweat_smile: It would be nice if we could expose this sort of thing separately


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org