Commit 0a7a6ab
authored
SEA: Fetch Phase (#650)
* Separate Session related functionality from Connection class (#571)
* decouple session class from existing Connection
ensure maintenance of current APIs of Connection while delegating
responsibility
Signed-off-by: varun-edachali-dbx <[email protected]>
* add open property to Connection to ensure maintenance of existing API
Signed-off-by: varun-edachali-dbx <[email protected]>
* update unit tests to address ThriftBackend through session instead of through Connection
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: move session specific tests from test_client to test_session
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
as in CONTRIBUTING.md
Signed-off-by: varun-edachali-dbx <[email protected]>
* use connection open property instead of long chain through session
Signed-off-by: varun-edachali-dbx <[email protected]>
* trigger integration workflow
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: ensure open attribute of Connection never fails
in case the openSession takes long, the initialisation of the session
will not complete immediately. This could make the session attribute
inaccessible. If the Connection is deleted in this time, the open()
check will throw because the session attribute does not exist. Thus, we
default to the Connection being closed in this case. This was not an
issue before because open was a direct attribute of the Connection
class. Caught in the integration tests.
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: de-complicate earlier connection open logic
earlier, one of the integration tests was failing because 'session was
not an attribute of Connection'. This is likely tied to a local
configuration issue related to unittest that was causing an error in the
test suite itself. The tests are now passing without checking for the
session attribute.
https://github.com/databricks/databricks-sql-python/pull/567/commits/c676f9b0281cc3e4fe9c6d8216cc62fc75eade3b
Signed-off-by: varun-edachali-dbx <[email protected]>
* Revert "fix: de-complicate earlier connection open logic"
This reverts commit d6b1b196c98a6e9d8e593a88c34bbde010519ef4.
Signed-off-by: varun-edachali-dbx <[email protected]>
* [empty commit] attempt to trigger ci e2e workflow
Signed-off-by: varun-edachali-dbx <[email protected]>
* Update CODEOWNERS (#562)
new codeowners
Signed-off-by: varun-edachali-dbx <[email protected]>
* Enhance Cursor close handling and context manager exception management to prevent server side resource leaks (#554)
* Enhance Cursor close handling and context manager exception management
* tests
* fmt
* Fix Cursor.close() to properly handle CursorAlreadyClosedError
* Remove specific test message from Cursor.close() error handling
* Improve error handling in connection and cursor context managers to ensure proper closure during exceptions, including KeyboardInterrupt. Add tests for nested cursor management and verify operation closure on server-side errors.
* add
* add
Signed-off-by: varun-edachali-dbx <[email protected]>
* PECOBLR-86 improve logging on python driver (#556)
* PECOBLR-86 Improve logging for debug level
Signed-off-by: Sai Shree Pradhan <[email protected]>
* PECOBLR-86 Improve logging for debug level
Signed-off-by: Sai Shree Pradhan <[email protected]>
* fixed format
Signed-off-by: Sai Shree Pradhan <[email protected]>
* used lazy logging
Signed-off-by: Sai Shree Pradhan <[email protected]>
* changed debug to error logs
Signed-off-by: Sai Shree Pradhan <[email protected]>
* used lazy logging
Signed-off-by: Sai Shree Pradhan <[email protected]>
---------
Signed-off-by: Sai Shree Pradhan <[email protected]>
Signed-off-by: varun-edachali-dbx <[email protected]>
* Revert "Merge remote-tracking branch 'upstream/sea-migration' into decouple-session"
This reverts commit dbb2ec52306b91072a2ee842270c7113aece9aff, reversing
changes made to 7192f117279d4f0adcbafcdf2238c18663324515.
Signed-off-by: varun-edachali-dbx <[email protected]>
* Reapply "Merge remote-tracking branch 'upstream/sea-migration' into decouple-session"
This reverts commit bdb83817f49e1d88a01679b11da8e55e8e80b42f.
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: separate session opening logic from instantiation
ensures correctness of self.session.open call in Connection
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: use is_open attribute to denote session availability
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: access thrift backend through session
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: use get_handle() instead of private session attribute in client
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: remove accidentally removed assertions
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
Signed-off-by: Sai Shree Pradhan <[email protected]>
Co-authored-by: Jothi Prakash <[email protected]>
Co-authored-by: Madhav Sainanee <[email protected]>
Co-authored-by: Sai Shree Pradhan <[email protected]>
* Introduce Backend Interface (DatabricksClient) (#573)
NOTE: the `test_complex_types` e2e test was not working at the time of this merge. The test must be triggered when the test is back up and running as intended.
* remove excess logs, assertions, instantiations
large merge artifacts
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black) + remove excess log (merge artifact)
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix typing
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary check
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary replace call
Signed-off-by: varun-edachali-dbx <[email protected]>
* introduce __str__ methods for CommandId and SessionId
Signed-off-by: varun-edachali-dbx <[email protected]>
* docstrings for DatabricksClient interface
Signed-off-by: varun-edachali-dbx <[email protected]>
* stronger typing of Cursor and ExecuteResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove utility functions from backend interface, fix circular import
Signed-off-by: varun-edachali-dbx <[email protected]>
* rename info to properties
Signed-off-by: varun-edachali-dbx <[email protected]>
* newline for cleanliness
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix circular import
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* to_hex_id -> get_hex_id
Signed-off-by: varun-edachali-dbx <[email protected]>
* better comment on protocol version getter
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* move guid to hex id to new utils module
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* move staging allowed local path to connection props
Signed-off-by: varun-edachali-dbx <[email protected]>
* add strong return type for execute_command
Signed-off-by: varun-edachali-dbx <[email protected]>
* skip auth, error handling in databricksclient interface
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: docstring + line width
Signed-off-by: varun-edachali-dbx <[email protected]>
* get_id -> get_guid
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: to_hex_id -> to_hex_guid
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* Implement ResultSet Abstraction (backend interfaces for fetch phase) (#574)
* ensure backend client returns a ResultSet type in backend tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* newline for cleanliness
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix circular import
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* to_hex_id -> get_hex_id
Signed-off-by: varun-edachali-dbx <[email protected]>
* better comment on protocol version getter
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* stricter typing for cursor
Signed-off-by: varun-edachali-dbx <[email protected]>
* correct typing
Signed-off-by: varun-edachali-dbx <[email protected]>
* correct tests and merge artifacts
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove accidentally modified workflow files
remnants of old merge
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: remove accidentally modified workflow files
Signed-off-by: varun-edachali-dbx <[email protected]>
* add back accidentally removed docstrings
Signed-off-by: varun-edachali-dbx <[email protected]>
* clean up docstrings
Signed-off-by: varun-edachali-dbx <[email protected]>
* log hex
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove unnecessary _replace call
Signed-off-by: varun-edachali-dbx <[email protected]>
* add __str__ for CommandId
Signed-off-by: varun-edachali-dbx <[email protected]>
* take TOpenSessionResp in get_protocol_version to maintain existing interface
Signed-off-by: varun-edachali-dbx <[email protected]>
* active_op_handle -> active_mmand_id
Signed-off-by: varun-edachali-dbx <[email protected]>
* ensure None returned for close_command
Signed-off-by: varun-edachali-dbx <[email protected]>
* account for ResultSet return in new pydocs
Signed-off-by: varun-edachali-dbx <[email protected]>
* pydoc for types
Signed-off-by: varun-edachali-dbx <[email protected]>
* move common state to ResultSet aprent
Signed-off-by: varun-edachali-dbx <[email protected]>
* stronger typing in resultSet behaviour
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove redundant patch in test
Signed-off-by: varun-edachali-dbx <[email protected]>
* add has_been_closed_server_side assertion
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove redundancies in tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* more robust close check
Signed-off-by: varun-edachali-dbx <[email protected]>
* use normalised state in e2e test
Signed-off-by: varun-edachali-dbx <[email protected]>
* simplify corrected test
Signed-off-by: varun-edachali-dbx <[email protected]>
* add line gaps after multi-line pydocs for consistency
Signed-off-by: varun-edachali-dbx <[email protected]>
* use normalised CommandState type in ExecuteResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* Introduce Sea HTTP Client and test script (#583)
* introduce http client (temp) and sea test file
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce verbosity
Signed-off-by: varun-edachali-dbx <[email protected]>
* redundant comment
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce redundancy, params and data separate
Signed-off-by: varun-edachali-dbx <[email protected]>
* rename client
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix type issues
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce repetition in request calls
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary elifs
Signed-off-by: varun-edachali-dbx <[email protected]>
* add newline at EOF
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* Introduce `SeaDatabricksClient` (Session Implementation) (#582)
* [squashed from prev branch] introduce sea client with session open and close functionality
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove accidental changes to workflows (merge artifacts)
Signed-off-by: varun-edachali-dbx <[email protected]>
* pass test_input to get_protocol_version instead of session_id to maintain previous API
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black + line gaps after multi-line pydocs)
Signed-off-by: varun-edachali-dbx <[email protected]>
* use factory for backend instantiation
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix type issues
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove redundant comments
Signed-off-by: varun-edachali-dbx <[email protected]>
* introduce models for requests and responses
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove http client and test script
to prevent diff from showing up post http-client merge
Signed-off-by: varun-edachali-dbx <[email protected]>
* Introduce Sea HTTP Client and test script (#583)
* introduce http client (temp) and sea test file
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce verbosity
Signed-off-by: varun-edachali-dbx <[email protected]>
* redundant comment
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce redundancy, params and data separate
Signed-off-by: varun-edachali-dbx <[email protected]>
* rename client
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix type issues
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce repetition in request calls
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary elifs
Signed-off-by: varun-edachali-dbx <[email protected]>
* add newline at EOF
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* CustomHttpClient -> SeaHttpClient
Signed-off-by: varun-edachali-dbx <[email protected]>
* redundant comment in backend client
Signed-off-by: varun-edachali-dbx <[email protected]>
* regex for warehouse_id instead of .split, remove excess imports and behaviour
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove redundant attributes
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* [nit] reduce nested code
Signed-off-by: varun-edachali-dbx <[email protected]>
* line gap after multi-line pydoc
Signed-off-by: varun-edachali-dbx <[email protected]>
* redundant imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* move sea backend and models into separate sea/ dir
Signed-off-by: varun-edachali-dbx <[email protected]>
* move http client into separate sea/ dir
Signed-off-by: varun-edachali-dbx <[email protected]>
* change commands to include ones in docs
Signed-off-by: varun-edachali-dbx <[email protected]>
* add link to sql-ref-parameters for session-confs
Signed-off-by: varun-edachali-dbx <[email protected]>
* add client side filtering for session confs, add note on warehouses over endoints
Signed-off-by: varun-edachali-dbx <[email protected]>
* test unimplemented methods and max_download_threads prop
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* Normalise Execution Response (clean backend interfaces) (#587)
* [squash from exec-sea] bring over execution phase changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess test
Signed-off-by: varun-edachali-dbx <[email protected]>
* add docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* remvoe exec func in sea backend
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess files
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess models
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess sea backend tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* cleanup
Signed-off-by: varun-edachali-dbx <[email protected]>
* re-introduce get_schema_desc
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove SeaResultSet
Signed-off-by: varun-edachali-dbx <[email protected]>
* clean imports and attributes
Signed-off-by: varun-edachali-dbx <[email protected]>
* pass CommandId to ExecResp
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove changes in types
Signed-off-by: varun-edachali-dbx <[email protected]>
* add back essential types (ExecResponse, from_sea_state)
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix fetch types
Signed-off-by: varun-edachali-dbx <[email protected]>
* excess imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff by maintaining logs
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix int test types
Signed-off-by: varun-edachali-dbx <[email protected]>
* move guid_to_hex_id import to utils
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff in guid utils import
Signed-off-by: varun-edachali-dbx <[email protected]>
* move arrow_schema_bytes back into ExecuteResult
Signed-off-by: varun-edachali-dbx <[email protected]>
* maintain log
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary assignment
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary tuple response
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-ncessary verbose mocking
Signed-off-by: varun-edachali-dbx <[email protected]>
* move Queue construction to ResultSert
Signed-off-by: varun-edachali-dbx <[email protected]>
* move description to List[Tuple]
Signed-off-by: varun-edachali-dbx <[email protected]>
* frmatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff (remove explicit tuple conversion)
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove has_more_rows from ExecuteResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary has_more_rows aclc
Signed-off-by: varun-edachali-dbx <[email protected]>
* default has_more_rows to True
Signed-off-by: varun-edachali-dbx <[email protected]>
* return has_more_rows from ExecResponse conversion during GetRespMetadata
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove unnecessary replacement
Signed-off-by: varun-edachali-dbx <[email protected]>
* better mocked backend naming
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove has_more_rows test in ExecuteResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
* introduce replacement of original has_more_rows read test
Signed-off-by: varun-edachali-dbx <[email protected]>
* call correct method in test_use_arrow_schema
Signed-off-by: varun-edachali-dbx <[email protected]>
* call correct method in test_fall_back_to_hive_schema
Signed-off-by: varun-edachali-dbx <[email protected]>
* re-introduce result response read test
Signed-off-by: varun-edachali-dbx <[email protected]>
* simplify test
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess fetch_results mocks
Signed-off-by: varun-edachali-dbx <[email protected]>
* more minimal changes to thrift_backend tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* move back to old table types
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove outdated arrow_schema_bytes return
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove duplicate import
Signed-off-by: varun-edachali-dbx <[email protected]>
* rephrase model docstrings to explicitly denote that they are representations and not used over the wire
Signed-off-by: varun-edachali-dbx <[email protected]>
* has_more_rows -> is_direct_results
Signed-off-by: varun-edachali-dbx <[email protected]>
* switch docstring format to align with Connection class
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* Introduce models for `SeaDatabricksClient` (#595)
* [squash from exec-sea] bring over execution phase changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess test
Signed-off-by: varun-edachali-dbx <[email protected]>
* add docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* remvoe exec func in sea backend
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess files
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess models
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess sea backend tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* cleanup
Signed-off-by: varun-edachali-dbx <[email protected]>
* re-introduce get_schema_desc
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove SeaResultSet
Signed-off-by: varun-edachali-dbx <[email protected]>
* clean imports and attributes
Signed-off-by: varun-edachali-dbx <[email protected]>
* pass CommandId to ExecResp
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove changes in types
Signed-off-by: varun-edachali-dbx <[email protected]>
* add back essential types (ExecResponse, from_sea_state)
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix fetch types
Signed-off-by: varun-edachali-dbx <[email protected]>
* excess imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff by maintaining logs
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix int test types
Signed-off-by: varun-edachali-dbx <[email protected]>
* [squashed from exec-sea] init execution func
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove ResultSetFilter functionality
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* even more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove sea response as init option
Signed-off-by: varun-edachali-dbx <[email protected]>
* exec test example scripts
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* [squashed from sea-exec] merge sea stuffs
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess removed docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes in backend
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove accidentally removed _get_schema_desc
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove unnecessary init with sea_response tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* rmeove unnecessary changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* improved models and filters from cloudfetch-sea branch
Signed-off-by: varun-edachali-dbx <[email protected]>
* filters stuff (align with JDBC)
Signed-off-by: varun-edachali-dbx <[email protected]>
* backend from cloudfetch-sea
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove filtering, metadata ops
Signed-off-by: varun-edachali-dbx <[email protected]>
* raise NotImplementedErrror for metadata ops
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary backend cahnges
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-needed GetChunksResponse
only relevant in Fetch phase
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce code duplication
Signed-off-by: varun-edachali-dbx <[email protected]>
* more clear docstrings
Signed-off-by: varun-edachali-dbx <[email protected]>
* introduce strongly typed ChunkInfo
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove is_volume_operation from response
Signed-off-by: varun-edachali-dbx <[email protected]>
* add is_volume_op and more ResultData fields
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* Introduce preliminary SEA Result Set (#588)
* [squash from exec-sea] bring over execution phase changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess test
Signed-off-by: varun-edachali-dbx <[email protected]>
* add docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* remvoe exec func in sea backend
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess files
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess models
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess sea backend tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* cleanup
Signed-off-by: varun-edachali-dbx <[email protected]>
* re-introduce get_schema_desc
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove SeaResultSet
Signed-off-by: varun-edachali-dbx <[email protected]>
* clean imports and attributes
Signed-off-by: varun-edachali-dbx <[email protected]>
* pass CommandId to ExecResp
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove changes in types
Signed-off-by: varun-edachali-dbx <[email protected]>
* add back essential types (ExecResponse, from_sea_state)
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix fetch types
Signed-off-by: varun-edachali-dbx <[email protected]>
* excess imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff by maintaining logs
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix int test types
Signed-off-by: varun-edachali-dbx <[email protected]>
* [squashed from exec-sea] init execution func
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove ResultSetFilter functionality
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* even more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove sea response as init option
Signed-off-by: varun-edachali-dbx <[email protected]>
* move guid_to_hex_id import to utils
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff in guid utils import
Signed-off-by: varun-edachali-dbx <[email protected]>
* move arrow_schema_bytes back into ExecuteResult
Signed-off-by: varun-edachali-dbx <[email protected]>
* maintain log
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary assignment
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary tuple response
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-ncessary verbose mocking
Signed-off-by: varun-edachali-dbx <[email protected]>
* move Queue construction to ResultSert
Signed-off-by: varun-edachali-dbx <[email protected]>
* move description to List[Tuple]
Signed-off-by: varun-edachali-dbx <[email protected]>
* frmatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff (remove explicit tuple conversion)
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove has_more_rows from ExecuteResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary has_more_rows aclc
Signed-off-by: varun-edachali-dbx <[email protected]>
* default has_more_rows to True
Signed-off-by: varun-edachali-dbx <[email protected]>
* return has_more_rows from ExecResponse conversion during GetRespMetadata
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove unnecessary replacement
Signed-off-by: varun-edachali-dbx <[email protected]>
* better mocked backend naming
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove has_more_rows test in ExecuteResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
* introduce replacement of original has_more_rows read test
Signed-off-by: varun-edachali-dbx <[email protected]>
* call correct method in test_use_arrow_schema
Signed-off-by: varun-edachali-dbx <[email protected]>
* call correct method in test_fall_back_to_hive_schema
Signed-off-by: varun-edachali-dbx <[email protected]>
* re-introduce result response read test
Signed-off-by: varun-edachali-dbx <[email protected]>
* simplify test
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess fetch_results mocks
Signed-off-by: varun-edachali-dbx <[email protected]>
* more minimal changes to thrift_backend tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* move back to old table types
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove outdated arrow_schema_bytes return
Signed-off-by: varun-edachali-dbx <[email protected]>
* align SeaResultSet with new structure
Signed-off-by: varun-edachali-dbx <[email protected]>
* correct sea res set tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove duplicate import
Signed-off-by: varun-edachali-dbx <[email protected]>
* rephrase model docstrings to explicitly denote that they are representations and not used over the wire
Signed-off-by: varun-edachali-dbx <[email protected]>
* has_more_rows -> is_direct_results
Signed-off-by: varun-edachali-dbx <[email protected]>
* switch docstring format to align with Connection class
Signed-off-by: varun-edachali-dbx <[email protected]>
* has_more_rows -> is_direct_results
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix type errors with arrow_schema_bytes
Signed-off-by: varun-edachali-dbx <[email protected]>
* spaces after multi line pydocs
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove duplicate queue init (merge artifact)
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff (remove newlines)
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary changes
covered by #588 anyway
Signed-off-by: varun-edachali-dbx <[email protected]>
* Revert "remove un-necessary changes"
This reverts commit a70a6cee277db44d6951604e890f91cae9f92f32.
Signed-off-by: varun-edachali-dbx <[email protected]>
* b"" -> None
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove invalid ExecuteResponse import
Signed-off-by: varun-edachali-dbx <[email protected]>
* Separate Session related functionality from Connection class (#571)
* decouple session class from existing Connection
ensure maintenance of current APIs of Connection while delegating
responsibility
Signed-off-by: varun-edachali-dbx <[email protected]>
* add open property to Connection to ensure maintenance of existing API
Signed-off-by: varun-edachali-dbx <[email protected]>
* update unit tests to address ThriftBackend through session instead of through Connection
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: move session specific tests from test_client to test_session
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
as in CONTRIBUTING.md
Signed-off-by: varun-edachali-dbx <[email protected]>
* use connection open property instead of long chain through session
Signed-off-by: varun-edachali-dbx <[email protected]>
* trigger integration workflow
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: ensure open attribute of Connection never fails
in case the openSession takes long, the initialisation of the session
will not complete immediately. This could make the session attribute
inaccessible. If the Connection is deleted in this time, the open()
check will throw because the session attribute does not exist. Thus, we
default to the Connection being closed in this case. This was not an
issue before because open was a direct attribute of the Connection
class. Caught in the integration tests.
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: de-complicate earlier connection open logic
earlier, one of the integration tests was failing because 'session was
not an attribute of Connection'. This is likely tied to a local
configuration issue related to unittest that was causing an error in the
test suite itself. The tests are now passing without checking for the
session attribute.
https://github.com/databricks/databricks-sql-python/pull/567/commits/c676f9b0281cc3e4fe9c6d8216cc62fc75eade3b
Signed-off-by: varun-edachali-dbx <[email protected]>
* Revert "fix: de-complicate earlier connection open logic"
This reverts commit d6b1b196c98a6e9d8e593a88c34bbde010519ef4.
Signed-off-by: varun-edachali-dbx <[email protected]>
* [empty commit] attempt to trigger ci e2e workflow
Signed-off-by: varun-edachali-dbx <[email protected]>
* Update CODEOWNERS (#562)
new codeowners
Signed-off-by: varun-edachali-dbx <[email protected]>
* Enhance Cursor close handling and context manager exception management to prevent server side resource leaks (#554)
* Enhance Cursor close handling and context manager exception management
* tests
* fmt
* Fix Cursor.close() to properly handle CursorAlreadyClosedError
* Remove specific test message from Cursor.close() error handling
* Improve error handling in connection and cursor context managers to ensure proper closure during exceptions, including KeyboardInterrupt. Add tests for nested cursor management and verify operation closure on server-side errors.
* add
* add
Signed-off-by: varun-edachali-dbx <[email protected]>
* PECOBLR-86 improve logging on python driver (#556)
* PECOBLR-86 Improve logging for debug level
Signed-off-by: Sai Shree Pradhan <[email protected]>
* PECOBLR-86 Improve logging for debug level
Signed-off-by: Sai Shree Pradhan <[email protected]>
* fixed format
Signed-off-by: Sai Shree Pradhan <[email protected]>
* used lazy logging
Signed-off-by: Sai Shree Pradhan <[email protected]>
* changed debug to error logs
Signed-off-by: Sai Shree Pradhan <[email protected]>
* used lazy logging
Signed-off-by: Sai Shree Pradhan <[email protected]>
---------
Signed-off-by: Sai Shree Pradhan <[email protected]>
Signed-off-by: varun-edachali-dbx <[email protected]>
* Revert "Merge remote-tracking branch 'upstream/sea-migration' into decouple-session"
This reverts commit dbb2ec52306b91072a2ee842270c7113aece9aff, reversing
changes made to 7192f117279d4f0adcbafcdf2238c18663324515.
Signed-off-by: varun-edachali-dbx <[email protected]>
* Reapply "Merge remote-tracking branch 'upstream/sea-migration' into decouple-session"
This reverts commit bdb83817f49e1d88a01679b11da8e55e8e80b42f.
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: separate session opening logic from instantiation
ensures correctness of self.session.open call in Connection
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: use is_open attribute to denote session availability
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: access thrift backend through session
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: use get_handle() instead of private session attribute in client
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: remove accidentally removed assertions
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
Signed-off-by: Sai Shree Pradhan <[email protected]>
Co-authored-by: Jothi Prakash <[email protected]>
Co-authored-by: Madhav Sainanee <[email protected]>
Co-authored-by: Sai Shree Pradhan <[email protected]>
* Introduce Backend Interface (DatabricksClient) (#573)
NOTE: the `test_complex_types` e2e test was not working at the time of this merge. The test must be triggered when the test is back up and running as intended.
* remove excess logs, assertions, instantiations
large merge artifacts
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black) + remove excess log (merge artifact)
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix typing
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary check
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary replace call
Signed-off-by: varun-edachali-dbx <[email protected]>
* introduce __str__ methods for CommandId and SessionId
Signed-off-by: varun-edachali-dbx <[email protected]>
* docstrings for DatabricksClient interface
Signed-off-by: varun-edachali-dbx <[email protected]>
* stronger typing of Cursor and ExecuteResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove utility functions from backend interface, fix circular import
Signed-off-by: varun-edachali-dbx <[email protected]>
* rename info to properties
Signed-off-by: varun-edachali-dbx <[email protected]>
* newline for cleanliness
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix circular import
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* to_hex_id -> get_hex_id
Signed-off-by: varun-edachali-dbx <[email protected]>
* better comment on protocol version getter
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* move guid to hex id to new utils module
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* move staging allowed local path to connection props
Signed-off-by: varun-edachali-dbx <[email protected]>
* add strong return type for execute_command
Signed-off-by: varun-edachali-dbx <[email protected]>
* skip auth, error handling in databricksclient interface
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: docstring + line width
Signed-off-by: varun-edachali-dbx <[email protected]>
* get_id -> get_guid
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: to_hex_id -> to_hex_guid
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* Implement ResultSet Abstraction (backend interfaces for fetch phase) (#574)
* ensure backend client returns a ResultSet type in backend tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* newline for cleanliness
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix circular import
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* to_hex_id -> get_hex_id
Signed-off-by: varun-edachali-dbx <[email protected]>
* better comment on protocol version getter
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* stricter typing for cursor
Signed-off-by: varun-edachali-dbx <[email protected]>
* correct typing
Signed-off-by: varun-edachali-dbx <[email protected]>
* correct tests and merge artifacts
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove accidentally modified workflow files
remnants of old merge
Signed-off-by: varun-edachali-dbx <[email protected]>
* chore: remove accidentally modified workflow files
Signed-off-by: varun-edachali-dbx <[email protected]>
* add back accidentally removed docstrings
Signed-off-by: varun-edachali-dbx <[email protected]>
* clean up docstrings
Signed-off-by: varun-edachali-dbx <[email protected]>
* log hex
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove unnecessary _replace call
Signed-off-by: varun-edachali-dbx <[email protected]>
* add __str__ for CommandId
Signed-off-by: varun-edachali-dbx <[email protected]>
* take TOpenSessionResp in get_protocol_version to maintain existing interface
Signed-off-by: varun-edachali-dbx <[email protected]>
* active_op_handle -> active_mmand_id
Signed-off-by: varun-edachali-dbx <[email protected]>
* ensure None returned for close_command
Signed-off-by: varun-edachali-dbx <[email protected]>
* account for ResultSet return in new pydocs
Signed-off-by: varun-edachali-dbx <[email protected]>
* pydoc for types
Signed-off-by: varun-edachali-dbx <[email protected]>
* move common state to ResultSet aprent
Signed-off-by: varun-edachali-dbx <[email protected]>
* stronger typing in resultSet behaviour
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove redundant patch in test
Signed-off-by: varun-edachali-dbx <[email protected]>
* add has_been_closed_server_side assertion
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove redundancies in tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* more robust close check
Signed-off-by: varun-edachali-dbx <[email protected]>
* use normalised state in e2e test
Signed-off-by: varun-edachali-dbx <[email protected]>
* simplify corrected test
Signed-off-by: varun-edachali-dbx <[email protected]>
* add line gaps after multi-line pydocs for consistency
Signed-off-by: varun-edachali-dbx <[email protected]>
* use normalised CommandState type in ExecuteResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary initialisation assertions
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary line break s
Signed-off-by: varun-edachali-dbx <[email protected]>
* more un-necessary line breaks
Signed-off-by: varun-edachali-dbx <[email protected]>
* constrain diff of test_closing_connection_closes_commands
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff of test_closing_connection_closes_commands
Signed-off-by: varun-edachali-dbx <[email protected]>
* use pytest-like assertions for test_closing_connection_closes_commands
Signed-off-by: varun-edachali-dbx <[email protected]>
* ensure command_id is not None
Signed-off-by: varun-edachali-dbx <[email protected]>
* line breaks after multi-line pyfocs
Signed-off-by: varun-edachali-dbx <[email protected]>
* ensure non null operationHandle for commandId creation
Signed-off-by: varun-edachali-dbx <[email protected]>
* use command_id methods instead of explicit guid_to_hex_id conversion
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary artifacts in test_session, add back assertion
Signed-off-by: varun-edachali-dbx <[email protected]>
* Implement SeaDatabricksClient (Complete Execution Spec) (#590)
* [squash from exec-sea] bring over execution phase changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess test
Signed-off-by: varun-edachali-dbx <[email protected]>
* add docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* remvoe exec func in sea backend
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess files
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess models
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess sea backend tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* cleanup
Signed-off-by: varun-edachali-dbx <[email protected]>
* re-introduce get_schema_desc
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove SeaResultSet
Signed-off-by: varun-edachali-dbx <[email protected]>
* clean imports and attributes
Signed-off-by: varun-edachali-dbx <[email protected]>
* pass CommandId to ExecResp
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove changes in types
Signed-off-by: varun-edachali-dbx <[email protected]>
* add back essential types (ExecResponse, from_sea_state)
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix fetch types
Signed-off-by: varun-edachali-dbx <[email protected]>
* excess imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff by maintaining logs
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix int test types
Signed-off-by: varun-edachali-dbx <[email protected]>
* [squashed from exec-sea] init execution func
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove ResultSetFilter functionality
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* even more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove sea response as init option
Signed-off-by: varun-edachali-dbx <[email protected]>
* exec test example scripts
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* [squashed from sea-exec] merge sea stuffs
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess removed docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes in backend
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove accidentally removed _get_schema_desc
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove unnecessary init with sea_response tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* rmeove unnecessary changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* improved models and filters from cloudfetch-sea branch
Signed-off-by: varun-edachali-dbx <[email protected]>
* filters stuff (align with JDBC)
Signed-off-by: varun-edachali-dbx <[email protected]>
* backend from cloudfetch-sea
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove filtering, metadata ops
Signed-off-by: varun-edachali-dbx <[email protected]>
* raise NotImplementedErrror for metadata ops
Signed-off-by: varun-edachali-dbx <[email protected]>
* change to valid table name
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary changes
covered by #588
Signed-off-by: varun-edachali-dbx <[email protected]>
* simplify test module
Signed-off-by: varun-edachali-dbx <[email protected]>
* logging -> debug level
Signed-off-by: varun-edachali-dbx <[email protected]>
* change table name in log
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary backend cahnges
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-needed GetChunksResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-needed GetChunksResponse
only relevant in Fetch phase
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce code duplication in response parsing
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce code duplication
Signed-off-by: varun-edachali-dbx <[email protected]>
* more clear docstrings
Signed-off-by: varun-edachali-dbx <[email protected]>
* introduce strongly typed ChunkInfo
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove is_volume_operation from response
Signed-off-by: varun-edachali-dbx <[email protected]>
* add is_volume_op and more ResultData fields
Signed-off-by: varun-edachali-dbx <[email protected]>
* add test scripts
Signed-off-by: varun-edachali-dbx <[email protected]>
* Revert "Merge branch 'exec-models-sea' into exec-phase-sea"
This reverts commit be1997e0d6b6cf0f5499db2381971ec3a015a2f7, reversing
changes made to 37813ba6d1fe06d7f9f10d510a059b88dc552496.
* change logging level
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove _get_schema_bytes (for now)
Signed-off-by: varun-edachali-dbx <[email protected]>
* redundant comments
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove fetch phase methods
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce code repetititon + introduce gaps after multi line pydocs
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove unused imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* move description extraction to helper func
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* add more unit tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* streamline unit tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* test getting the list of allowed configurations
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff
Signed-off-by: varun-edachali-dbx <[email protected]>
* house constants in enums for readability and immutability
Signed-off-by: varun-edachali-dbx <[email protected]>
* add note on hybrid disposition
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove redundant note on arrow_schema_bytes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove invalid import
Signed-off-by: varun-edachali-dbx <[email protected]>
* add strong typing for manifest in _extract_description
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary column skipping
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove parsing in backend
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix: convert sea statement id to CommandId type
Signed-off-by: varun-edachali-dbx <[email protected]>
* make polling interval a separate constant
Signed-off-by: varun-edachali-dbx <[email protected]>
* align state checking with Thrift implementation
Signed-off-by: varun-edachali-dbx <[email protected]>
* update unit tests according to changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* add unit tests for added methods
Signed-off-by: varun-edachali-dbx <[email protected]>
* add spec to description extraction docstring, add strong typing to params
Signed-off-by: varun-edachali-dbx <[email protected]>
* add strong typing for backend parameters arg
Signed-off-by: varun-edachali-dbx <[email protected]>
---------
Signed-off-by: varun-edachali-dbx <[email protected]>
* add from __future__ import annotations to remove string literals around forward refs, remove some unused imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* move docstring of DatabricksClient within class
Signed-off-by: varun-edachali-dbx <[email protected]>
* move ThriftResultSet import to top of file
Signed-off-by: varun-edachali-dbx <[email protected]>
* make backend/utils __init__ file empty
Signed-off-by: varun-edachali-dbx <[email protected]>
* use from __future__ import annotations to remove string literals around Cursor
Signed-off-by: varun-edachali-dbx <[email protected]>
* use lazy logging
Signed-off-by: varun-edachali-dbx <[email protected]>
* replace getters with property tag
Signed-off-by: varun-edachali-dbx <[email protected]>
* set active_command_id to None, not active_op_handle
Signed-off-by: varun-edachali-dbx <[email protected]>
* align test_session with pytest instead of unittest
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove duplicate test, correct active_command_id attribute
Signed-off-by: varun-edachali-dbx <[email protected]>
* SeaDatabricksClient: Add Metadata Commands (#593)
* [squash from exec-sea] bring over execution phase changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess test
Signed-off-by: varun-edachali-dbx <[email protected]>
* add docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* remvoe exec func in sea backend
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess files
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess models
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess sea backend tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* cleanup
Signed-off-by: varun-edachali-dbx <[email protected]>
* re-introduce get_schema_desc
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove SeaResultSet
Signed-off-by: varun-edachali-dbx <[email protected]>
* clean imports and attributes
Signed-off-by: varun-edachali-dbx <[email protected]>
* pass CommandId to ExecResp
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove changes in types
Signed-off-by: varun-edachali-dbx <[email protected]>
* add back essential types (ExecResponse, from_sea_state)
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix fetch types
Signed-off-by: varun-edachali-dbx <[email protected]>
* excess imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce diff by maintaining logs
Signed-off-by: varun-edachali-dbx <[email protected]>
* fix int test types
Signed-off-by: varun-edachali-dbx <[email protected]>
* [squashed from exec-sea] init execution func
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove ResultSetFilter functionality
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* even more irrelevant changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove sea response as init option
Signed-off-by: varun-edachali-dbx <[email protected]>
* exec test example scripts
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* [squashed from sea-exec] merge sea stuffs
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess removed docstring
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes in backend
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess imports
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove accidentally removed _get_schema_desc
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove unnecessary init with sea_response tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* rmeove unnecessary changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* improved models and filters from cloudfetch-sea branch
Signed-off-by: varun-edachali-dbx <[email protected]>
* filters stuff (align with JDBC)
Signed-off-by: varun-edachali-dbx <[email protected]>
* backend from cloudfetch-sea
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove filtering, metadata ops
Signed-off-by: varun-edachali-dbx <[email protected]>
* raise NotImplementedErrror for metadata ops
Signed-off-by: varun-edachali-dbx <[email protected]>
* add metadata commands
Signed-off-by: varun-edachali-dbx <[email protected]>
* formatting (black)
Signed-off-by: varun-edachali-dbx <[email protected]>
* add metadata command unit tests
Signed-off-by: varun-edachali-dbx <[email protected]>
* change to valid table name
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary changes
covered by #588
Signed-off-by: varun-edachali-dbx <[email protected]>
* simplify test module
Signed-off-by: varun-edachali-dbx <[email protected]>
* logging -> debug level
Signed-off-by: varun-edachali-dbx <[email protected]>
* change table name in log
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary backend cahnges
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-needed GetChunksResponse
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-needed GetChunksResponse
only relevant in Fetch phase
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce code duplication in response parsing
Signed-off-by: varun-edachali-dbx <[email protected]>
* reduce code duplication
Signed-off-by: varun-edachali-dbx <[email protected]>
* more clear docstrings
Signed-off-by: varun-edachali-dbx <[email protected]>
* introduce strongly typed ChunkInfo
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove is_volume_operation from response
Signed-off-by: varun-edachali-dbx <[email protected]>
* add is_volume_op and more ResultData fields
Signed-off-by: varun-edachali-dbx <[email protected]>
* add test scripts
Signed-off-by: varun-edachali-dbx <[email protected]>
* Revert "Merge branch 'sea-migration' into exec-models-sea"
This reverts commit 8bd12d829ea13abf8fc1507fff8cb21751001c67, reversing
changes made to 030edf8df3db487b7af8d910ee51240d1339229e.
* Revert "Merge branch 'exec-models-sea' into exec-phase-sea"
This reverts commit be1997e0d6b6cf0f5499db2381971ec3a015a2f7, reversing
changes made to 37813ba6d1fe06d7f9f10d510a059b88dc552496.
* change logging level
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove un-necessary changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove excess changes
Signed-off-by: varun-edachali-dbx <[email protected]>
* remove _get_schema_bytes (for now)
Signed-off-by: varun-edachali-dbx <[email protected]>
* redundant comments
S…1 parent 71d306f commit 0a7a6ab
File tree
35 files changed
+3102
-525
lines changed- examples/experimental/tests
- src/databricks/sql
- backend
- sea
- models
- utils
- cloudfetch
- telemetry
- models
- tests
- e2e
- common
- unit
35 files changed
+3102
-525
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
| 56 | + | |
56 | 57 | | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
57 | 65 | | |
58 | | - | |
| 66 | + | |
59 | 67 | | |
60 | | - | |
| 68 | + | |
61 | 69 | | |
62 | 70 | | |
63 | 71 | | |
| |||
70 | 78 | | |
71 | 79 | | |
72 | 80 | | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
73 | 98 | | |
74 | | - | |
| 99 | + | |
75 | 100 | | |
76 | 101 | | |
77 | 102 | | |
| |||
131 | 156 | | |
132 | 157 | | |
133 | 158 | | |
134 | | - | |
| 159 | + | |
| 160 | + | |
135 | 161 | | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
136 | 169 | | |
137 | | - | |
| 170 | + | |
138 | 171 | | |
139 | | - | |
| 172 | + | |
140 | 173 | | |
141 | 174 | | |
142 | 175 | | |
| |||
149 | 182 | | |
150 | 183 | | |
151 | 184 | | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
152 | 201 | | |
153 | | - | |
| 202 | + | |
154 | 203 | | |
155 | 204 | | |
156 | 205 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | | - | |
| 53 | + | |
| 54 | + | |
54 | 55 | | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
55 | 71 | | |
56 | | - | |
| 72 | + | |
57 | 73 | | |
58 | | - | |
59 | | - | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
60 | 81 | | |
61 | 82 | | |
62 | 83 | | |
| |||
115 | 136 | | |
116 | 137 | | |
117 | 138 | | |
118 | | - | |
| 139 | + | |
| 140 | + | |
119 | 141 | | |
120 | 142 | | |
121 | | - | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
122 | 147 | | |
123 | | - | |
124 | | - | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
125 | 163 | | |
126 | 164 | | |
127 | 165 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
9 | 14 | | |
10 | 15 | | |
11 | 16 | | |
| |||
19 | 24 | | |
20 | 25 | | |
21 | 26 | | |
22 | | - | |
| 27 | + | |
23 | 28 | | |
24 | 29 | | |
25 | 30 | | |
| |||
110 | 115 | | |
111 | 116 | | |
112 | 117 | | |
| 118 | + | |
113 | 119 | | |
114 | 120 | | |
115 | 121 | | |
| |||
296 | 302 | | |
297 | 303 | | |
298 | 304 | | |
299 | | - | |
| 305 | + | |
300 | 306 | | |
301 | 307 | | |
302 | 308 | | |
| |||
311 | 317 | | |
312 | 318 | | |
313 | 319 | | |
314 | | - | |
315 | | - | |
316 | | - | |
317 | 320 | | |
318 | 321 | | |
319 | 322 | | |
| |||
337 | 340 | | |
338 | 341 | | |
339 | 342 | | |
340 | | - | |
| 343 | + | |
341 | 344 | | |
342 | 345 | | |
343 | 346 | | |
| |||
358 | 361 | | |
359 | 362 | | |
360 | 363 | | |
361 | | - | |
| 364 | + | |
362 | 365 | | |
363 | 366 | | |
364 | 367 | | |
| |||
647 | 650 | | |
648 | 651 | | |
649 | 652 | | |
| 653 | + | |
| 654 | + | |
| 655 | + | |
| 656 | + | |
| 657 | + | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
| 670 | + | |
| 671 | + | |
| 672 | + | |
| 673 | + | |
650 | 674 | | |
651 | 675 | | |
652 | 676 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
29 | 30 | | |
30 | 31 | | |
31 | 32 | | |
| |||
47 | 48 | | |
48 | 49 | | |
49 | 50 | | |
| 51 | + | |
50 | 52 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
160 | 160 | | |
161 | 161 | | |
162 | 162 | | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
0 commit comments