mirror of https://github.com/apache/superset.git
feat: improve presto query perf (#11069)
This commit is contained in:
parent
046bd02d65
commit
0f7e90f1f7
|
@ -730,10 +730,10 @@ class PrestoEngineSpec(BaseEngineSpec):
|
||||||
)
|
)
|
||||||
|
|
||||||
if not latest_parts:
|
if not latest_parts:
|
||||||
latest_parts = tuple([None] * len(col_names)) # type: ignore
|
latest_parts = tuple([None] * len(col_names))
|
||||||
metadata["partitions"] = {
|
metadata["partitions"] = {
|
||||||
"cols": cols,
|
"cols": cols,
|
||||||
"latest": dict(zip(col_names, latest_parts)), # type: ignore
|
"latest": dict(zip(col_names, latest_parts)),
|
||||||
"partitionQuery": pql,
|
"partitionQuery": pql,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -925,6 +925,7 @@ class PrestoEngineSpec(BaseEngineSpec):
|
||||||
return None
|
return None
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
|
@cache.memoize(timeout=60)
|
||||||
def latest_partition(
|
def latest_partition(
|
||||||
cls,
|
cls,
|
||||||
table_name: str,
|
table_name: str,
|
||||||
|
|
Loading…
Reference in New Issue