Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
3940b1ba
Commit
3940b1ba
authored
Feb 08, 2016
by
Calen Pennington
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add configuration for retries to ProgramsApiConfig
parent
c1d46ed5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
0 deletions
+28
-0
openedx/core/djangoapps/programs/migrations/0005_programsapiconfig_max_retries.py
+19
-0
openedx/core/djangoapps/programs/models.py
+9
-0
No files found.
openedx/core/djangoapps/programs/migrations/0005_programsapiconfig_max_retries.py
0 → 100644
View file @
3940b1ba
# -*- coding: utf-8 -*-
from
__future__
import
unicode_literals
from
django.db
import
migrations
,
models
class
Migration
(
migrations
.
Migration
):
dependencies
=
[
(
'programs'
,
'0004_programsapiconfig_enable_certification'
),
]
operations
=
[
migrations
.
AddField
(
model_name
=
'programsapiconfig'
,
name
=
'max_retries'
,
field
=
models
.
PositiveIntegerField
(
default
=
11
,
help_text
=
'When making requests to award certificates, make at most this many attempts to retry a failing request.'
,
verbose_name
=
'Maximum Certification Retries'
),
),
]
openedx/core/djangoapps/programs/models.py
View file @
3940b1ba
...
...
@@ -65,6 +65,15 @@ class ProgramsApiConfig(ConfigurationModel):
default
=
False
)
max_retries
=
models
.
PositiveIntegerField
(
verbose_name
=
_
(
"Maximum Certification Retries"
),
default
=
11
,
# This gives about 30 minutes wait before the final attempt
help_text
=
_
(
"When making requests to award certificates, make at most this many attempts "
"to retry a failing request."
)
)
@property
def
internal_api_url
(
self
):
"""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment