sadpandajoe commented on code in PR #43429:
URL: https://github.com/apache/superset/pull/43429#discussion_r3837087340
##########
superset-frontend/src/components/Chart/chartAction.ts:
##########
@@ -441,11 +456,24 @@ const v1ChartDataRequest = async (
allowDomainSharding,
}).toString();
+ // Opt full JSON chart-data renders into async execution per the resolved
policy
+ // (feature flag + deployment default + optional per-dashboard override).
Only
+ // callers that handle a 202 task response set enableAsyncMode; the server
treats
+ // an absent async_mode as synchronous, so this is additive.
+ const asyncMode =
+ requestParams.enableAsyncMode === true &&
+ resultFormat === 'json' &&
+ resultType === 'full' &&
+ resolveAsyncMode(requestParams.async_mode_override);
+ const body = JSON.stringify(
+ asyncMode ? { ...payload, async_mode: true } : payload,
Review Comment:
This makes async opt-in only for the `v1ChartDataRequest` producer.
`StatefulChart` still posts full JSON chart-data requests directly, even though
it already handles 202 responses, so its Matrixify cells now always run
synchronously when this endpoint requires `async_mode`. Could the resolved
policy be shared with that producer as well?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]