internetarchive / internetarchive/openlibrary

testing.openlibrary.org separated memcache causing stale pages

Open
#2,755 2 comments 0 reactions 0 assignees View on GitHub
Affects: Configuration Lead: @cdrini Module: Infogami Module: Memcache Needs: Investigation Priority: 4 Theme: Development Type: Bug
Dominant language
Python
Stars
6.7k
Forks
2k
Avg merge
2d 19h
Merged PRs (30d)
138

Description

In fixing #2628 , we gave dev.openlibrary.org (and any other prod-data-access environments) separate memcaches (updating `openlibrary.yml` to point to these). Unfortunately, we forgot that these memcaches are also specified in `infobase.yml`. This has caused essentially #2040 to re-appear, but on dev only. This issue arises when the site has access to a memcache which infobase does not. Essentially:
1. page viewed on dev; gets stored in memcache
2. edit made on dev
3. edit sent to prod infobase; infobase purges the item from prod memcaches (because it was edited)
4. Visiting the item on dev, dev uses its own memcache, which hasn't been purged

### Steps to Reproduce

1. Go to https://dev.openlibrary.org/books/OL7673800M (or another page)
2. Edit the title and save

* Actual: The old title appears
* Expected: The new title should appear

### Details

- **Logged in (Y/N)?** Y
- **Browser type/version?** FF71
- **Operating system?** Win10
- **Environment (prod/dev/local)?** dev

### Possible Solutions
- Have dev instance also have its own instance of infobase, but hooked to the prod DB.
- Will this work at all, or will infobase just explode?

### Related files

### Stakeholders
@mekarpeles

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.