chore: update Druid (#22067)
This commit is contained in:
parent
cdec09243b
commit
4496748cd9
|
|
@ -78,7 +78,7 @@ pure-eval==0.2.2
|
|||
# via stack-data
|
||||
pure-sasl==0.6.2
|
||||
# via thrift-sasl
|
||||
pydruid==0.6.2
|
||||
pydruid==0.6.5
|
||||
# via apache-superset
|
||||
pygments==2.12.0
|
||||
# via ipython
|
||||
|
|
|
|||
2
setup.py
2
setup.py
|
|
@ -141,7 +141,7 @@ setup(
|
|||
"db2": ["ibm-db-sa>=0.3.5, <0.4"],
|
||||
"dremio": ["sqlalchemy-dremio>=1.1.5, <1.3"],
|
||||
"drill": ["sqlalchemy-drill==0.1.dev"],
|
||||
"druid": ["pydruid>=0.6.1,<0.7"],
|
||||
"druid": ["pydruid>=0.6.5,<0.7"],
|
||||
"solr": ["sqlalchemy-solr >= 0.2.0"],
|
||||
"elasticsearch": ["elasticsearch-dbapi>=0.2.9, <0.3.0"],
|
||||
"exasol": ["sqlalchemy-exasol >= 2.4.0, <3.0"],
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@ import logging
|
|||
from datetime import datetime
|
||||
from typing import Any, Dict, List, Optional, Type, TYPE_CHECKING
|
||||
|
||||
from sqlalchemy import types
|
||||
from sqlalchemy.engine.reflection import Inspector
|
||||
|
||||
from superset import is_feature_enabled
|
||||
|
|
@ -131,16 +130,11 @@ class DruidEngineSpec(BaseEngineSpec):
|
|||
"""
|
||||
Update the Druid type map.
|
||||
"""
|
||||
# pylint: disable=import-outside-toplevel
|
||||
from pydruid.db.sqlalchemy import type_map
|
||||
|
||||
type_map["complex<hllsketch>"] = types.BLOB
|
||||
|
||||
return super().get_columns(inspector, table_name, schema)
|
||||
|
||||
@classmethod
|
||||
def get_dbapi_exception_mapping(cls) -> Dict[Type[Exception], Type[Exception]]:
|
||||
# pylint: disable=import-error,import-outside-toplevel
|
||||
# pylint: disable=import-outside-toplevel
|
||||
from requests import exceptions as requests_exceptions
|
||||
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -224,7 +224,7 @@ class TrinoEngineSpec(PrestoBaseEngineSpec):
|
|||
|
||||
@classmethod
|
||||
def get_dbapi_exception_mapping(cls) -> Dict[Type[Exception], Type[Exception]]:
|
||||
# pylint: disable=import-error,import-outside-toplevel
|
||||
# pylint: disable=import-outside-toplevel
|
||||
from requests import exceptions as requests_exceptions
|
||||
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -563,7 +563,7 @@ class Database(
|
|||
database=self, inspector=self.inspector, schema=schema
|
||||
)
|
||||
return [(table, schema) for table in tables]
|
||||
except Exception as ex: # pylint: disable=broad-except
|
||||
except Exception as ex:
|
||||
raise self.db_engine_spec.get_dbapi_mapped_exception(ex)
|
||||
|
||||
@cache_util.memoized_func(
|
||||
|
|
@ -593,7 +593,7 @@ class Database(
|
|||
database=self, inspector=self.inspector, schema=schema
|
||||
)
|
||||
return [(view, schema) for view in views]
|
||||
except Exception as ex: # pylint: disable=broad-except
|
||||
except Exception as ex:
|
||||
raise self.db_engine_spec.get_dbapi_mapped_exception(ex)
|
||||
|
||||
@cache_util.memoized_func(
|
||||
|
|
|
|||
|
|
@ -327,7 +327,7 @@ class Superset(BaseSupersetView): # pylint: disable=too-many-public-methods
|
|||
@has_access
|
||||
@event_logger.log_this
|
||||
@expose("/approve", methods=["POST"])
|
||||
def approve(self) -> FlaskResponse: # pylint: disable=too-many-locals,no-self-use
|
||||
def approve(self) -> FlaskResponse: # pylint: disable=too-many-locals
|
||||
def clean_fulfilled_requests(session: Session) -> None:
|
||||
for dar in session.query(DAR).all():
|
||||
datasource = DatasourceDAO.get_datasource(
|
||||
|
|
|
|||
Loading…
Reference in New Issue