Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
edx-platform-release
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Hsin-Yu Chien
edx-platform-release
Commits
8eb73a6e
Commit
8eb73a6e
authored
7 years ago
by
Waheed Ahmed
Browse files
Options
Downloads
Patches
Plain Diff
Route sailthru tasks to lms ace queue instead of default.
LEARNER-4801
parent
5ac5d9d5
Loading
Loading
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lms/djangoapps/email_marketing/tasks.py
+5
-4
5 additions, 4 deletions
lms/djangoapps/email_marketing/tasks.py
with
5 additions
and
4 deletions
lms/djangoapps/email_marketing/tasks.py
+
5
−
4
View file @
8eb73a6e
...
...
@@ -15,9 +15,10 @@ from email_marketing.models import EmailMarketingConfiguration
log
=
logging
.
getLogger
(
__name__
)
SAILTHRU_LIST_CACHE_KEY
=
"
email.marketing.cache
"
ACE_ROUTING_KEY
=
getattr
(
settings
,
'
ACE_ROUTING_KEY
'
,
None
)
@task
(
bind
=
True
)
@task
(
bind
=
True
,
routing_key
=
ACE_ROUTING_KEY
)
def
get_email_cookies_via_sailthru
(
self
,
user_email
,
post_parms
):
"""
Adds/updates Sailthru cookie information for a new user.
...
...
@@ -58,7 +59,7 @@ def get_email_cookies_via_sailthru(self, user_email, post_parms):
# pylint: disable=not-callable
@task
(
bind
=
True
,
default_retry_delay
=
3600
,
max_retries
=
24
)
@task
(
bind
=
True
,
default_retry_delay
=
3600
,
max_retries
=
24
,
routing_key
=
ACE_ROUTING_KEY
)
def
update_user
(
self
,
sailthru_vars
,
email
,
site
=
None
,
new_user
=
False
,
send_welcome_email
=
False
):
"""
Adds/updates Sailthru profile information for a user.
...
...
@@ -134,7 +135,7 @@ def is_default_site(site):
# pylint: disable=not-callable
@task
(
bind
=
True
,
default_retry_delay
=
3600
,
max_retries
=
24
)
@task
(
bind
=
True
,
default_retry_delay
=
3600
,
max_retries
=
24
,
routing_key
=
ACE_ROUTING_KEY
)
def
update_user_email
(
self
,
new_email
,
old_email
):
"""
Adds/updates Sailthru when a user email address is changed
...
...
@@ -294,7 +295,7 @@ def _retryable_sailthru_error(error):
return
code
==
9
or
code
==
43
@task
(
bind
=
True
)
@task
(
bind
=
True
,
routing_key
=
ACE_ROUTING_KEY
)
def
update_course_enrollment
(
self
,
email
,
course_key
,
mode
):
"""
Adds/updates Sailthru when a user adds to cart/purchases/upgrades a course
Args:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment