Commit Graph

1510 Commits

Author SHA1 Message Date
Vaidas Gasiunas 5abdb1e655 Upgrade Tests: Disable upgrade tests in sanitizer builds 2022-04-15 16:33:48 +02:00
Vaidas Gasiunas 0a6b74ad3f Upgrade Tests: Remove 6.2 from regression testing, because of sporadic failures 2022-04-14 14:30:55 +02:00
Vaidas Gasiunas a03ba928e4 Upgrade Tests: Introduce transaction retry limit; Trace long retry chains; An option to run the test binary with gdb 2022-04-13 16:50:02 +02:00
Vaidas Gasiunas f7636ecf3b Upgrade Tests: Addressing review comments 2022-04-13 14:17:23 +02:00
Vaidas Gasiunas 9e46128b6f Upgrade Test: Include only currently working tests into the ctest suite 2022-04-12 20:03:29 +02:00
Vaidas Gasiunas 1e2541f1db Upgrade Tests: Log long waits on futures 2022-04-12 19:44:06 +02:00
Vaidas Gasiunas 580010e64c Merge remote-tracking branch 'apple/main' into vgasiunas-upgrade-test 2022-04-12 13:43:36 +02:00
Aaron Molitor 1328c34323 update version to 7.2.0 -- address pr comments 2022-04-11 23:23:27 -05:00
Aaron Molitor 5ba8b82ba6 update version to 7.2.0 -- address pr comments 2022-04-11 23:23:27 -05:00
Aaron Molitor f49b761d14 update version to 7.2.0 -- pr comment 2022-04-11 23:23:27 -05:00
Aaron Molitor cbaef8f03b update version to 7.2.0 2022-04-11 23:23:27 -05:00
Johannes M. Scheuermann dca18ac71e Add support for the reboot command in go bindings 2022-04-11 14:56:18 -07:00
Josh Slocum 6276cebad9
Blob integration (#6808)
* Fixing leaked stream with explicit notify failed before destructor

* better logic to prevent races in change feed fetching

* Found new race that makes assert incorrect

* handle server overloaded in initial read from fdb

* Handling more blob error types in granule retry

* Fixing rollback metadata problem, added better debugging

* Fixing version race when fetching change feed metadata

* Better racing split request handling

* fixing assert

* Handle change feed popped check in the blob worker

* fix: do not use a RYW transaction for a versionstamp because of randomize API version (#6768)

* more merge conflict issues

* Change feed destroy fixes

* Fixing change feed destroy and move race

* Check error condition in BG file req

* Using relative endpoints for blob worker interface

* Fixing bug in previous fix

* More destroy and move race fixes

* Don't update empty version on destroy in case it gets rolled back. moved() and removing will take care of ensuring it is not read

* Bug fix (#6796)

* fix: do not use a RYW transaction for a versionstamp because of randomize API version

* fix: if the initialSnapshotVersion was pruned, granule history was incorrect

* added a way to compress null bytes in printable()

* Fixing durability issue with moving and destroying change feeds

* Adding fix for not fully deleting files for a granule that child granules need to re-snapshot

* More destroy and move races

* Fixing change feed destroy and pop races

* Renaming bg prune to purge, and adding a C api and unit test for it

* more cleanup

* review comments

* Observability for granule purging

* better handling for change feed not registered

* Fixed purging bugs (#6815)

* fix: do not use a RYW transaction for a versionstamp because of randomize API version

* fix: if the initialSnapshotVersion was pruned, granule history was incorrect

* added a way to compress null bytes in printable()

* fixed a few purging bugs

Co-authored-by: Evan Tschannen <evan.tschannen@snowflake.com>
2022-04-08 14:15:25 -07:00
Lukas Joswiak 73a7c32982
Add fdbcli command to read/write version epoch (#6480)
* Initialize cluster version at wall-clock time

Previously, new clusters would begin at version 0. After this change,
clusters will initialize at a version matching wall-clock time. Instead
of using the Unix epoch (or Windows epoch), FDB clusters will use a new
epoch, defaulting to January 1, 2010, 01:00:00+00:00. In the future,
this base epoch will be modifiable through fdbcli, allowing
administrators to advance the cluster version.

Basing the version off of time allows different FDB clusters to share
data without running into version issues.

* Send version epoch to master

* Cleanup

* Update fdbserver/storageserver.actor.cpp

Co-authored-by: A.J. Beamon <aj.beamon@snowflake.com>

* Jump directly to expected version if possible

* Fix initial version issue on storage servers

* Add random recovery offset to start version in simulation

* Type fixes

* Disable reference time by default

Enable on a cluster using the fdbcli command `versionepoch add 0`.

* Use correct recoveryTransactionVersion when recovering

* Allow version epoch to be adjusted forwards (to decrease the version)

* Set version epoch in simulation

* Add quiet database check to ensure small version offset

* Fix initial version issue on storage servers

* Disable reference time by default

Enable on a cluster using the fdbcli command `versionepoch add 0`.

* Add fdbcli command to read/write version epoch

* Cause recovery when version epoch is set

* Handle optional version epoch key

* Add ability to clear the version epoch

This causes version advancement to revert to the old methodology whereas
versions attempt to advance by about a million versions per second,
instead of trying to match the clock.

* Update transaction access

* Modify version epoch to use microseconds instead of seconds

* Modify fdbcli version target API

Move commands from `versionepoch` to `targetversion` top level command.

* Add fdbcli tests for

* Temporarily disable targetversion cli tests

* Fix version epoch fetch issue

* Fix Arena issue

* Reduce max version jump in simulation to 1,000,000

* Rework fdbcli API

It now requires two commands to fully switch a cluster to using the
version epoch. First, enable the version epoch with `versionepoch
enable` or `versionepoch set <versionepoch>`. At this point, versions
will be given out at a faster or slower rate in an attempt to reach the
expected version. Then, run `versionepoch commit` to perform a one time
jump to the expected version. This is essentially irreversible.

* Temporarily disable old targetversion tests

* Cleanup

* Move version epoch buggify to sequencer

This will cause some issues with the QuietDatabase check for the version
offset - namely, it won't do anything, since the version epoch is not
being written to the txnStateStore in simulation. This will get fixed in
the future.

Co-authored-by: A.J. Beamon <aj.beamon@snowflake.com>
2022-04-08 12:33:19 -07:00
Vaidas Gasiunas f91acd323c Merge remote-tracking branch 'apple/main' into vgasiunas-upgrade-test 2022-04-08 20:27:45 +02:00
Vaidas Gasiunas b267246bac Upgrade Test: enable GRV caching only for API version >= 710 2022-04-08 20:25:02 +02:00
Tao Lin eb270d44b7 Remove unnecessary FDB_API_CHANGED 2022-04-08 10:18:16 -07:00
Tao Lin 73ed34d2fb Fixes #6793: Upgrade from 7.0.0 to 7.1.0 fails because of missing function fdb_transaction_get_mapped_range 2022-04-08 09:32:18 -07:00
Vaidas Gasiunas b544adad12 Merge remote-tracking branch 'apple/main' into vgasiunas-upgrade-test 2022-04-08 15:01:29 +02:00
Vaidas Gasiunas ac48e5000e Upgrade Test: Include upgrade from 7.0 in ctest 2022-04-07 19:32:57 +02:00
Jon Fu b0ae22f16d Merge branch 'main' of github.com:apple/foundationdb into jfu-grv-cache-multi-threaded 2022-04-06 12:28:28 -04:00
Vaidas Gasiunas ef0ec3d893 Merge remote-tracking branch 'apple/main' into vgasiunas-upgrade-test 2022-04-06 12:01:52 +02:00
Chaoguang Lin 7d365bd1bb
Remote ikvs debugging (#6465)
* initial structure for remote IKVS server

* moved struct to .h file, added new files to CMakeList

* happy path implementation, connection error when testing

* saved minor local change

* changed tracing to debug

* fixed onClosed and getError being called before init is finished

* fix spawn process bug, now use absolute path

* added server knob to set ikvs process port number

* added server knob for remote/local kv store

* implement simulator remote process spawning

* fixed bug for simulator timeout

* commit all changes

* removed print lines in trace

* added FlowProcess implementation by Markus

* initial debug of FlowProcess, stuck at parent sending OpenKVStoreRequest to child

* temporary fix for process factory throwing segfault on create

* specify public address in command

* change remote kv store knob to false for jenkins build

* made port 0 open random unused port

* change remote store knob to true for benchmark

* set listening port to randomly opened port

* added print lines for jenkins run open kv store timeout debug

* removed most tracing and print lines

* removed tutorial changes

* update handleIOErrors error handling to handle remote-ikvs cases

* Push all debugging changes

* A version where worker bug exists

* A version where restarting tests fail

* Use both the name and the port to determine the child process

* Remove unnecessary update on local address

* Disable remote-kvs for DiskFailureCycle test

* A version where restarting stuck

* A version where most restarting tests green

* Reset connection with child process explicitly

* Remove change on unnecessary files

* Unify flags from _ to -

* fix merging unexpected changes

* fix trac.error to .errorUnsuppressed

* Add license header

* Remove unnecessary header in FlowProcess.actor.cpp

* Fix Windows build

* Fix Windows build, add missing ;

* Fix a stupid bug caused by code dropped by code merging

* Disable remote kvs by default

* Pass the conn_file path to the flow process, though not needed, but the buildNetwork is difficult to tune

* serialization change on readrange

* Update traces

* Refactor the RemoteIKVS interface

* Format files

* Update sim2 interface to not clog connections between parent and child processes in simulation

* Update comments; remove debugging symbols; Add error handling for remote_kvs_cancelled

* Add comments, format files

* Change method name from isBuggifyDisabled to isStableConnection; Decrease(0.1x) latency for stable connections

* Commit the IConnection interface change, forgot in previous commit

* Fix the issue that onClosed request is cancelled by ActorCollection

* Enable the remote kv store knob

* Remove FlowProcess.actor.cpp and move functions to RemoteIKeyValueStore.actor.cpp; Add remote kv store delay to avoid race; Bind the child process to die with parent process

* Fix the bug where one process starts storage server more than once

* Add a please_reboot_remote_kv_store error to restart the storage server worker if remote kvs died abnormally

* Remove unreachable code path and add comments

* Clang format the code

* Fix a simple wait error

* Clang format after merging the main branch

* Testing mixed mode in simulation if remote_kvs knob is enabled, setting the default to false

* Disable remote kvs for PhysicalShardMove which is for RocksDB

* Cleanup #include orders, remove debugging traces

* Revert the reorder in fdbserver.actor.cpp, which fails the gcc build

Co-authored-by: “Lincoln <“lincoln.xiao@snowflake.com”>
2022-03-31 17:08:59 -07:00
Tao Lin 001909be08
Fixes for when getMappedRange cannot parse as tuple (#6665) 2022-03-31 14:06:45 -07:00
A.J. Beamon 5469b57a2b Add a note that opening a tenant does not check whether that tenant exists in the cluster 2022-03-31 11:39:50 -07:00
A.J. Beamon be7315473a Move tenant creation/deletion into a TenantManagement class 2022-03-30 16:31:28 -07:00
A.J. Beamon 6570ae44c6 Use special keys to create/delete tenants 2022-03-30 16:31:28 -07:00
Jon Fu 995f1b3601 Support tuples in Java tenants 2022-03-30 16:31:28 -07:00
A.J. Beamon a2a97e7176 Add tenant support to the Java bindings 2022-03-30 16:31:28 -07:00
Jon Fu 4677b59fd8 Merge branch 'main' of github.com:apple/foundationdb into jfu-grv-cache-multi-threaded 2022-03-30 15:29:56 -04:00
Jon Fu f266695a76 clear shared state map entries on version upgrade and use currentProtocolVersion instead of piping version through function parameters 2022-03-30 15:28:55 -04:00
A.J. Beamon fc68cdf45f
Merge pull request #6693 from sfc-gh-ajbeamon/python-tenant-management-module
Move Python tenant management to its own module
2022-03-30 12:03:08 -07:00
Jon Fu 3283d07b4c Merge branch 'main' of github.com:apple/foundationdb into jfu-grv-cache-multi-threaded 2022-03-30 13:44:28 -04:00
Jon Fu 9d0a520fe0 add ProtocolVersion to shared state and state cluster map 2022-03-30 13:28:06 -04:00
Xiaoxi Wang e644c6da49
Merge pull request #6716 from sfc-gh-xwang/memory-test-ide
fix cmake error after adding memory test when OPEN_FOR_IDE=ON
2022-03-29 14:23:16 -07:00
Jon Fu 53d252fda0 Merge branch 'main' of github.com:apple/foundationdb into jfu-grv-cache-multi-threaded 2022-03-29 17:23:08 -04:00
Jon Fu bdbe78e48f address code review comments 2022-03-29 17:20:22 -04:00
Andrew Noyes d727e7648e Fix a few memory issues found by ASAN 2022-03-29 12:39:12 -07:00
Xiaoxi Wang bc3e5cdaa1 fix cmake error when OPEN_FOR_IDE=ON 2022-03-29 12:02:56 -07:00
Josh Slocum 721c64b698 Adding Blob Granule Client C Unit Tests 2022-03-28 15:42:33 -05:00
A.J. Beamon 3cf0ea5950
Merge pull request #6697 from sfc-gh-ajbeamon/fix-tenant-map-range-read-bug
Fix bug in tenant map range reads when the end key is outside of the tenant map range
2022-03-28 10:55:33 -07:00
Steve Atherton 478ff1eb76
Merge pull request #6652 from sfc-gh-anoyes/anoyes/fast-alloc
Move most usage of FastAlloc to malloc
2022-03-26 15:46:05 -07:00
A.J. Beamon 2475c4e2d6 Fix various non-compiling code errors. 2022-03-25 15:56:49 -07:00
A.J. Beamon 48447c2788 Add the tenant management module to CMakeLists. Don't test tenants before API version 710. 2022-03-25 14:35:16 -07:00
A.J. Beamon e8a38bb048 Fix bug in tenant map range reads when the end key is outside of the tenant map range. 2022-03-25 14:24:25 -07:00
A.J. Beamon b4cfcc10d3 Move Python tenant management to its own module 2022-03-25 11:36:35 -07:00
Josh Slocum bf3da72637 Merge branch 'main' into bg_client_bindings_improvements 2022-03-24 15:56:30 -05:00
Josh Slocum b42c49ca0a Adding full file length for future-proofing 2022-03-24 15:56:03 -05:00
Josh Slocum b92c6ea92c granule parallelism, metrics, and other improvements to bg client bindings 2022-03-24 13:44:09 -05:00
Vaidas Gasiunas 68a9abd3c5 Upgrade Test: Derive API version from the versions tested; Improve handing of error situations 2022-03-24 17:23:17 +01:00