Vitor-Avila commented on code in PR #35832:
URL: https://github.com/apache/superset/pull/35832#discussion_r2544273762


##########
superset/tasks/slack.py:
##########
@@ -15,29 +15,128 @@
 # specific language governing permissions and limitations
 # under the License.
 import logging
+from typing import Optional
 
 from flask import current_app
 
-from superset.extensions import celery_app
-from superset.utils.slack import get_channels
+from superset.extensions import cache_manager, celery_app
+from superset.utils.slack import (
+    get_channels_with_search,
+    SLACK_CHANNELS_CACHE_KEY,
+    SLACK_CHANNELS_CONTINUATION_CURSOR_KEY,
+    SlackChannelTypes,
+)
 
 logger = logging.getLogger(__name__)
 
 
-@celery_app.task(name="slack.cache_channels")
+@celery_app.task(
+    name="slack.cache_channels",
+    time_limit=300,  # 5 minute hard timeout (via SLACK_CACHE_WARMUP_TIMEOUT)

Review Comment:
   got it, thanks!



-- 
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]

Reply via email to