From 6338c682ec6e10b37954699fdc9341a88dd118fc Mon Sep 17 00:00:00 2001 From: Michael Cahill Date: Tue, 29 Nov 2016 16:58:14 +1100 Subject: WT-3028 Don't check for blocked eviction with in-memory workloads. (#3159) * Don't check for blocked eviction with in-memory workloads. The cache can become full of clean pages so eviction can't make progress, but application threads are not blocked. We shouldn't fail in this case. * Directly track if reconciliation makes progress. Give up on page rewrites that don't use any updates. --- dist/flags.py | 1 - 1 file changed, 1 deletion(-) (limited to 'dist') diff --git a/dist/flags.py b/dist/flags.py index 676f224cbb6..e200f95fba6 100644 --- a/dist/flags.py +++ b/dist/flags.py @@ -114,7 +114,6 @@ flags = { 'session' : [ 'SESSION_CAN_WAIT', 'SESSION_INTERNAL', - 'SESSION_IN_SPLIT', 'SESSION_LOCK_NO_WAIT', 'SESSION_LOCKED_CHECKPOINT', 'SESSION_LOCKED_HANDLE_LIST', -- cgit v1.2.1 From 1f8860ea54b4ef6e8bcb88692e3b26ac3dbbae64 Mon Sep 17 00:00:00 2001 From: Keith Bostic Date: Thu, 1 Dec 2016 17:25:55 -0500 Subject: WT-3048 WiredTiger maximum size warning uses the wrong format. (#3164) Also force the type of WT_BTREE_MAX_OBJECT_SIZE, there's no guarantee all systems will consistently declare UINT32_MAX. --- dist/s_void | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'dist') diff --git a/dist/s_void b/dist/s_void index 16684e962e6..06111245fe2 100755 --- a/dist/s_void +++ b/dist/s_void @@ -5,7 +5,8 @@ trap 'rm -f $t' 0 1 2 3 13 15 cd .. -# Turn a C file into a line per function that returns an int. +# Parse a C file, discarding functions that don't return an int, and formatting +# the remaining functions as a single line. file_parse() { sed -n \ @@ -109,7 +110,7 @@ func_ok() } # Complain about functions which return an "int" but which don't return except -# at the end of the function. This script is a kluge and isn't run by default. +# at the end of the function. for f in `find bench ext src test -name '*.[ci]'`; do if expr "$f" : '.*/windows_shim.c' > /dev/null; then continue -- cgit v1.2.1 From 2f18a859cea47f0352cea9fbd64b396e52095ed8 Mon Sep 17 00:00:00 2001 From: Michael Cahill Date: Mon, 5 Dec 2016 11:49:34 +1100 Subject: WT-3034 Add support for named snapshots including updates. (#3161) This supports a model where one session performs updates in a transaction after creating a named snapshot and other sessions can use that snapshot and read the updates. In other words, they see exactly what the updating session sees. --- dist/api_data.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'dist') diff --git a/dist/api_data.py b/dist/api_data.py index 5a81e8dd080..aa76ff45d1a 100644 --- a/dist/api_data.py +++ b/dist/api_data.py @@ -1119,6 +1119,10 @@ methods = { Config('to', '', r''' drop all snapshots up to and including the specified name'''), ]), + Config('include_updates', 'false', r''' + make updates from the current transaction visible to users of the + named snapshot. Transactions started with such a named snapshot are + restricted to being read-only''', type='boolean'), Config('name', '', r'''specify a name for the snapshot'''), ]), -- cgit v1.2.1 From d2dfe81c95cb2cd2c04cf7e7711c8ad247d63ce1 Mon Sep 17 00:00:00 2001 From: Keith Bostic Date: Sun, 4 Dec 2016 22:21:45 -0500 Subject: WT-3014 Add GCC/clang support for ELF symbol visibility. (#3138) * Rewrite the demo file system example to not require internal WiredTiger functions. * Replace calls to __wt_calloc/__wt_free with C library calloc/free/calls, avoid using internal WiredTiger functions. --- dist/s_prototypes | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'dist') diff --git a/dist/s_prototypes b/dist/s_prototypes index 4c07b9aa160..d6228866f08 100755 --- a/dist/s_prototypes +++ b/dist/s_prototypes @@ -39,9 +39,12 @@ proto() -e H \ -e x \ -e '}' \ - -e '# Add the gcc warn_unused_result attribute to any external' \ + -e '# Add the warn_unused_result attribute to any external' \ -e '# functions that return an int.' \ -e '/^extern int /s/$/ WT_GCC_FUNC_DECL_ATTRIBUTE((warn_unused_result))/' \ + -e '# Add the hidden attribute to any external functions without' \ + -e '# an explicit visibility.' \ + -e '/visibility/!s/$/ WT_GCC_FUNC_DECL_ATTRIBUTE((visibility("hidden")))/' \ -e 's/$/;/' \ -e p < $1 } -- cgit v1.2.1 From 853430ea86b8e29cdfa9de34606405d52384d2db Mon Sep 17 00:00:00 2001 From: sueloverso Date: Sun, 4 Dec 2016 23:22:58 -0500 Subject: WT-2670 Add access_pattern_hint configuration for tables (#3155) --- dist/api_config.py | 3 ++- dist/api_data.py | 8 ++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) (limited to 'dist') diff --git a/dist/api_config.py b/dist/api_config.py index 1069a7037ce..d83a632321e 100644 --- a/dist/api_config.py +++ b/dist/api_config.py @@ -198,7 +198,8 @@ def get_default(c): return 'false' elif c.default == 'true': return 'true' - elif t == 'string' and c.default == 'none': + elif t == 'string' and c.default == 'none' and \ + not c.flags.get('choices', []): return '' elif t == 'category': return '(%s)' % (','.join('%s=%s' % (subc.name, get_default(subc)) diff --git a/dist/api_data.py b/dist/api_data.py index aa76ff45d1a..2d4371923e1 100644 --- a/dist/api_data.py +++ b/dist/api_data.py @@ -120,6 +120,14 @@ lsm_config = [ # Per-file configuration file_config = format_meta + [ + Config('access_pattern_hint', 'none', r''' + It is recommended that workloads that consist primarily of + updates and/or point queries specify \c random. Workloads that + do many cursor scans through large ranges of data specify + \c sequential and other workloads specify \c none. The + option leads to an advisory call to an appropriate operating + system API where available''', + choices=['none', 'random', 'sequential']), Config('block_allocation', 'best', r''' configure block allocation. Permitted values are \c "first" or \c "best"; the \c "first" configuration uses a first-available -- cgit v1.2.1 From f1152ba768da7e03fbca5131b289f0407565050a Mon Sep 17 00:00:00 2001 From: Keith Bostic Date: Mon, 5 Dec 2016 22:06:19 -0500 Subject: WT-2969 Possible snapshot corruption during compaction (#3160) * Change compaction to use database-wide checkpoints: rather than processing each file separately and checkpointing after each time we compact a file, do a compaction pass over all of the files then database-wide checkpoints. * Save/restore the WT_SESSION_CAN_WAIT, WT_SESSION_NO_EVICTION flags set during checkpoint, the session handle may be used for other tasks in the future. * There's no need to hold the checkpoint lock while opening the metadata cursor. * When adc1cfb went in (WT-2394, gather handles for compaction first, before doing the actual compaction), we broke data-source support for compaction. Add back in data-source support and simplify the __wt_schema_worker() code, it no longer needs to know about LSM or data-source compaction. * Disallow LSM compaction in an existing transaction (LSM didn't check, but there's no reason to special case LSM compaction so it can run in an existing transaction, and it's potentially confusing, or fragile if LSM compaction some day requires checkpoints). * Do a checkpoint after removing the key/value pairs, otherwise we might not find anything to work with in our compaction pass. * Replace WT_SESSION_LOCK_NO_WAIT with per-lock operation flags. If we set WT_SESSION_LOCK_NO_WAIT and the lock is acquired, then the underlying operation eventually needs to acquire its own locks, having the WT_SESSION_LOCK_NO_WAIT flag set in the session may not be correct. --- dist/api_data.py | 7 ++++--- dist/flags.py | 1 - dist/s_define.list | 2 +- dist/s_string.ok | 1 + 4 files changed, 6 insertions(+), 5 deletions(-) (limited to 'dist') diff --git a/dist/api_data.py b/dist/api_data.py index 2d4371923e1..2b7ef4a94e1 100644 --- a/dist/api_data.py +++ b/dist/api_data.py @@ -855,9 +855,10 @@ methods = { 'WT_SESSION.drop' : Method([ Config('checkpoint_wait', 'true', r''' - wait for the checkpoint lock, if \c checkpoint_wait=false, perform - the drop operation without taking a lock, returning EBUSY if the - operation conflicts with a running checkpoint''', + wait for concurrent checkpoints to complete before attempting the drop + operation. If \c checkpoint_wait=false, attempt the drop operation + without waiting, returning EBUSY if the operation conflicts with a + running checkpoint''', type='boolean', undoc=True), Config('force', 'false', r''' return success if the object does not exist''', diff --git a/dist/flags.py b/dist/flags.py index e200f95fba6..320bd8f6fb9 100644 --- a/dist/flags.py +++ b/dist/flags.py @@ -114,7 +114,6 @@ flags = { 'session' : [ 'SESSION_CAN_WAIT', 'SESSION_INTERNAL', - 'SESSION_LOCK_NO_WAIT', 'SESSION_LOCKED_CHECKPOINT', 'SESSION_LOCKED_HANDLE_LIST', 'SESSION_LOCKED_METADATA', diff --git a/dist/s_define.list b/dist/s_define.list index 7b11d665de5..372a251bf01 100644 --- a/dist/s_define.list +++ b/dist/s_define.list @@ -54,7 +54,7 @@ WT_STAT_INCRV_BASE WT_STAT_WRITE WT_TIMEDIFF_US WT_TRET_ERROR_OK -WT_WITH_LOCK +WT_WITH_LOCK_NOWAIT WT_WITH_LOCK_WAIT __F __WIREDTIGER_EXT_H_ diff --git a/dist/s_string.ok b/dist/s_string.ok index d19c05e802b..3476dff0e84 100644 --- a/dist/s_string.ok +++ b/dist/s_string.ok @@ -247,6 +247,7 @@ NONINFRINGEMENT NOTFOUND NOTREACHED NOVALUE +NOWAIT NUL NUM NetBSD -- cgit v1.2.1 From 587be3ea72844924de5f43db9f1bc3ea61a10e5c Mon Sep 17 00:00:00 2001 From: Don Anderson Date: Tue, 6 Dec 2016 22:29:11 -0500 Subject: WT-2336 Add a test validating schema operations via file system call monitoring (#3059) Take advantage of the above to create a maintainable .run file that works on systems without ftruncate. Use macros to avoid using so many #ifdefs. When output differences are detected, report the output's line number (or range of lines numbers we tried to match) to make it easier to diagnose differences. Add O_NOATIME to list of predefines to check. The probe needs to be compiled -D_GNU_SOURCE on Linux. Use all probed variables in the symbol table when looking at strace/dtruss output, as strace uses symbolic flag names. --- dist/s_python | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'dist') diff --git a/dist/s_python b/dist/s_python index b8aa5848637..bfe3ba57783 100755 --- a/dist/s_python +++ b/dist/s_python @@ -17,10 +17,10 @@ test -s $t && { echo '[tab] characters appear in Python scripts:' cat $t } -# Check Python coding standards: check for trailing semi-colons. +# Check Python coding standards: check for uncommented trailing semi-colons. # Don't check too widely, there are third-party tools that fail this test as # well as scripts in this directory that output C code, and so fail the test. -egrep ';$' `find lang test -name '*.py'`> $t +egrep '^[^#]*;$' `find lang test -name '*.py'`> $t test -s $t && { echo 'trailing semi-colons in selected Python code:' cat $t -- cgit v1.2.1 From bc2c716ce59da0847ba7dd26d97d0f39c7279cdf Mon Sep 17 00:00:00 2001 From: David Hows Date: Wed, 7 Dec 2016 15:31:16 +1100 Subject: Cut WiredTiger WT-2.9.0 release --- dist/package/wiredtiger.spec | 2 +- dist/s_string.ok | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+), 1 deletion(-) (limited to 'dist') diff --git a/dist/package/wiredtiger.spec b/dist/package/wiredtiger.spec index 365c330d86a..1376bac9ef6 100644 --- a/dist/package/wiredtiger.spec +++ b/dist/package/wiredtiger.spec @@ -1,5 +1,5 @@ Name: wiredtiger -Version: 2.8.1 +Version: 2.9.0 Release: 1%{?dist} Summary: WiredTiger data storage engine diff --git a/dist/s_string.ok b/dist/s_string.ok index d19c05e802b..2d7fe2706df 100644 --- a/dist/s_string.ok +++ b/dist/s_string.ok @@ -38,6 +38,7 @@ BTREE BUF BZ Barack +BerkeleyDB Bitfield Bitwise Brueckner @@ -88,6 +89,7 @@ DNE DOI DONTNEED DUPLICATEV +DataSet DbCursor DbEnv Decrement @@ -126,6 +128,7 @@ FNV FORALL FOREACH FS +FTRUNCATE FULLFSYNC Facebook FindClose @@ -167,6 +170,7 @@ INITIALIZER INMEM INSN INTL +INULL ISA ITEMs ITER @@ -269,6 +273,7 @@ PRIu PRNG PTHREAD PTR +PackInputStream Pandis Phong PlatformSDK @@ -300,6 +305,7 @@ Readonly Rebalance RedHat Redistributions +Refactor Resize RocksDB SIMD @@ -397,14 +403,18 @@ WiredTigerPreplog WiredTigerTmplog WiredTigerTxn WithSeeds +Wpedantic WriteFile Wuninitialized Wunused XP +Xcode +Xcode/ Yann ZSTD Zlib Zlib's +Zstandard Zstd Zstd's abcdef @@ -428,6 +438,7 @@ argc args argv asm +aspell assertfmt async asyncopp @@ -547,6 +558,7 @@ create's createCStream crypto cryptobad +csuite csv ctime ctype @@ -598,6 +610,7 @@ dequeue dequeued der dereference +dereferenced desc designator dest @@ -610,6 +623,7 @@ difftime dir dirlist disjunction +disjunctions dlclose dlh dll @@ -633,6 +647,7 @@ dumpcmp dumpfile dup eg +egrep emp encodings encryptor @@ -723,6 +738,7 @@ gettime gettimeofday getv github +gitignore gobare goesc gostring @@ -834,6 +850,7 @@ libdatasource libs libtool libwiredtiger +linkers llll llu loadtext @@ -935,6 +952,7 @@ nowait nset nsnap nul +nullptr nuls numSymbols numbare @@ -948,6 +966,7 @@ oo opcode opendir openfile +oplog optimizations optype ori @@ -969,6 +988,7 @@ pclose pcpu perf pfx +pluggable popen poptable popthreads @@ -1117,6 +1137,7 @@ subtree sunique superset sw +sx sy sys sz @@ -1225,6 +1246,7 @@ walk's warmup wb wcursor +whitespace wiredTiger wiredtiger workFactor @@ -1238,6 +1260,7 @@ ws wtbench wti wtperf +wtperf's wts wtstats xF @@ -1250,6 +1273,7 @@ zf zfree zlib zlib's +zseries zstd zstd's zu -- cgit v1.2.1 From 5ebe8b7531a39ecadde60f4bad34493f41c805e9 Mon Sep 17 00:00:00 2001 From: David Hows Date: Wed, 7 Dec 2016 16:07:22 +1100 Subject: Bump release version on develop to 2.9.1 --- dist/package/wiredtiger.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'dist') diff --git a/dist/package/wiredtiger.spec b/dist/package/wiredtiger.spec index 1376bac9ef6..ca88f76b06b 100644 --- a/dist/package/wiredtiger.spec +++ b/dist/package/wiredtiger.spec @@ -1,5 +1,5 @@ Name: wiredtiger -Version: 2.9.0 +Version: 2.9.1 Release: 1%{?dist} Summary: WiredTiger data storage engine -- cgit v1.2.1 From 1b812c0aa2fbab91e289642b0a8d02d65c879438 Mon Sep 17 00:00:00 2001 From: Keith Bostic Date: Thu, 8 Dec 2016 09:42:31 -0500 Subject: WT-3064 minor tree cleanups: .gitignore, NEWS misspelling (#3185) --- dist/s_string.ok | 1 + 1 file changed, 1 insertion(+) (limited to 'dist') diff --git a/dist/s_string.ok b/dist/s_string.ok index a56d78cf0d4..f2429237f21 100644 --- a/dist/s_string.ok +++ b/dist/s_string.ok @@ -159,6 +159,7 @@ HHHHLL HHHLL Hendrik HyperLevelDB +ID's IEC IEEE IKEY -- cgit v1.2.1