OpenSlides / OpenSlides/openslides-backend

[RelDB] Concurrency-related stuff

Open
#3,319 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement needs investigation
Dominant language
Python
Stars
9
Forks
40
Avg merge
1d 22h
Merged PRs (30d)
19

Description

There seem to be some uncertainties in regards to locking and concurrency. Not necessarily blockers, but uncomfortable things nonetheless. Here's a list of topics:

  • See this comment https://github.com/OpenSlides/openslides-backend/issues/3305#issuecomment-3861162976 and the one above.
  • test_create_sequential_number.py test_create_sequential_numbers_race_condition problem will need to be investigated (Impulse from @hjanott was to search for dead locks in postgres)
  • db_connection_handling.py in create_os_conn_pool, try enabling prepared statements again, according to @hjanott they were disabled due to problems with concurrency.
  • system/test_write.py: the two_write_requests_with_locked_fields test deals with locks and is currently skipped. It should be fixed or deleted. It is quite possible that the concept behind the test is obsolete.
  • action/test_action_command_format.py: Implement locked fields or delete commented out code. Apparently 95% chance that the test is obsolete.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the linked comment on issue 3305 and the listed files: test_create_sequential_number.py, db_connection_handling.py, system/test_write.py, and action/test_action_command_format.py. Investigate the concurrency behavior and determine which skipped or commented-out tests and prepared-statement settings remain valid. Done means each listed uncertainty has a documented resolution and the relevant tests or code are updated accordingly.

Written by the indexing model from the issue text.

Assessment

Tech stack
postgresql, python
Domain
backend, databases, testing
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.