CurtHagenlocher commented on code in PR #2691:
URL: https://github.com/apache/arrow-adbc/pull/2691#discussion_r2047276895


##########
csharp/src/Drivers/Databricks/DatabricksConnection.cs:
##########
@@ -29,10 +29,50 @@ namespace Apache.Arrow.Adbc.Drivers.Databricks
 {
     internal class DatabricksConnection : SparkHttpConnection
     {
+        // CloudFetch configuration
+        private const long DefaultMaxBytesPerFile = 20 * 1024 * 1024; // 20MB
+
+        private bool _useCloudFetch = true;
+        private bool _canDecompressLz4 = true;
+        private long _maxBytesPerFile = DefaultMaxBytesPerFile;
+
         public DatabricksConnection(IReadOnlyDictionary<string, string> 
properties) : base(properties)
         {
+            // Parse CloudFetch options from connection properties
+            if (Properties.TryGetValue(DatabricksParameters.UseCloudFetch, out 
string? useCloudFetchStr) &&
+                bool.TryParse(useCloudFetchStr, out bool useCloudFetchValue))
+            {
+                _useCloudFetch = useCloudFetchValue;

Review Comment:
   Consider validating the string property. Right now, if someone were to typo 
as e.g. `properties["CloudFetch"] = "flase";` the property value would be 
silently ignored. (Similarly, `properties["CloudFetc"] = "false";` would be 
ignored but I'm not sure how consistently drivers are producing errors for 
unsupported properties.)



-- 
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-unsubscr...@arrow.apache.org

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

Reply via email to