Commit Graph

29 Commits

Author SHA1 Message Date
Régis Behmo
4daf452620 fix!: infinite growth of cache when auto eviction is disabled
See discussion here: https://github.com/overhangio/tutor/pull/984

This is a breaking change that will explicitely set the timeout of
course structure cache entries to 1 week, instead of being unlimited. If
you wish to revert to the former behaviour, you should set
`course_structure_cache["TIMEOUT"] = None`.

The course structure cache keys were previously set with an explicit
timeout of `None` which was overriding the cache default timeout of 2h.
This was OK in environments where the cache is configured with a maximum
memory limit and an automatic key eviction strategy. But in others (such
as Tutor), the course structure cache could grow infinitely.

It was agreed that course structure cache keys should be long-lived but
should respect the default cache structure timeout. Thus, we set here
the TTL to 1 week.

We can also configure Tutor to use a cache eviction policy. But that
means we need to set a `maxmemory` value in Redis. It's not possible to
set a value that will be appropriate for everyone:
- if it's higher than the total memory (e.g: in small instances), server
  will crash before the cache is filled.
- if it's too low (e.g: in large instances), the whole platform will abruptly
  slow down as many cache entries are suddenly evicted.

That question of whether Tutor should define a cache eviction policy is
still under discussion, but it can be resolved independently of this
change.
2024-02-14 08:28:37 -05:00
Kyle McCormick
27803f51c8 feat!: assume & remove BLOCKSTORE_USE_BLOCKSTORE_APP_API (#33765)
Originally, Blockstore was an independent micro-service, accessed via a REST API.
Then, we changed Blockstore so it could be installed as an in-process Django app.

To support both modes, there existed a blockstore_api wrapper library in edx-platform,
with toggles controlling whether the wrapper called out to the micro-service's REST API versus the
Django app's Python API. Now that the micro-service Blockstore implementation is deprecated,
though, this wrapper library and toggles are just unnecessary complexity.

As a first step towards cleanup, we:

* remove several toggles and settings (details below);
* remove the blocokstore_api wrapper methods which called the REST API and
  marshalled them back into Python objects; and
* remove all test cases which relied on the Blockstore micro-service (and were skippped in CI).

In the future, we will remove the content libraries indexer, 
clean up the remaining bits of blockstore_api, and flatten out all
the Blockstore-related test class hierarchies which are no longer nceessary.

BREAKING CHANGE:
* These Django settings are removed:
  * BLOCKSTORE_PUBLIC_URL_ROOT
  * BLOCKSTORE_API_URL
  * BLOCKSTORE_API_AUTH_TOKEN
  * BLOCKSTORE_USE_BLOCKSTORE_APP_API
* The blockstore.use_blockstore_app_api Waffle switch is removed.
* edx-platform will act as it did when the DJango setting BLOCKSTORE_USE_BLOCKSTORE_APP_API
  or the Waffle switch blockstore.use_blockstore_app_api were enabled. That is, any running Blockstore
  micro-service instance will be ignored, and the Blockstore package which is installed into edx-platform
  will be used instead.

Ref: https://github.com/openedx/blockstore/issues/296
2023-12-06 15:15:18 +00:00
Jesper Hodge
7fd4c30daf Chore adjust swagger for api gateway (#33694)
* chore: add api.edx.org server and correct route to swagger file endpoints

* chore: make server urls for swagger doc depend on env variables

* chore: add yaml file server descriptions

* chore: rename authoring api route and add description to swagger

* Update cms/urls.py

Co-authored-by: connorhaugh <49422820+connorhaugh@users.noreply.github.com>

* fix: lint

* fix: lint

* fix: lint

---------

Co-authored-by: connorhaugh <49422820+connorhaugh@users.noreply.github.com>
2023-11-16 15:39:46 -05:00
Muhammad Umar Khan
5b469371d5 chore: update connect_timeout for memcache server (#33594) 2023-10-25 17:11:12 +00:00
Zubair Shakoor
70f6f5ad9e fix: replaced mysql57 hosts with mysql80 (#33147) 2023-10-04 17:35:18 +05:00
German
d3a6615deb chore: update location config for devstack-experimental (#33256)
* Update location in devstack-experimental to fix issue while re-indexing
* Updated the devstack.py to point to edx.devstack.elasticsearch710 host
* Enabed the ENABLE_COURSEWARE_INDEX and ENABLE_COURSEWARE_SEARCH
2023-09-14 14:21:47 -03:00
Awais Qureshi
9db024c435 feat!: upgrading django-storages to 1.11.1 2023-08-31 14:21:24 +05:00
Awais Qureshi
3c76d6644f Revert "Revert "Revert "feat!: upgrading django-storages to 1.10.1 (#32571)" (#33109)" (#33111)" (#33113)
This reverts commit 2f8475c307.
2023-08-30 19:40:32 +05:00
Awais Qureshi
2f8475c307 Revert "Revert "feat!: upgrading django-storages to 1.10.1 (#32571)" (#33109)" (#33111)
This reverts commit 191b825a2c.
2023-08-28 14:46:21 +05:00
Awais Qureshi
191b825a2c Revert "feat!: upgrading django-storages to 1.10.1 (#32571)" (#33109)
This reverts commit 9281ea4a9a.
2023-08-28 14:05:38 +05:00
Awais Qureshi
9281ea4a9a feat!: upgrading django-storages to 1.10.1 (#32571)
* feat!: upgrading django-storages to 1.10.1
2023-08-28 13:13:28 +05:00
Feanil Patel
5960840f51 Merge pull request #32496 from ManpraXSoftware/edx-depr31
feat: BLOCK_STRUCTURES_SETTINGS['PRUNING_ACTIVE'] toggle removed depr31
2023-08-22 12:58:02 -04:00
Muhammad Umar Khan
07fbf3b14b chore: update pymemcache settings (#33019) 2023-08-16 15:17:53 +05:00
Yagnesh1998
6ace2aa293 Merge branch 'master' into edx-depr31 2023-08-02 16:09:27 +05:30
Muhammad Umar Khan
23d696675f chore: replace memcachecache with pymemcache backend (#32845) 2023-07-26 16:50:39 +05:00
Yagnesh1998
03b189fc7c feat: Remove FOOTER_ORGANIZATION_IMAGE django settings depr52 (#32757)
* feat: Remove FOOTER_ORGANIZATION_IMAGE django settings depr52

* feat: Update api.py

* feat: Update api.py

* feat: Update footer.html

* feat: change in logo images path

* feat: Update footer.html

as per Diana's suggestion white space is removed.
2023-07-19 10:54:29 -04:00
Yagnesh1998
6e8c10c791 Merge branch 'openedx:master' into edx-depr31 2023-07-17 15:54:46 +05:30
Yagnesh1998
a68a1ed434 feat: Removed JWT_AUTH_REFRESH_COOKIE in depr. (#32664) 2023-07-06 09:14:30 -04:00
Yagnesh
14f90eba96 feat: BLOCK_STRUCTURES_SETTINGS['PRUNING_ACTIVE'] toggle removed depr31 2023-06-17 02:31:07 +05:30
Tim McCormack
be80f2788e test: Remove unneeded signing key from CMS dev/test environments (#32082)
This key should only be needed by the LMS, as the CMS uses OAuth login and
maintains its own session.
2023-04-18 13:37:13 +00:00
Agrendalath
ae1dcbea74 refactor: rename HiddenDescriptor to HiddenBlock
This also handles the AttributeError in the default XBlock class fallback.
2022-12-19 17:48:49 +01:00
0x29a
4d8618517f refactor: xmodule/hidden_module.py -> xmodule/hidden_block.py 2022-12-19 17:48:49 +01:00
Zachary Hancock
2f3c93ed9f feat: sync with exam service on course publish (#31015)
Call into the exam service instead of the edx-proctoring plugin on course publish if the course_apps.exams_ida course waffle flag is enabled. This is an early step in moving away from edx-proctoring
2022-09-20 12:38:32 -04:00
Sarina Canelake
4a2f231302 fix: fix github url strings (org edx -> openedx) 2022-09-15 14:52:28 -04:00
Peter Kabiri
41ee16a6b7 fix: Removed hardcoded social media and mobile store images. (#30630) 2022-08-17 17:51:06 +05:00
Jansen Kantor
33e8d26502 Jkantor/learner course regrade queue (#30778)
* temp: move recalculate_course_and_subsection_grades_for_user to new queue
2022-07-25 15:14:05 -04:00
Feanil Patel
f2ec7b5053 chore: Cleanup last remenants of the edx-microsite code. (#30306)
There are still references to the word `microsite` because the
site-configuration code uses it to referr to it's sub-sites in a few
places.
2022-04-25 10:48:35 -04:00
Keith Grootboom
9d3f52ed67 feat: add PREPEND_LOCALE_PATHS configuration setting (#29851)
edx-platform supports COMPREHENSIVE_THEME_LOCALE_PATHS setting, which
appends paths to the end of LOCALE_PATHS,  but there's currently no
way to add additional paths to the start of the list.

https://tasks.opencraft.com/browse/SE-5299
2022-02-09 13:30:21 -05:00
Kyle McCormick
29ed3d911a build: expose working openedx/lms and openedx/cms docker images (#29549)
This commits prepares edx-platform's experimental Dockerfile
for optional use in devstack. Presently, the image built by this
Dockerfile isn't used anywhere.

Notable changes:
* Drop the openedx/edx-platform image name in favor of
  openedx/lms and openedx/cms.
* Drop the newrelic stages and tags.
* Create openedx/lms-dev and openedx/cms-dev image
  variants which use Django devserver, install dev
  requirements, and specify devstack Django settings.
* Add config files at (lms,cms)/envs/devstack-experimental.yml,
  extracted from the existing edxapp docker image.
* Adds three new scripts, each of which replaces an Ansible
  or Paver-supported function with a pure bash + Django
  management command implementation.
2022-01-10 11:20:10 -05:00