birschick-bq commented on code in PR #3794:
URL: https://github.com/apache/arrow-adbc/pull/3794#discussion_r2700037107
##########
csharp/src/Drivers/Apache/Hive2/HiveServer2HttpConnection.cs:
##########
@@ -150,6 +154,12 @@ protected override TTransport CreateTransport()
httpClient.DefaultRequestHeaders.AcceptEncoding.Add(new
StringWithQualityHeaderValue("identity"));
httpClient.DefaultRequestHeaders.ExpectContinue = false;
+ activity?.AddTag(ActivityKeys.Encrypted,
TlsOptions.IsTlsEnabled.ToString());
Review Comment:
@CurtHagenlocher
This has to do with a previous failed attempt to use
[`JsonSerializerContext`](https://github.com/birschick-bq/arrow-adbc/commit/13dac005031b2a5167369d19d440eedb424efc14#diff-f5e1edbd8f00745b597d6fff29f31cf692699f34b42e581ae4ee94a7605dba95)
for the `SerialializableActivity` class.
When using `JsonSerializerContext`, it would throw and exception if it
didn't know how to serialize a particular object that was added to a Tag (e.g.,
collection, etc.). This issue could be fixed by adding that class to the
definition, but that would mean any instrumenters of tracing would have to
remember to decorate this class.
So, I ended up removing it.
My intention is to simplify the AddTag so that only types that could be
handled by `JsonSerializerContext` natively should be added.
I think I went overboard, as I believe numeric and boolean types should
serialize fine.
At any rate, if we do restrict the types passed to AddTag, we can do that in
one change rather than a trickle.
I'll remove the ToString() usage except for enums, where the name is better
than than the number.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]