mirror of
https://github.com/apache/superset.git
synced 2026-05-12 19:35:17 +00:00
fix(thumbnails): ensure consistent cache_key (#33109)
(cherry picked from commit 347c174099)
This commit is contained in:
committed by
Michael S. Molina
parent
65c9375624
commit
bf2e014cde
@@ -1303,6 +1303,7 @@ class DashboardRestApi(BaseSupersetModelRestApi):
|
|||||||
current_user=current_user,
|
current_user=current_user,
|
||||||
dashboard_id=dashboard.id,
|
dashboard_id=dashboard.id,
|
||||||
force=False,
|
force=False,
|
||||||
|
cache_key=cache_key,
|
||||||
)
|
)
|
||||||
return self.response(
|
return self.response(
|
||||||
202,
|
202,
|
||||||
|
|||||||
@@ -78,6 +78,7 @@ def cache_dashboard_thumbnail(
|
|||||||
force: bool,
|
force: bool,
|
||||||
thumb_size: Optional[WindowSize] = None,
|
thumb_size: Optional[WindowSize] = None,
|
||||||
window_size: Optional[WindowSize] = None,
|
window_size: Optional[WindowSize] = None,
|
||||||
|
cache_key: str | None = None,
|
||||||
) -> None:
|
) -> None:
|
||||||
# pylint: disable=import-outside-toplevel
|
# pylint: disable=import-outside-toplevel
|
||||||
from superset.models.dashboard import Dashboard
|
from superset.models.dashboard import Dashboard
|
||||||
@@ -103,6 +104,7 @@ def cache_dashboard_thumbnail(
|
|||||||
window_size=window_size,
|
window_size=window_size,
|
||||||
thumb_size=thumb_size,
|
thumb_size=thumb_size,
|
||||||
force=force,
|
force=force,
|
||||||
|
cache_key=cache_key,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user