Skip to content

Port 13 stable update test#17

Open
AlbaHerrerias wants to merge 169 commits intoport-python-testsfrom
port-13-stable-update-test
Open

Port 13 stable update test#17
AlbaHerrerias wants to merge 169 commits intoport-python-testsfrom
port-13-stable-update-test

Conversation

@AlbaHerrerias
Copy link

@AlbaHerrerias AlbaHerrerias commented Nov 14, 2025

Overview

Testing recommendations

make elixir tests=test/elixir/test/mango/13_stable_update_test.exs

Related Issues or Pull Requests

Checklist

  • Code is written and works correctly
  • Changes are covered by tests
  • Any new configurable parameters are documented in rel/overlay/etc/default.ini
  • Documentation changes were made in the src/docs folder
  • Documentation changes were backported (separated PR) to affected branches

"should not return design docs"
],
"SupportStableAndUpdate": [
"update updates view when specified"
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not 100% sure these go here instead of search.elixir, confirmation would be appreciated, thanks

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It only goes to search when the Python requires text service

MangoDatabase.recreate(@db_name)
# Hack to prevent auto-indexer from foiling update=False test
# https://github.com/apache/couchdb/issues/2313
MangoDatabase.save_docs(@db_name, [%{"_id" => "_design/foo", "language" => "query", "autoupdate" => false}])
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The original function is save_doc (singular), I don't think it's worth to create a function just for it, but let me know if you think otherwise

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The function is created, you can use it now

@hulkoba hulkoba force-pushed the port-python-tests branch 8 times, most recently from c413a13 to 25f1f55 Compare November 19, 2025 14:21
nickva and others added 29 commits February 18, 2026 07:31
Previously we didn't handle the case when the "infinity" value was explicitly
set in the config file. We only handled the case when it was the default value.
When debugging processes getting stuck in hibernation bug [1] a few benchmarks
showed that hibernation can be pretty expensive. I saw 20% or so reduction in
latency in couch_work_queue if we hibernate after every single item insertion.

Erlang documents warn about this [2]:

> Use this feature with care, as hibernation implies at least two garbage
collections (when hibernating and shortly after waking up) and is not something
you want to do between each call to a busy server.

In a few places like the `couch_work_queue` and `couch_db_updater` we did
exactly that. However, since we added that more Erlang/OTP implemented a new
`gen_server` option - `{hibernate_after, Timeout}`. It will trigger hibernation
after an idle time. That seems ideal for us - it keeps expensive hibernation
out of the main data path, as docs warn us about, but once the server goes idle
we still get to run it to dereference any ref binaries.

Since we encountered the recent hibernation bug [1] also add an option to
disable it altogether, just to have a way to mitigate the issue when running on
OTP 27 and 28 before the fix is out.

[1] erlang/otp#10651
[2] https://www.erlang.org/doc/apps/stdlib/gen_server.html
[3] apache@d9eb87f
Send 404 for /_all_dbs and /_dbs_info with extra path parts
There are two main improvements:

1) Remove dynamic runtime reloading. That feature is not useful any longer
after we stopped doing online relups, and instead became a potential landmine
that can lead to metrics unexpectedly faling if stats description files, or
disk access to them changes at runtime. The only minor benefit previous
behavior had was was for local dev/run development, coupled with online module
reloading; but that hardly justifies the complexity and the confusion resulting
from stats all of the sudden breaking in production.

2) Strengthen a few asserts during stats loading. Only accept missing stats
description from applications, and stop on any other error. We don't want to
run with stats missing or unloadable or constantly spewing "unknown metric"
error.
…-arm

ci: temporarily disable freebsd-arm worker because it is too slow
…ct-index-test

Port Python test to Elixir: `12_use_correct_index_test`
…ult-field-test

Port Python test to Elixir: `06-text-default-field-test`
Port Python test to Elixir: `07_text_custom_field_list_test`
Almalinux 10 was enabled by Ronny in the couchdb-pkg repo!

Also, add an extra "intermediate" variant, that might be useful to
have especially before swithing the minimum up. In our case that's
Erlang 27.
path
open_doc
delete_doc
ddoc_info
delete_index
bulk_delete
Port Python test to Elixir: `01-index-crud-test`
Port Python test to Elixir: `03-operator-test`
@hulkoba hulkoba force-pushed the port-13-stable-update-test branch from 5bb4250 to 06edf2a Compare February 23, 2026 08:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.