Commit Graph

11170 Commits

Author SHA1 Message Date
Xiaoxi Wang cc61ea6a01 finish the clearrange ops 2022-11-01 14:56:55 -07:00
Xiaoxi Wang 334fced572 add data api implementations; add more realistic fetchKey implementation; finish randomKeyBetween implementation 2022-11-01 14:56:55 -07:00
Xiaoxi Wang 8a59bc276d data operation api (not finished) 2022-11-01 14:56:54 -07:00
Jingyu Zhou 0135d9cee1
Merge pull request #8643 from jzhou77/fix
Remove unnecessary decodeServerTagValue calls
2022-11-01 12:28:08 -07:00
Xiaoge Su f1eca6d672 fixup! Fix compile error 2022-11-01 10:36:25 -07:00
Xiaoge Su 9ee99ad058 fixup! Reformat source 2022-11-01 10:36:25 -07:00
Xiaoge Su 520a14cd72 fixup! update code per comments 2022-11-01 10:36:25 -07:00
Xiaoge Su 769bc28ea3 Reformat source 2022-11-01 10:36:25 -07:00
Xiaoge Su 12ea86efb6 Print parsed log lines via vsnprintf 2022-11-01 10:36:25 -07:00
Xiaoge Su bf84b7a216 Reformat source 2022-11-01 10:36:25 -07:00
Xiaoge Su c4b083f22d Move the periodic logger to RocksDBLogger 2022-11-01 10:36:25 -07:00
Xiaoge Su 74de1aaa8d Redirect RocksDB Log data to FDB TraceEvent
RocksDB supports injecting a custom logger. By introducing
RocksDBLogForwarder, it is possible to retrieve RocksDB log lines and
log them as TraceEvents.

Note that RocksDB is multi-threaded while FDB is designed to be
single threaded, in the FDB event loop there are certain variables
defined as thread_local. This causes that only FDB main thread could
generate TraceEvent, since information like Machine are only available
in the main thread. The current design is to cache all log lines from
the other threads, and let the main thread report the cached log, when:

  * The main thread received log
  * Every some time (this should be a Knob but at this stage a magic
    number is used for convenience.)

It is possible to parse the log lines into Key/Value pairs for
TraceEvent output, but at this stage only the format string is printed
out. Also, RocksDB may log some errors that are interpreted as SevError,
which will cause simulation failures. To prevent this, the maximum error
level is set to SevWarn, which should be reconsidered carefully.

The code is tested by 1) random simulations to ensure the log lines are
included in the XML files 2) force the simulator uses RocksDB and run a
10k correctness run. Both tests passed.
2022-11-01 10:36:25 -07:00
Xiaoge Su 7c4063e32c dfasdf 2022-11-01 10:36:25 -07:00
Jingyu Zhou d1adc067d6
Merge pull request #8646 from sfc-gh-satherton/diskqueue-write-bug
File write() buffer lifetime fix in DiskQueue.
2022-11-01 10:23:12 -07:00
Jingyu Zhou bc098ff8d7 Save a copy for param2 2022-11-01 10:14:58 -07:00
Josh Slocum 178e3bb700
Changing priority for not-at-latest change feed reads (#8651) 2022-11-01 10:59:04 -05:00
Trevor Clinkenbeard 39abc712b0
Merge pull request #8549 from sfc-gh-tclinkenbeard/expose-txn-cost
Create `fdb_transaction_get_total_cost` function
2022-11-01 08:14:57 -07:00
Steve Atherton d12bb31233 File write() buffer lifetime fix in DiskQueue.
Both push() and pushAndCommit() now require reference-counted pageData and file->write() is wrapped in uncancellable(holdWhile(pageData, ..)).  To support this with no additional overhead, StringBuffer returns a Standalone reference to its contents.
2022-10-31 22:06:48 -07:00
Dennis Zhou aab0276969 blob: fix bad continuation actor after shutdown
bin/fdbserver -r simulation -f tests/slow/BlobGranuleVerifyBalance.toml -s 68505494 -b off --crash --trace_format json
2022-10-31 21:28:18 -07:00
Nim Wijetunga 24ce8c0fd0
Commit Proxy Encryption Code Probes (#8618)
* add commit proxy encryption code probes

* fix comment

* address pr comments

* address pr comments

* address pr comments

* address pr comments

* Trigger Build
2022-10-31 20:04:42 -07:00
Jingyu Zhou d76a003351 Remove unnecessary decodeServerTagValue calls 2022-10-31 16:58:08 -07:00
Yao Xiao e7e8c7ea19 Merge branch 'main' of github.com:apple/foundationdb into fix-deadline 2022-10-31 13:26:31 -07:00
Ankita Kejriwal fcdf1ed6ff
Merge pull request #8603 from sfc-gh-tclinkenbeard/ignore-worst-zone
Make `GlobalTagThrottler` ignore worst zone
2022-10-31 12:46:44 -07:00
He Liu 8d76636a7f
Don't unassign ranges from dest servers if they are skipped. (#8611)
Co-authored-by: He Liu <heliu@apple.com>
2022-10-31 12:07:42 -07:00
sfc-gh-tclinkenbeard 0eb1598afa Merge remote-tracking branch 'origin/main' into expose-txn-cost 2022-10-30 09:36:37 -07:00
sfc-gh-tclinkenbeard 1d6bd0057b Merge remote-tracking branch 'origin/main' into add-tag-throttling-latency-bands 2022-10-29 09:49:37 -07:00
sfc-gh-tclinkenbeard c3c2435228 Addressed review comments 2022-10-28 20:48:18 -07:00
Jingyu Zhou 22293ebac5
Merge pull request #8614 from neethuhaneesha/clearRanges
Enable clear range eager reads knob for rocksdb.
2022-10-28 17:03:39 -07:00
Steve Atherton b3017ae330
Merge pull request #8577 from sfc-gh-satherton/storageserver-pml
Unrevert #7578 - new PriorityMultiLock and StorageServer read prioritization.
2022-10-28 16:04:44 -07:00
He Liu 7bb823edbe
Replace KeyRange with std::vector<KeyRange> in DataMoveMetaData and (#8591)
* Replace KeyRange with std::vector<KeyRange> in DataMoveMetaData and
CheckpointMetaData.

* Checked if ranges.empty().

* fmt.

* Resolved some comments.

Co-authored-by: He Liu <heliu@apple.com>
2022-10-28 15:22:55 -07:00
neethuhaneesha 55fc0c1a0b Enable clear range eager reads knob for rocksdb. 2022-10-28 14:30:05 -07:00
Steve Atherton f4e8854e8c
Merge pull request #8517 from sfc-gh-etschannen/feature-disk-queue-perf
added a disk queue load generator
2022-10-28 14:15:55 -07:00
Steve Atherton 326d45819e Merge branch 'main' into storageserver-pml 2022-10-28 14:14:44 -07:00
sfc-gh-tclinkenbeard 948773bab4 Merge remote-tracking branch 'origin/main' into ignore-worst-zone 2022-10-28 13:36:21 -07:00
sfc-gh-tclinkenbeard 07e80f7398 Fixed bug in /GlobalTagThrottler/WriteThrottling unit test 2022-10-28 13:35:30 -07:00
Evan Tschannen 51e2f8e74b made the test clean up after itself 2022-10-28 09:26:48 -07:00
Andrew Noyes 0a15f081a1
Proactively clean up idempotency ids for successful commits (#8578)
* Proactively clean up idempotency ids for successful commits

This change also includes some minor changes from my branch working on
an idempotency ids cleaner, that I'd like to get merged sooner rather
than later.

- Adding a timestamp to idempotency values
- Making IdempotencyId an actor file
- Adding commit_unknown_result_fatal
- Checking idempotencyIdsExpiredVersion in determineCommitStatus
- Some testing QOL changes

* Factor out decodeIdempotencyKey logic

* Fix formatting

* Update flow/include/flow/error_definitions.h

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

* Use KeyBackedObjectProperty for idempotencyIdsExpiredVersion

* Add IDEMPOTENCY_ID_IN_MEMORY_LIFETIME knob

* Rename ExpireIdempotencyKeyValuePairRequest

Also add a code probe for the case where an ExpireIdempotencyIdRequest is
received before the count is known, and add an assert

* Fix formatting and add TODO for nwijetunga

Co-authored-by: A.J. Beamon <aj.beamon@snowflake.com>
2022-10-28 09:07:54 -07:00
Yao Xiao 05a1497d8a resolve comments 2022-10-27 22:54:20 -07:00
sfc-gh-tclinkenbeard 83bfa95921 Added /GlobalTagThrottler/IgnoreWorstZone unit test 2022-10-27 21:18:39 -07:00
sfc-gh-tclinkenbeard c0fcf59a8c Fix bug in GlobalTagThrottler::getLimitingTps.
Also add comments to GlobalTagThrottler unit tests
2022-10-27 21:18:39 -07:00
sfc-gh-tclinkenbeard 4b9c21ed8b Ignore worst zones in GlobalTagThrottler::getLimitingTps 2022-10-27 21:18:39 -07:00
sfc-gh-tclinkenbeard e4836a47a9 Replace GlobalTagThrottlerTesting namespace with anonymous namespace 2022-10-27 21:18:39 -07:00
sfc-gh-tclinkenbeard 6a8c6e83e4 Rename StorageQueueInfo::getTagThrottlingRatio 2022-10-27 21:18:39 -07:00
sfc-gh-tclinkenbeard 950ac1c867 Improve encapsulation for TLogQueueInfo and StorageQueueInfo 2022-10-27 21:18:35 -07:00
Steve Atherton 1dad43cb06 Remove unnecessary change feed disk read lock as its functionality is obsoleted by the storage server read priority lock. 2022-10-27 18:03:14 -07:00
Steve Atherton f9ad7fb35b Merge origin/main into storageserver-pml 2022-10-27 18:00:11 -07:00
Steve Atherton 67a76db9bd Bug fix, FlowLock releaser created too late. 2022-10-27 17:54:33 -07:00
Yao Xiao f4bee6d2c5 Update error code. 2022-10-27 15:32:42 -07:00
sfc-gh-tclinkenbeard 6ae0aac153 Merge remote-tracking branch 'origin/main' into add-tag-throttling-latency-bands 2022-10-27 14:07:51 -07:00
Lukas Joswiak 91146a03f0 Write cluster ID to `ClientDBInfo`
This enables clients to receive the cluster ID.
2022-10-27 13:56:13 -07:00