diff options
author | Luke Chen <luke.chen@mongodb.com> | 2018-02-26 17:13:06 +1100 |
---|---|---|
committer | Luke Chen <luke.chen@mongodb.com> | 2018-02-26 17:14:42 +1100 |
commit | b5b3fcc4c38cd289e9c0d3192946ed715d7e576f (patch) | |
tree | 4b3f175a28dd1fd7bde51a1eeaa57d132ad3b54a /src/third_party/wiredtiger/examples | |
parent | 0a0597248fa8234414c07ec6cd5a4fef51169148 (diff) | |
download | mongo-b5b3fcc4c38cd289e9c0d3192946ed715d7e576f.tar.gz |
Import wiredtiger: 8f5b5544d8e2ca861956a255cf079b3ad34ca0f3 from branch mongodb-3.8
ref: a6e72378a6..8f5b5544d8
for: 3.7.3
WT-1228 Improve performance of WT_SESSION::open_cursor
WT-3805 Avoid reading lookaside pages in truncate fast path
WT-3829 WiredTiger metadata can be logically inconsistent.
WT-3848 Enhance new prepare transaction API to enforce post conditions
WT-3850 Implement WT_SESSSION::prepare_transaction
WT-3867 Bi-weekly WT codebase lint
WT-3901 Corruption of operation tracking log files
WT-3904 Reconsider error path in log server thread
WT-3905 Save the timestamp used for a checkpoint
WT-3912 fast-delete pages should re-instantiate the delete transaction's timestamp.
WT-3923 __wt_txn_context_prepare_check() requires API initialization
WT-3925 Fix test format operation selection code
WT-3926 Allow read_timestamp to be set after begin_transaction
WT-3927 LSM truncate operations are too slow.
WT-3932 WiredTiger memory allocation failure in js_test
WT-3933 test/format failure illegal WT_REF.state rolling back deleted page
Diffstat (limited to 'src/third_party/wiredtiger/examples')
-rw-r--r-- | src/third_party/wiredtiger/examples/c/ex_all.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/third_party/wiredtiger/examples/c/ex_all.c b/src/third_party/wiredtiger/examples/c/ex_all.c index 8e40b9f0b6c..62269b91263 100644 --- a/src/third_party/wiredtiger/examples/c/ex_all.c +++ b/src/third_party/wiredtiger/examples/c/ex_all.c @@ -900,6 +900,8 @@ transaction_ops(WT_SESSION *session_arg) error_check(session->commit_transaction(session, NULL)); /*! [transaction isolation] */ +#ifdef HAVE_TIMESTAMPS + { /*! [transaction prepare] */ /* * Prepare a transaction which guarantees a subsequent commit will @@ -911,9 +913,13 @@ transaction_ops(WT_SESSION *session_arg) error_check(session->begin_transaction(session, NULL)); cursor->set_key(cursor, "key"); cursor->set_value(cursor, "value"); - session->prepare_transaction(session, "prepare_timestamp=2a"); - error_check(session->commit_transaction(session, NULL)); + error_check(session->prepare_transaction( + session, "prepare_timestamp=2a")); + error_check(session->commit_transaction( + session, "commit_timestamp=2b")); /*! [transaction prepare] */ + } +#endif /*! [session isolation configuration] */ /* Open a session configured for read-uncommitted isolation. */ |