Skip to content

Commit

Permalink
[druid] Fixing issue 3894 multi-processing w/ Gunicorn (apache#3895)
Browse files Browse the repository at this point in the history
  • Loading branch information
john-bodley authored and michellethomas committed May 23, 2018
1 parent 5afe328 commit e581fa1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions superset/connectors/druid/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from datetime import datetime, timedelta
import json
import logging
from multiprocessing import Pool
from multiprocessing.pool import ThreadPool

from dateutil.parser import parse as dparse
from flask import escape, Markup
Expand Down Expand Up @@ -157,7 +157,7 @@ def refresh(self, datasource_names, merge_flag, refreshAll):
session.flush()

# Prepare multithreaded executation
pool = Pool()
pool = ThreadPool()
ds_refresh = list(ds_map.values())
metadata = pool.map(_fetch_metadata_for, ds_refresh)
pool.close()
Expand Down

0 comments on commit e581fa1

Please sign in to comment.