Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Enhance SEA HTTP Client #618

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

Draft
wants to merge 12 commits into
base: ext-links-sea
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/databricks/sql/auth/retry.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,8 @@ def __init__(
allowed_methods=["POST"],
status_forcelist=[429, 503, *self.force_dangerous_codes],
)

urllib3_kwargs.update(**_urllib_kwargs_we_care_about)
_urllib_kwargs_we_care_about.update(**urllib3_kwargs)
urllib3_kwargs = _urllib_kwargs_we_care_about

super().__init__(
**urllib3_kwargs,
Expand Down
8 changes: 4 additions & 4 deletions src/databricks/sql/backend/sea/backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import logging
import time
import re
from typing import Dict, Tuple, List, Optional, Union, TYPE_CHECKING, Set
from typing import Any, Dict, Tuple, List, Optional, Union, TYPE_CHECKING, Set

from databricks.sql.backend.sea.models.base import ExternalLink, ResultManifest
from databricks.sql.backend.sea.utils.constants import (
Expand Down Expand Up @@ -49,7 +49,7 @@


def _filter_session_configuration(
session_configuration: Optional[Dict[str, str]]
session_configuration: Optional[Dict[str, Any]]
) -> Optional[Dict[str, str]]:
if not session_configuration:
return None
Expand All @@ -59,7 +59,7 @@ def _filter_session_configuration(

for key, value in session_configuration.items():
if key.upper() in ALLOWED_SESSION_CONF_TO_DEFAULT_VALUES_MAP:
filtered_session_configuration[key.lower()] = value
filtered_session_configuration[key.lower()] = str(value)
else:
ignored_configs.add(key)

Expand Down Expand Up @@ -183,7 +183,7 @@ def max_download_threads(self) -> int:

def open_session(
self,
session_configuration: Optional[Dict[str, str]],
session_configuration: Optional[Dict[str, Any]],
catalog: Optional[str],
schema: Optional[str],
) -> SessionId:
Expand Down
Loading
Loading