Debian Codegraph @

test/tcl/TESTS

raw
1 # Automatically built by dist/s_test; may require local editing.
2
3
4 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
5 backup
6 Test of hotbackup functionality.
7
8 Do all the of the following tests with and without
9 the -c (checkpoint) option; and with and without the
10 transactional bulk loading optimization. Make sure
11 that -c and -d (data_dir) are not allowed together.
12
13 (1) Test that plain and simple hotbackup works.
14 (2) Test with -data_dir (-d).
15 (3) Test updating an existing hot backup (-u).
16 (4) Test with absolute path.
17 (5) Test with DB_CONFIG, setting log_dir (-l)
18 and data_dir (-d).
19 (6) DB_CONFIG and update.
20 (7) Repeat hot backup (non-update) with DB_CONFIG,
21 DB_CONFIG (-D) and existing directories.
22
23 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
24 bigfile001
25 Create a database greater than 4 GB in size. Close, verify.
26 Grow the database somewhat. Close, reverify. Lather, rinse,
27 repeat. Since it will not work on all systems, this test is
28 not run by default.
29
30 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
31 bigfile002
32 This one should be faster and not require so much disk space,
33 although it doesn't test as extensively. Create an mpool file
34 with 1K pages. Dirty page 6000000. Sync.
35
36 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
37 Cold-boot a 4-site group. The first two sites start quickly and
38 initiate an election. The other two sites don't join the election until
39 the middle of the long full election timeout period. It's important that
40 the number of sites that start immediately be a sub-majority, because
41 that's the case that used to have a bug in it [#18456].
42
43 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
44 dbm
45 Historic DBM interface test. Use the first 1000 entries from the
46 dictionary. Insert each with self as key and data; retrieve each.
47 After all are entered, retrieve all; compare output to original.
48 Then reopen the file, re-retrieve everything. Finally, delete
49 everything.
50
51 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
52 db_reptest
53 Wrapper to configure and run the db_reptest program.
54
55 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
56 dead001
57 Use two different configurations to test deadlock detection among a
58 variable number of processes. One configuration has the processes
59 deadlocked in a ring. The other has the processes all deadlocked on
60 a single resource.
61
62 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
63 dead002
64 Same test as dead001, but use "detect on every collision" instead
65 of separate deadlock detector.
66
67 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
68 dead003
69
70 Same test as dead002, but explicitly specify DB_LOCK_OLDEST and
71 DB_LOCK_YOUNGEST. Verify the correct lock was aborted/granted.
72
73 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
74 dead006
75 use timeouts rather than the normal dd algorithm.
76
77 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
78 dead007
79 Tests for locker and txn id wraparound.
80
81 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
82 dead008
83 Run dead001 deadlock test using priorities
84
85 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
86 dead009
87 Run dead002 deadlock test using priorities
88
89 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
90 dead010
91
92 Same test as dead003, except the actual youngest and oldest will have
93 higher priorities. Verify that the oldest/youngest of the lower
94 priority lockers gets killed. Doesn't apply to 2 procs.
95
96 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
97 dead011
98 Test out the minlocks, maxlocks, and minwrites options
99 to the deadlock detector when priorities are used.
100
101 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
102 env001
103 Test of env remove interface (formerly env_remove).
104
105 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
106 env002
107 Test of DB_LOG_DIR and env name resolution.
108 With an environment path specified using -home, and then again
109 with it specified by the environment variable DB_HOME:
110 1) Make sure that the set_lg_dir option is respected
111 a) as a relative pathname.
112 b) as an absolute pathname.
113 2) Make sure that the DB_LOG_DIR db_config argument is respected,
114 again as relative and absolute pathnames.
115 3) Make sure that if -both- db_config and a file are present,
116 only the file is respected (see doc/env/naming.html).
117
118 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
119 env003
120 Test DB_TMP_DIR and env name resolution
121 With an environment path specified using -home, and then again
122 with it specified by the environment variable DB_HOME:
123 1) Make sure that the DB_TMP_DIR config file option is respected
124 a) as a relative pathname.
125 b) as an absolute pathname.
126 2) Make sure that the -tmp_dir config option is respected,
127 again as relative and absolute pathnames.
128 3) Make sure that if -both- -tmp_dir and a file are present,
129 only the file is respected (see doc/env/naming.html).
130
131 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
132 env004
133 Test multiple data directories. Do a bunch of different opens
134 to make sure that the files are detected in different directories.
135
136 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
137 env005
138 Test that using subsystems without initializing them correctly
139 returns an error. Cannot test mpool, because it is assumed in
140 the Tcl code.
141
142 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
143 env006
144 Make sure that all the utilities exist and run.
145 Test that db_load -r options don't blow up.
146
147 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
148 env007
149 Test DB_CONFIG config file options for berkdb env.
150 1) Make sure command line option is respected
151 2) Make sure that config file option is respected
152 3) Make sure that if -both- DB_CONFIG and the set_<whatever>
153 method is used, only the file is respected.
154 Then test all known config options.
155 Also test config options on berkdb open. This isn't
156 really env testing, but there's no better place to put it.
157
158 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
159 env008
160 Test environments and subdirectories.
161
162 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
163 env009
164 Test calls to all the various stat functions. We have several
165 sprinkled throughout the test suite, but this will ensure that
166 we run all of them at least once.
167
168 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
169 env010
170 Run recovery in an empty directory, and then make sure we can still
171 create a database in that directory.
172
173 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
174 env011
175 Run with region overwrite flag.
176
177 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
178 env012
179 Test DB_REGISTER.
180
181 DB_REGISTER will fail on systems without fcntl. If it
182 fails, make sure we got the expected DB_OPNOTSUP return.
183
184 Then, the real tests:
185 For each test, we start a process that opens an env with -register.
186
187 1. Verify that a 2nd process can enter the existing env with -register.
188
189 2. Kill the 1st process, and verify that the 2nd process can enter
190 with "-register -recover".
191
192 3. Kill the 1st process, and verify that the 2nd process cannot
193 enter with just "-register".
194
195 4. While the 1st process is still running, a 2nd process enters
196 with "-register". Kill the 1st process. Verify that a 3rd process
197 can enter with "-register -recover". Verify that the 3rd process,
198 entering, causes process 2 to fail with the message DB_RUNRECOVERY.
199
200 5. We had a bug where recovery was always run with -register
201 if there were empty slots in the process registry file. Verify
202 that recovery doesn't automatically run if there is an empty slot.
203
204 6. Verify process cannot connect when specifying -failchk and an
205 isalive function has not been declared.
206
207 7. Verify that a 2nd process can enter the existing env with -register
208 and -failchk and having specified an isalive function
209
210 8. Kill the 1st process, and verify that the 2nd process can enter
211 with "-register -failchk -recover"
212
213 9. 2nd process enters with "-register -failchk". Kill the 1st process.
214 2nd process may get blocked on a mutex held by process one. Verify
215 3rd process can enter with "-register -recover -failchk". 3rd process
216 should run failchk, clear out open txn/log from process 1. It will
217 enter env without need for any additional recovery. We look for
218 "Freeing log information .." sentence in the log for 3rd process as
219 an indication that failchk ran. If DB_RUNRECOVERY were returned
220 instead it would mean failchk could not recover.
221
222 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
223 env013
224 Test of basic functionality of fileid_reset.
225
226 Create a database in an env. Copy it to a new file within
227 the same env. Reset the file id and make sure it has changed.
228
229 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
230 env014
231
232 Make sure that attempts to open an environment with
233 incompatible flags (e.g. replication without transactions)
234 fail with the appropriate messages.
235
236 A new thread of control joining an env automatically
237 initializes the same subsystems as the original env.
238 Make sure that the attempt to change subsystems when
239 joining an env fails with the appropriate messages.
240
241 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
242 env015
243 Rename the underlying directory of an env, make sure everything
244 still works. Test runs with regular named databases and with
245 in-memory named databases.
246
247 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
248 env016
249 Replication settings and DB_CONFIG
250
251 Create a DB_CONFIG for various replication settings. Use
252 rep_stat or getter functions to verify they're set correctly.
253
254 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
255 env017
256 Check documented "stat" fields against the fields
257 returned by the "stat" functions. Make sure they
258 match, and that none are missing.
259 These are the stat functions we test:
260 env log_stat
261 env lock_stat
262 env txn_stat
263 env mutex_stat
264 env rep_stat
265 env repmgr_stat
266 env mpool_stat
267 db stat
268 seq stat
269 db compact_stat
270
271 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
272 env018
273 Test getters when joining an env. When a second handle is
274 opened on an existing env, get_open_flags needs to return
275 the correct flags to the second handle so it knows what sort
276 of environment it's just joined.
277
278 For several different flags to env_open, open an env. Open
279 a second handle on the same env, get_open_flags and verify
280 the flag is returned.
281
282 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
283 env019
284 Test that stats are correctly set and reported when
285 an env is accessed from a second process.
286
287 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
288 env020
289 Check if the output information for stat_print is expected.
290 These are the stat_print functions we test:
291 env stat_print
292 env lock_stat_print
293 env log_stat_print
294 env mpool_stat_print
295 env mutex_stat_print
296 env rep_stat_print
297 env repmgr_stat_print
298 env txn_stat_print
299 db stat_print
300 seq stat_print
301
302 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
303 env021
304 Test the operations on a transaction in a CDS environment.
305 These are the operations we test:
306 $txn abort
307 $txn commit
308 $txn id
309 $txn prepare
310 $txn setname name
311 $txn getname
312 $txn discard
313 $txn set_timeout
314 In these operations, we only support the following:
315 $txn id
316 $txn commit
317
318 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
319 fop001.tcl
320 Test two file system operations combined in one transaction.
321
322 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
323 fop002.tcl
324 Test file system operations in the presence of bad permissions.
325
326 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
327 fop003
328
329 Test behavior of create and truncate for compatibility
330 with sendmail.
331 1. DB_TRUNCATE is not allowed with locking or transactions.
332 2. Can -create into zero-length existing file.
333 3. Can -create into non-zero-length existing file if and
334 only if DB_TRUNCATE is specified.
335
336 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
337 fop004
338 Test of DB->rename(). (formerly test075)
339 Test that files can be renamed from one directory to another.
340 Test that files can be renamed using absolute or relative
341 pathnames.
342
343 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
344 fop005
345 Test of DB->remove()
346 Formerly test080.
347 Test use of dbremove with and without envs, with absolute
348 and relative paths, and with subdirectories.
349
350 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
351 fop006
352 Test file system operations in multiple simultaneous
353 transactions. Start one transaction, do a file operation.
354 Start a second transaction, do a file operation. Abort
355 or commit txn1, then abort or commit txn2, and check for
356 appropriate outcome.
357
358 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
359 fop007
360 Test file system operations on named in-memory databases.
361 Combine two ops in one transaction.
362
363 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
364 fop008
365 Test file system operations on named in-memory databases.
366 Combine two ops in one transaction.
367
368 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
369 fop009
370 Test file system operations in child transactions.
371 Combine two ops in one child transaction.
372
373 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
374 fop010
375 Test file system operations in child transactions.
376 Two ops, each in its own child txn.
377
378 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
379 fop011
380 Test file system operations in child transactions.
381 Combine two ops in one child transaction, with in-emory
382 databases.
383
384 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
385 fop012
386 Test file system operations in child transactions.
387 Two ops, each in its own child txn, with in-memory dbs.
388
389 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
390 jointest
391 Test duplicate assisted joins. Executes 1, 2, 3 and 4-way joins
392 with differing index orders and selectivity.
393
394 We'll test 2-way, 3-way, and 4-way joins and figure that if those
395 work, everything else does as well. We'll create test databases
396 called join1.db, join2.db, join3.db, and join4.db. The number on
397 the database describes the duplication -- duplicates are of the
398 form 0, N, 2N, 3N, ... where N is the number of the database.
399 Primary.db is the primary database, and null.db is the database
400 that has no matching duplicates.
401
402 We should test this on all btrees, all hash, and a combination thereof
403
404 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
405 lock001
406 Make sure that the basic lock tests work. Do some simple gets
407 and puts for a single locker.
408
409 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
410 lock002
411 Exercise basic multi-process aspects of lock.
412
413 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
414 lock003
415 Exercise multi-process aspects of lock. Generate a bunch of parallel
416 testers that try to randomly obtain locks; make sure that the locks
417 correctly protect corresponding objects.
418
419 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
420 lock004
421 Test locker ids wraping around.
422
423 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
424 lock005
425 Check that page locks are being released properly.
426
427 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
428 lock006
429 Test lock_vec interface. We do all the same things that
430 lock001 does, using lock_vec instead of lock_get and lock_put,
431 plus a few more things like lock-coupling.
432 1. Get and release one at a time.
433 2. Release with put_obj (all locks for a given locker/obj).
434 3. Release with put_all (all locks for a given locker).
435 Regularly check lock_stat to verify all locks have been
436 released.
437
438 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
439 log001
440 Read/write log records.
441 Test with and without fixed-length, in-memory logging,
442 and encryption.
443
444 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
445 log002
446 Tests multiple logs
447 Log truncation
448 LSN comparison and file functionality.
449
450 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
451 log003
452 Verify that log_flush is flushing records correctly.
453
454 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
455 log004
456 Make sure that if we do PREVs on a log, but the beginning of the
457 log has been truncated, we do the right thing.
458
459 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
460 log005
461 Check that log file sizes can change on the fly.
462
463 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
464 log006
465 Test log file auto-remove.
466 Test normal operation.
467 Test a long-lived txn.
468 Test log_archive flags.
469 Test db_archive flags.
470 Test turning on later.
471 Test setting via DB_CONFIG.
472
473 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
474 log007
475 Test of in-memory logging bugs. [#11505]
476
477 Test db_printlog with in-memory logs.
478
479 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
480 log008
481 Test what happens if a txn_ckp record falls into a
482 different log file than the DBREG_CKP records generated
483 by the same checkpoint.
484
485 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
486 log009
487 Test of logging and getting log file version information.
488 Each time we cross a log file boundary verify we can
489 get the version via the log cursorlag.
490 Do this both forward and backward.
491
492 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
493 memp001
494 Randomly updates pages.
495
496 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
497 memp002
498 Tests multiple processes accessing and modifying the same files.
499
500 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
501 memp003
502 Test reader-only/writer process combinations; we use the access methods
503 for testing.
504
505 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
506 memp004
507 Test that small read-only databases are mapped into memory.
508
509 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
510 memp005
511 Make sure that db pagesize does not interfere with mpool pagesize.
512
513 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
514 mut001
515 Exercise the mutex API.
516
517 Allocate, lock, unlock, and free a bunch of mutexes.
518 Set basic configuration options and check mutex_stat and
519 the mutex getters for the correct values.
520
521 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
522 mut002
523 Two-process mutex test.
524
525 Allocate and lock a self-blocking mutex. Start another process.
526 Try to lock the mutex again -- it will block.
527 Unlock the mutex from the other process, and the blocked
528 lock should be obtained. Clean up.
529 Do another test with a "-process-only" mutex. The second
530 process should not be able to unlock the mutex.
531
532 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
533 mut003
534 Try doing mutex operations out of order. Make sure
535 we get appropriate errors.
536
537 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
538 plat001
539
540 Test of portability of sequences.
541
542 Create and dump a database containing sequences. Save the dump.
543 This test is used in conjunction with the upgrade tests, which
544 will compare the saved dump to a locally created dump.
545
546 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
547 recd001
548 Per-operation recovery tests for non-duplicate, non-split
549 messages. Makes sure that we exercise redo, undo, and do-nothing
550 condition. Any test that appears with the message (change state)
551 indicates that we've already run the particular test, but we are
552 running it again so that we can change the state of the data base
553 to prepare for the next test (this applies to all other recovery
554 tests as well).
555
556 These are the most basic recovery tests. We do individual recovery
557 tests for each operation in the access method interface. First we
558 create a file and capture the state of the database (i.e., we copy
559 it. Then we run a transaction containing a single operation. In
560 one test, we abort the transaction and compare the outcome to the
561 original copy of the file. In the second test, we restore the
562 original copy of the database and then run recovery and compare
563 this against the actual database.
564
565 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
566 recd002
567 Split recovery tests. For every known split log message, makes sure
568 that we exercise redo, undo, and do-nothing condition.
569
570 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
571 recd003
572 Duplicate recovery tests. For every known duplicate log message,
573 makes sure that we exercise redo, undo, and do-nothing condition.
574
575 Test all the duplicate log messages and recovery operations. We make
576 sure that we exercise all possible recovery actions: redo, undo, undo
577 but no fix necessary and redo but no fix necessary.
578
579 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
580 recd004
581 Big key test where big key gets elevated to internal page.
582
583 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
584 recd005
585 Verify reuse of file ids works on catastrophic recovery.
586
587 Make sure that we can do catastrophic recovery even if we open
588 files using the same log file id.
589
590 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
591 recd006
592 Nested transactions.
593
594 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
595 recd007
596 File create/delete tests.
597
598 This is a recovery test for create/delete of databases. We have
599 hooks in the database so that we can abort the process at various
600 points and make sure that the transaction doesn't commit. We
601 then need to recover and make sure the file is correctly existing
602 or not, as the case may be.
603
604 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
605 recd008
606 Test deeply nested transactions and many-child transactions.
607
608 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
609 recd009
610 Verify record numbering across split/reverse splits and recovery.
611
612 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
613 recd010
614 Test stability of btree duplicates across btree off-page dup splits
615 and reverse splits and across recovery.
616
617 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
618 recd011
619 Verify that recovery to a specific timestamp works.
620
621 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
622 recd012
623 Test of log file ID management. [#2288]
624 Test recovery handling of file opens and closes.
625
626 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
627 recd013
628 Test of cursor adjustment on child transaction aborts. [#2373]
629
630 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
631 recd014
632 This is a recovery test for create/delete of queue extents. We
633 then need to recover and make sure the file is correctly existing
634 or not, as the case may be.
635
636 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
637 recd015
638 This is a recovery test for testing lots of prepared txns.
639 This test is to force the use of txn_recover to call with the
640 DB_FIRST flag and then DB_NEXT.
641
642 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
643 recd016
644 Test recovery after checksum error.
645
646 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
647 recd017
648 Test recovery and security. This is basically a watered
649 down version of recd001 just to verify that encrypted environments
650 can be recovered.
651
652 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
653 recd018
654 Test recover of closely interspersed checkpoints and commits.
655
656 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
657 recd019
658 Test txn id wrap-around and recovery.
659
660 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
661 recd020
662 Test creation of intermediate directories -- an
663 undocumented, UNIX-only feature.
664
665 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
666 recd021
667 Test of failed opens in recovery.
668
669 If a file was deleted through the file system (and not
670 within Berkeley DB), an error message should appear.
671 Test for regular files and subdbs.
672
673 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
674 recd022
675 Test that pages allocated by an aborted subtransaction
676 within an aborted prepared parent transaction are returned
677 to the free list after recovery. This exercises
678 __db_pg_prepare in systems without FTRUNCATE. [#7403]
679
680 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
681 recd023
682 Test recover of reverse split.
683
684 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
685 recd024
686 Test recovery of streaming partial insert operations. These are
687 operations that do multiple partial puts that append to an existing
688 data item (as long as the data item is on an overflow page).
689 The interesting cases are:
690 * Simple streaming operations
691 * Operations that cause the overflow item to flow onto another page.
692
693
694 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
695 recd025
696 Basic tests for transaction bulk loading and recovery.
697 In particular, verify that the tricky hot backup protocol works.
698
699 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
700 rep001
701 Replication rename and forced-upgrade test.
702
703 Run rep_test in a replicated master environment.
704 Verify that the database on the client is correct.
705 Next, remove the database, close the master, upgrade the
706 client, reopen the master, and make sure the new master can
707 correctly run rep_test and propagate it in the other direction.
708
709 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
710 rep002
711 Basic replication election test.
712
713 Run a modified version of test001 in a replicated master
714 environment; hold an election among a group of clients to
715 make sure they select a proper master from amongst themselves,
716 in various scenarios.
717
718 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
719 rep003
720 Repeated shutdown/restart replication test
721
722 Run a quick put test in a replicated master environment;
723 start up, shut down, and restart client processes, with
724 and without recovery. To ensure that environment state
725 is transient, use DB_PRIVATE.
726
727 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
728 rep005
729 Replication election test with error handling.
730
731 Run rep_test in a replicated master environment;
732 hold an election among a group of clients to make sure they select
733 a proper master from amongst themselves, forcing errors at various
734 locations in the election path.
735
736 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
737 rep006
738 Replication and non-rep env handles.
739
740 Run a modified version of test001 in a replicated master
741 environment; verify that the database on the client is correct.
742 Next, create a non-rep env handle to the master env.
743 Attempt to open the database r/w to force error.
744
745 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
746 rep007
747 Replication and bad LSNs
748
749 Run rep_test in a replicated master env.
750 Close the client. Make additional changes to master.
751 Close the master. Open the client as the new master.
752 Make several different changes. Open the old master as
753 the client. Verify periodically that contents are correct.
754 This test is not appropriate for named in-memory db testing
755 because the databases are lost when both envs are closed.
756
757 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
758 rep008
759 Replication, back up and synchronizing
760
761 Run a modified version of test001 in a replicated master
762 environment.
763 Close master and client.
764 Copy the master log to the client.
765 Clean the master.
766 Reopen the master and client.
767
768 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
769 rep009
770 Replication and DUPMASTERs
771 Run test001 in a replicated environment.
772
773 Declare one of the clients to also be a master.
774 Close a client, clean it and then declare it a 2nd master.
775
776 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
777 rep010
778 Replication and ISPERM
779
780 With consecutive message processing, make sure every
781 DB_REP_PERMANENT is responded to with an ISPERM when
782 processed. With gaps in the processing, make sure
783 every DB_REP_PERMANENT is responded to with an ISPERM
784 or a NOTPERM. Verify in both cases that the LSN returned
785 with ISPERM is found in the log.
786
787 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
788 rep011
789 Replication: test open handle across an upgrade.
790
791 Open and close test database in master environment.
792 Update the client. Check client, and leave the handle
793 to the client open as we close the masterenv and upgrade
794 the client to master. Reopen the old master as client
795 and catch up. Test that we can still do a put to the
796 handle we created on the master while it was still a
797 client, and then make sure that the change can be
798 propagated back to the new client.
799
800 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
801 rep012
802 Replication and dead DB handles.
803
804 Run a modified version of test001 in a replicated master env.
805 Run in replicated environment with secondary indices too.
806 Make additional changes to master, but not to the client.
807 Downgrade the master and upgrade the client with open db handles.
808 Verify that the roll back on clients gives dead db handles.
809
810 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
811 rep013
812 Replication and swapping master/clients with open dbs.
813
814 Run a modified version of test001 in a replicated master env.
815 Make additional changes to master, but not to the client.
816 Swap master and client.
817 Verify that the roll back on clients gives dead db handles.
818 Rerun the test, turning on client-to-client synchronization.
819 Swap and verify several times.
820
821 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
822 rep014
823 Replication and multiple replication handles.
824 Test multiple client handles, opening and closing to
825 make sure we get the right openfiles.
826
827 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
828 rep015
829 Locking across multiple pages with replication.
830
831 Open master and client with small pagesize and
832 generate more than one page and generate off-page
833 dups on the first page (second key) and last page
834 (next-to-last key).
835 Within a single transaction, for each database, open
836 2 cursors and delete the first and last entries (this
837 exercises locks on regular pages). Intermittently
838 update client during the process.
839 Within a single transaction, for each database, open
840 2 cursors. Walk to the off-page dups and delete one
841 from each end (this exercises locks on off-page dups).
842 Intermittently update client.
843
844 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
845 rep016
846 Replication election test with varying required nvotes.
847
848 Run a modified version of test001 in a replicated master environment;
849 hold an election among a group of clients to make sure they select
850 the master with varying required participants.
851
852 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
853 rep017
854 Concurrency with checkpoints.
855
856 Verify that we achieve concurrency in the presence of checkpoints.
857 Here are the checks that we wish to make:
858 While dbenv1 is handling the checkpoint record:
859 Subsequent in-order log records are accepted.
860 Accepted PERM log records get NOTPERM
861 A subsequent checkpoint gets NOTPERM
862 After checkpoint completes, next txn returns PERM
863
864 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
865 rep018
866 Replication with dbremove.
867
868 Verify that the attempt to remove a database file
869 on the master hangs while another process holds a
870 handle on the client.
871
872
873 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
874 rep019
875 Replication and multiple clients at same LSN.
876 Have several clients at the same LSN. Run recovery at
877 different times. Declare a client master and after sync-up
878 verify all client logs are identical.
879
880 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
881 rep020
882 Replication elections - test election generation numbers.
883
884
885 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
886 rep021
887 Replication and multiple environments.
888 Run similar tests in separate environments, making sure
889 that some data overlaps. Then, "move" one client env
890 from one replication group to another and make sure that
891 we do not get divergent logs. We either match the first
892 record and end up with identical logs or we get an error.
893 Verify all client logs are identical if successful.
894
895 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
896 rep022
897 Replication elections - test election generation numbers
898 during simulated network partition.
899
900
901 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
902 rep023
903 Replication using two master handles.
904
905 Open two handles on one master env. Create two
906 databases, one through each master handle. Process
907 all messages through the first master handle. Make
908 sure changes made through both handles are picked
909 up properly.
910
911 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
912 rep024
913 Replication page allocation / verify test
914
915 Start a master (site 1) and a client (site 2). Master
916 closes (simulating a crash). Site 2 becomes the master
917 and site 1 comes back up as a client. Verify database.
918
919 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
920 rep025
921 Test of DB_REP_JOIN_FAILURE.
922
923 One master, one client.
924 Generate several log files.
925 Remove old master log files.
926 Delete client files and restart client.
927 Put one more record to the master. At the next
928 processing of messages, the client should get JOIN_FAILURE.
929 Recover with a hot failover.
930
931 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
932 rep026
933 Replication elections - simulate a crash after sending
934 a vote.
935
936 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
937 rep027
938 Replication and secondary indexes.
939
940 Set up a secondary index on the master and make sure
941 it can be accessed from the client.
942
943 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
944 rep028
945 Replication and non-rep env handles. (Also see rep006.)
946
947 Open second non-rep env on client, and create a db
948 through this handle. Open the db on master and put
949 some data. Check whether the non-rep handle keeps
950 working. Also check if opening the client database
951 in the non-rep env writes log records.
952
953 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
954 rep029
955 Test of internal initialization.
956
957 One master, one client.
958 Generate several log files.
959 Remove old master log files.
960 Delete client files and restart client.
961 Put one more record to the master.
962
963 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
964 rep030
965 Test of internal initialization multiple files and pagesizes.
966 Hold some databases open on master.
967
968 One master, one client using a data_dir for internal init.
969 Generate several log files.
970 Remove old master log files.
971 Delete client files and restart client.
972 Put one more record to the master.
973
974 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
975 rep031
976 Test of internal initialization and blocked operations.
977
978 One master, one client.
979 Put one more record to the master.
980 Test that internal initialization blocks:
981 log_archive, rename, remove, fileid_reset, lsn_reset.
982 Sleep 30+ seconds.
983 Test that blocked operations are now unblocked.
984
985 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
986 rep032
987 Test of log gap processing.
988
989 One master, one client.
990 Run rep_test.
991 Run rep_test without sending messages to client.
992 Make sure client missing the messages catches up properly.
993
994 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
995 rep033
996 Test of internal initialization with rename and remove of dbs.
997
998 One master, one client.
999 Generate several databases. Replicate to client.
1000 Do some renames and removes, both before and after
1001 closing the client.
1002
1003 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1004 rep034
1005 Test of STARTUPDONE notification.
1006
1007 STARTUPDONE can now be recognized without the need for new "live" log
1008 records from the master (under favorable conditions). The response to
1009 the ALL_REQ at the end of synchronization includes an end-of-log marker
1010 that now triggers it. However, the message containing that end marker
1011 could get lost, so live log records still serve as a back-up mechanism.
1012 The end marker may also be set under c2c sync, but only if the serving
1013 client has itself achieved STARTUPDONE.
1014
1015 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1016 rep035
1017 Test sync-up recovery in replication.
1018
1019 We need to fork off 3 child tclsh processes to operate
1020 on Site 3's (client always) home directory:
1021 Process 1 continually calls lock_detect.
1022 Process 2 continually calls txn_checkpoint.
1023 Process 3 continually calls memp_trickle.
1024 Process 4 continually calls log_archive.
1025 Sites 1 and 2 will continually swap being master
1026 (forcing site 3 to continually run sync-up recovery)
1027 New master performs 1 operation, replicates and downgrades.
1028
1029 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1030 rep036
1031 Multiple master processes writing to the database.
1032 One process handles all message processing.
1033
1034 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1035 rep037
1036 Test of internal initialization and page throttling.
1037
1038 One master, one client, force page throttling.
1039 Generate several log files.
1040 Remove old master log files.
1041 Delete client files and restart client.
1042 Put one more record to the master.
1043 Verify page throttling occurred.
1044
1045 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1046 rep038
1047 Test of internal initialization and ongoing master updates.
1048
1049 One master, one client.
1050 Generate several log files.
1051 Remove old master log files.
1052 Delete client files and restart client.
1053 Put more records on master while initialization is in progress.
1054
1055 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1056 rep039
1057 Test of interrupted internal initialization. The
1058 interruption is due to a changed master, or the client crashing,
1059 or both.
1060
1061 One master, two clients.
1062 Generate several log files. Remove old master log files.
1063 Restart client, optionally having "cleaned" client env dir. Either
1064 way, this has the effect of forcing an internal init.
1065 Interrupt the internal init.
1066 Vary the number of times we process messages to make sure
1067 the interruption occurs at varying stages of the first internal
1068 initialization.
1069
1070 Run for btree and queue only because of the number of permutations.
1071
1072
1073 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1074 rep040
1075 Test of racing rep_start and transactions.
1076
1077 One master, one client.
1078 Have master in the middle of a transaction.
1079 Call rep_start to make master a client.
1080 Commit the transaction.
1081 Call rep_start to make master the master again.
1082
1083 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1084 rep041
1085 Turn replication on and off at run-time.
1086
1087 Start a master with replication OFF (noop transport function).
1088 Run rep_test to advance log files and archive.
1089 Start up client; change master to working transport function.
1090 Now replication is ON.
1091 Do more ops, make sure client is up to date.
1092 Close client, turn replication OFF on master, do more ops.
1093 Repeat from point A.
1094
1095 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1096 rep042
1097 Concurrency with updates.
1098
1099 Verify racing role changes and updates don't result in
1100 pages with LSN 0,1. Set up an environment that is master.
1101 Spawn child process that does a delete, but using the
1102 $env check so that it sleeps in the middle of the call.
1103 Master downgrades and then sleeps as a client so that
1104 child will run. Verify child does not succeed (should
1105 get read-only error) due to role change in the middle of
1106 its call.
1107
1108 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1109 rep043
1110
1111 Constant writes during upgrade/downgrade.
1112
1113 Three envs take turns being master. Each env
1114 has a child process which does writes all the
1115 time. They will succeed when that env is master
1116 and fail when it is not.
1117
1118 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1119 rep044
1120
1121 Test rollbacks with open file ids.
1122
1123 We have one master with two handles and one client.
1124 Each time through the main loop, we open a db, write
1125 to the db, and close the db. Each one of these actions
1126 is propagated to the client, or a roll back is forced
1127 by swapping masters.
1128
1129 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1130 rep045
1131
1132 Replication with versions.
1133
1134 Mimic an application where a database is set up in the
1135 background and then put into a replication group for use.
1136 The "version database" identifies the current live
1137 version, the database against which queries are made.
1138 For example, the version database might say the current
1139 version is 3, and queries would then be sent to db.3.
1140 Version 4 is prepared for use while version 3 is in use.
1141 When version 4 is complete, the version database is updated
1142 to point to version 4 so queries can be directed there.
1143
1144 This test has a master and two clients. One client swaps
1145 roles with the master, and the other client runs constantly
1146 in another process.
1147
1148 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1149 rep046
1150 Replication and basic bulk transfer.
1151 Set bulk transfer replication option.
1152 Run long txns on master and then commit. Process on client
1153 and verify contents. Run a very long txn so that logging
1154 must send the log. Process and verify on client.
1155
1156 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1157 rep047
1158 Replication and log gap bulk transfers.
1159 Set bulk transfer replication option.
1160 Run test. Start a new client (to test ALL_REQ and bulk).
1161 Run small test again. Clear messages for 1 client.
1162 Run small test again to test LOG_REQ gap processing and bulk.
1163 Process and verify on clients.
1164
1165 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1166 rep048
1167 Replication and log gap bulk transfers.
1168 Have two master env handles. Turn bulk on in
1169 one (turns it on for both). Turn it off in the other.
1170 While toggling, send log records from both handles.
1171 Process message and verify master and client match.
1172
1173 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1174 rep049
1175 Replication and delay syncing clients - basic test.
1176
1177 Open and start up a master and two clients. Turn on delay sync
1178 in the delayed client. Change master, add data and process messages.
1179 Verify delayed client does not match. Make additional changes and
1180 update the delayted client. Verify all match.
1181 Add in a fresh delayed client to test delay of ALL_REQ.
1182 Process startup messages and verify freshc client has no database.
1183 Sync and verify fresh client matches.
1184
1185 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1186 rep050
1187 Replication and delay syncing clients - change master test.
1188
1189 Open and start up master and 4 clients. Turn on delay for 3 clients.
1190 Switch masters, add data and verify delayed clients are out of date.
1191 Make additional changes to master. And change masters again.
1192 Sync/update delayed client and verify. The 4th client is a brand
1193 new delayed client added in to test the non-verify path.
1194
1195 Then test two different things:
1196 1. Swap master again while clients are still delayed.
1197 2. Swap master again while sync is proceeding for one client.
1198
1199 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1200 rep051
1201 Test of compaction with replication.
1202
1203 Run rep_test in a replicated master environment.
1204 Delete a large number of entries and compact with -freespace.
1205 Propagate the changes to the client and make sure client and
1206 master match.
1207
1208 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1209 rep052
1210 Test of replication with NOWAIT.
1211
1212 One master, one client. After initializing
1213 everything normally, close client and let the
1214 master get ahead -- far enough that the master
1215 no longer has the client's last log file.
1216 Reopen the client and turn on NOWAIT.
1217 Process a few messages to get the client into
1218 recovery mode, and verify that lockout occurs
1219 on a txn API call (txn_begin) and an env API call.
1220 Process all the messages and verify that lockout
1221 is over.
1222
1223 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1224 rep053
1225 Replication and basic client-to-client synchronization.
1226
1227 Open and start up master and 1 client.
1228 Start up a second client later and verify it sync'ed from
1229 the original client, not the master.
1230
1231 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1232 rep054
1233 Test of internal initialization where a far-behind
1234 client takes over as master.
1235
1236 One master, two clients.
1237 Run rep_test and process.
1238 Close client 1.
1239 Run rep_test, opening new databases, and processing
1240 messages. Archive as we go so that log files get removed.
1241 Close master and reopen client 1 as master. Process messages.
1242 Verify that new master and client are in sync.
1243 Run rep_test again, adding data to one of the new
1244 named databases.
1245
1246 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1247 rep055
1248 Test of internal initialization and log archiving.
1249
1250 One master, one client.
1251 Generate several log files.
1252 Remove old master log files and generate several more.
1253 Get list of archivable files from db_archive and restart client.
1254 As client is in the middle of internal init, remove
1255 the log files returned earlier by db_archive.
1256
1257 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1258 rep058
1259
1260 Replication with early databases
1261
1262 Mimic an application where they create a database before
1263 calling rep_start, thus writing log records on a client
1264 before it is a client. Verify we cannot join repl group.
1265
1266 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1267 rep060
1268 Test of normally running clients and internal initialization.
1269 Have a client running normally, but slow/far behind the master.
1270 Then the master checkpoints and archives, causing the client
1271 to suddenly be thrown into internal init. This test tests
1272 that we clean up the old files/pages in mpool and dbreg.
1273 Also test same thing but the app holding an open dbp as well.
1274
1275 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1276 rep061
1277 Test of internal initialization multiple files and pagesizes
1278 with page gaps.
1279
1280 One master, one client.
1281 Generate several log files.
1282 Remove old master log files.
1283 Delete client files and restart client.
1284 Put one more record to the master.
1285 Force some page messages to get dropped.
1286
1287 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1288 rep062
1289 Test of internal initialization where client has a different
1290 kind of database than the master.
1291
1292 Create a master of one type, and let the client catch up.
1293 Close the client.
1294 Remove the database on the master, and create a new
1295 database of the same name but a different type.
1296 Run the master ahead far enough that internal initialization
1297 will be required on the reopen of the client.
1298 Reopen the client and verify.
1299
1300 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1301 rep063
1302 Replication election test with simulated different versions
1303 for each site. This tests that old sites with real priority
1304 trump ELECTABLE sites with zero priority even with greater LSNs.
1305 There is a special case in the code for testing that if the
1306 priority is <= 10, we simulate mixed versions for elections.
1307
1308 Run a rep_test in a replicated master environment and close;
1309 hold an election among a group of clients to make sure they select
1310 the master with varying LSNs and priorities.
1311
1312 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1313 rep064
1314 Replication rename and forced-upgrade test.
1315
1316 The test verifies that the client correctly
1317 (internally) closes files when upgrading to master.
1318 It does this by having the master have a database
1319 open, then crashing. The client upgrades to master,
1320 and attempts to remove the open database.
1321
1322 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1323 rep065
1324 Tests replication running with different versions.
1325 This capability is introduced with 4.5.
1326
1327 Start a replication group of 1 master and N sites, all
1328 running some historical version greater than or equal to 4.4.
1329 Take down a client and bring it up again running current.
1330 Run some upgrades, make sure everything works.
1331
1332 Each site runs the tcllib of its own version, but uses
1333 the current tcl code (e.g. test.tcl).
1334
1335 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1336 rep066
1337 Replication and dead log handles.
1338
1339 Run rep_test on master and a client.
1340 Simulate client crashes (master continues) until log 2.
1341 Open 2nd master env handle and put something in log and flush.
1342 Downgrade master, restart client as master.
1343 Run rep_test on newmaster until log 2.
1344 New master writes log records, newclient processes records
1345 and 2nd newclient env handle calls log_flush.
1346 New master commits, newclient processes and should succeed.
1347 Make sure 2nd handle detects the old log handle and doesn't
1348 write to a stale handle (if it does, the processing of the
1349 commit will fail).
1350
1351 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1352 rep067
1353 Full election timeout test.
1354
1355 Verify that elections use a separate "full election timeout" (if such
1356 configuration is in use) instead of the normal timeout, when the
1357 replication group is "cold-booted" (all sites starting with recovery).
1358
1359
1360 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1361 rep068
1362 Verify replication of dbreg operations does not hang clients.
1363 In a simple replication group, create a database with very
1364 little data. With DB_TXN_NOSYNC the database can be created
1365 at the client even though the log is not flushed. If we crash
1366 and restart, the application of the log starts over again, even
1367 though the database is still there. The application can open
1368 the database before replication tries to re-apply the create.
1369 This causes a hang as replication waits to be able to get a
1370 handle lock.
1371
1372 Run for btree only because access method shouldn't matter.
1373
1374
1375 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1376 rep069
1377 Test of internal initialization and elections.
1378
1379 If a client is in a recovery mode of any kind, it
1380 participates in elections at priority 0 so it can
1381 never be elected master.
1382
1383 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1384 rep070
1385 Test of startup_done condition with idle master.
1386
1387 Join a client to an existing master, and verify that
1388 the client detects startup_done even if the master
1389 does not execute any new transactions.
1390
1391 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1392 rep071
1393 Test of multiple simultaneous client env handles and
1394 upgrading/downgrading. Tests use of temp db handle
1395 internally.
1396
1397 Open a master and 2 handles to the same client env.
1398 Run rep_test.
1399 Close master and upgrade client to master using one env handle.
1400 Run rep_test again, and then downgrade back to client.
1401
1402 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1403 rep072
1404 Verify that internal init does not leak resources from
1405 the locking subsystem.
1406
1407 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1408 rep073
1409
1410 Test of allowing clients to create and update their own scratch
1411 databases within the environment. Doing so requires the use
1412 use of the DB_TXN_NOT_DURABLE flag for those databases.
1413
1414 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1415 rep074
1416 Verify replication withstands send errors processing requests.
1417
1418 Run for btree only because access method shouldn't matter.
1419
1420
1421 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1422 rep075
1423 Replication and prepared transactions.
1424 Test having outstanding prepared transactions and simulating
1425 crashing or upgrading or downgrading sites.
1426
1427
1428 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1429 rep076
1430 Replication elections - what happens if elected client
1431 does not become master?
1432
1433 Set up a master and 3 clients. Take down master, run election.
1434 The elected client will ignore the fact that it's been elected,
1435 so we still have 2 clients.
1436
1437 Run another election, a regular election that allows the winner
1438 to become master, and make sure it goes okay. We do this both
1439 for the client that ignored its election and for the other client.
1440
1441 This simulates what would happen if, say, we had a temporary
1442 network partition and lost the winner.
1443
1444 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1445 rep077
1446
1447 Replication, recovery and applying log records immediately.
1448 Master and 1 client. Start up both sites.
1449 Close client and run rep_test on the master so that the
1450 log record is the same LSN the client would be expecting.
1451 Reopen client with recovery and verify the client does not
1452 try to apply that "expected" record before it synchronizes
1453 with the master.
1454
1455 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1456 rep078
1457
1458 Replication and basic lease test.
1459 Set leases on master and 2 clients.
1460 Do a lease operation and process to all clients.
1461 Read with lease on master. Do another lease operation
1462 and don't process on any client. Try to read with
1463 on the master and verify it fails. Process the messages
1464 to the clients and retry the read.
1465
1466 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1467 rep079
1468 Replication leases and invalid usage.
1469
1470 Open a client without leases. Attempt to set leases after rep_start.
1471 Attempt to declare as master without election.
1472 Run an election with an nsites parameter value.
1473 Elect a master with leases. Put some data and send to clients.
1474 Cleanly shutdown master env. Restart without
1475 recovery and verify leases are expired and refreshed.
1476 Add a new client without leases to a group using leases.
1477 Test errors if we cannot get leases before/after txn_commit.
1478
1479 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1480 rep080
1481 AUTOINIT off with empty client logs.
1482
1483 Verify that a fresh client trying to join the group for
1484 the first time observes the setting of DELAY_SYNC and !AUTOINIT
1485 properly.
1486
1487
1488 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1489 rep081
1490 Test of internal initialization and missing database files.
1491
1492 One master, one client, two databases.
1493 Generate several log files.
1494 Remove old master log files.
1495 Start up client.
1496 Remove or replace one master database file while client initialization
1497 is in progress, make sure other master database can keep processing.
1498
1499 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1500 rep082
1501 Sending replication requests to correct master site.
1502
1503 Regression test for a bug [#16592] where a client could send an
1504 UPDATE_REQ to another client instead of the master.
1505
1506 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1507 rep083
1508 Replication clients must never send VERIFY_FAIL to a c2c request.
1509
1510 Regression test for a bug [#16592] where a client could send a
1511 VERIFY_FAIL to another client, which is illegal.
1512
1513 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1514 rep084
1515 Abbreviated internal init for named in-memory databases (NIMDBs).
1516
1517
1518 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1519 rep085
1520 Skipping unnecessary abbreviated internal init.
1521
1522 Make sure that once we've materialized NIMDBs, we don't bother
1523 trying to do it again on subsequent sync without recovery. Make
1524 sure we do probe for the need to materialize NIMDBs, but don't do
1525 any internal init at all if there are no NIMDBs. Note that in order to
1526 do this test we don't even need any NIMDBs.
1527
1528 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1529 rep086
1530 Interrupted abbreviated internal init.
1531
1532 Make sure we cleanly remove partially loaded named in-memory
1533 databases (NIMDBs).
1534
1535 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1536 rep087
1537 Abbreviated internal init with open file handles.
1538
1539 Client has open handle to an on-disk DB when abbreviated
1540 internal init starts. Make sure we lock out access, and make sure
1541 it ends up as HANDLE_DEAD. Also, make sure that if there are
1542 no NIMDBs, that we *don't* get HANDLE_DEAD.
1543
1544 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1545 rep088
1546 Replication roll-back preserves checkpoint.
1547
1548 Create a situation where a client has to roll back its
1549 log, discarding some existing transactions, in order to sync
1550 with a new master.
1551
1552 1. When the client still has its entire log file history, all
1553 the way back to log file #1, it's OK if the roll-back discards
1554 any/all checkpoints.
1555 2. When old log files have been archived, if the roll-back would
1556 remove all existing checkpoints it must be forbidden. The log
1557 must always have a checkpoint (or all files back through #1).
1558 The client must do internal init or return JOIN_FAILURE.
1559 3. (the normal case) Old log files archived, and a checkpoint
1560 still exists in the portion of the log which will remain after
1561 the roll-back: no internal-init/JOIN_FAILURE necessary.
1562
1563 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1564 rep089
1565 Test of proper clean-up of mpool during interrupted internal init.
1566
1567 Have a client in the middle of internal init when a new master
1568 generation comes along, forcing the client to interrupt the internal
1569 init, including doing the clean-up. The client is in the middle of
1570 retrieving database pages, so that we are forced to clean up mpool.
1571 (Regression test for bug 17121)
1572
1573 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1574 rep090
1575 Test of AUTO_REMOVE on both master and client sites.
1576
1577 One master, one client. Set AUTO_REMOVE on the client env.
1578 Generate several log files.
1579 Verify the client has properly removed the log files.
1580 Turn on AUTO_REMOVE on the master and generate more log files.
1581 Confirm both envs have the same log files.
1582
1583 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1584 rep091
1585 Read-your-writes consistency.
1586 Write transactions at the master, and then call the txn_applied()
1587 method to see whether the client has received and applied them yet.
1588
1589 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1590 rep092
1591 Read-your-writes consistency.
1592 Test events in one thread (process) waking up another sleeping thread,
1593 before a timeout expires.
1594
1595 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1596 rep093
1597 Egen changes during election.
1598
1599 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1600 rep094
1601 Full election with less than majority initially connected.
1602
1603 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1604 rep095
1605 Test of internal initialization use of shared region memory.
1606
1607 One master, one client. Create a gap that requires internal
1608 initialization. Start the internal initialization in this
1609 parent process and complete it in a separate child process.
1610
1611 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1612 rep096
1613 Replication and db_replicate utility.
1614
1615 Create a master and client environment. Open them.
1616 Start a db_replicate process on each. Create a database on
1617 the master and write some data. Then verify contents.
1618
1619 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1620 rep097
1621
1622 Replication and lease data durability test.
1623 Set leases on master and 2 clients.
1624 Have the original master go down and a client take over.
1625 Have the old master rejoin as client, but go down again.
1626 The other two sites do one txn, while the original master's
1627 LSN extends beyond due to running recovery.
1628 Original Master rejoins while new master fails. Make sure remaining
1629 original site is elected, with the smaller LSN, but with txn data.
1630
1631 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1632 rep098
1633 Test of internal initialization and page deallocation.
1634
1635 Use one master, one client.
1636 Generate several log files.
1637 Remove old master log files.
1638 Start a client.
1639 After client gets UPDATE file information, delete entries to
1640 remove pages in the database.
1641
1642 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1643 rep099
1644 Test of multiple data dirs and databases, both active replication
1645 and internal init.
1646
1647 One master, two clients using several data_dirs.
1648 Create databases in different data_dirs. Replicate to client.
1649 Add 2nd client later to require it to catch up via internal init.
1650
1651 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1652 rep100
1653 Checkpoints and unresolved txns
1654
1655
1656 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1657 rep101
1658 Test of exclusive access to databases and HA.
1659 Confirm basic functionality with master and client.
1660 Confirm excl access after checkpoint and archive.
1661 Confirm internal init with open excl databases.
1662
1663
1664 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1665 rep102
1666 Test of exclusive access to databases and HA.
1667 Master creates a database, writes some txns, and closes the db.
1668 Client opens the database (in child process).
1669 Master opens database exclusively.
1670 Client tries to read database and gets HANDLE_DEAD. Closes db.
1671 Client tries to reopen database and is blocked.
1672
1673
1674 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1675 rep109
1676 Test that snapshot isolation cannot be used on HA clients.
1677 Master creates a txn with DB_TXN_SNAPSHOT and succeeds.
1678 Client gets an error when creating txn with DB_TXN_SNAPSHOT.
1679 Master opens a cursor with DB_TXN_SNAPSHOT and succeeds.
1680 Client gets and error when opening a cursor with DB_TXN_SNAPSHOT.
1681
1682
1683 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1684 repmgr001
1685 Basic repmgr test.
1686
1687 Run all mix-and-match combinations of the basic_repmgr_test.
1688
1689
1690 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1691 repmgr002
1692 Basic repmgr test.
1693
1694 Run all combinations of the basic_repmgr_election_test.
1695
1696
1697 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1698 repmgr003
1699 Basic repmgr init test.
1700
1701 Run all combinations of the basic_repmgr_init_test.
1702
1703
1704 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1705 repmgr007
1706 Basic repmgr client shutdown/restart test.
1707
1708 Start an appointed master site and two clients. Shut down and
1709 restart each client, processing transactions after each restart.
1710 Verify all expected transactions are replicated.
1711
1712 Run for btree only because access method shouldn't matter.
1713
1714
1715 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1716 repmgr009
1717 repmgr API error test.
1718
1719 Try a variety of repmgr calls that result in errors. Also
1720 try combinations of repmgr and base replication API calls
1721 that result in errors.
1722
1723 Run for btree only because access method shouldn't matter.
1724
1725
1726 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1727 repmgr010
1728 Acknowledgement policy and timeout test.
1729
1730 Verify that "quorum" acknowledgement policy succeeds with fewer than
1731 nsites running. Verify that "all" acknowledgement policy results in
1732 ack failures with fewer than nsites running.
1733
1734 Run for btree only because access method shouldn't matter.
1735
1736
1737 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1738 repmgr011
1739 repmgr two site strict majority test.
1740
1741 Start an appointed master and one client with 2 site strict
1742 majority set. Shut down the master site, wait and verify that
1743 the client site was not elected master. Start up master site
1744 and verify that transactions are processed as expected.
1745
1746 Run for btree only because access method shouldn't matter.
1747
1748
1749 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1750 repmgr012
1751 repmgr heartbeat test.
1752
1753 Start an appointed master and one client site. Set heartbeat
1754 send and monitor values and process some transactions. Stop
1755 sending heartbeats from master and verify that client sees
1756 a dropped connection.
1757
1758 Run for btree only because access method shouldn't matter.
1759
1760
1761 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1762 repmgr013
1763 Site list test.
1764
1765 Configure a master and two clients where one client is a peer of
1766 the other and verify resulting site lists.
1767
1768 Run for btree only because access method shouldn't matter.
1769
1770
1771 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1772 repmgr017
1773 repmgr in-memory cache overflow test.
1774
1775 Start an appointed master site and one client, putting databases,
1776 environment regions, logs and replication files in-memory. Set
1777 very small cachesize and run enough transactions to overflow cache.
1778 Shut down and restart master and client, giving master a larger cache.
1779 Run and verify a small number of transactions.
1780
1781 Run for btree only because access method shouldn't matter.
1782
1783
1784 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1785 repmgr018
1786 Check repmgr stats.
1787
1788 Start an appointed master and one client. Shut down the client,
1789 run some transactions at the master and verify that there are
1790 acknowledgement failures and one dropped connection. Shut down
1791 and restart client again and verify that there are two dropped
1792 connections.
1793
1794 Run for btree only because access method shouldn't matter.
1795
1796
1797 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1798 repmgr023
1799 Test of JOIN_FAILURE event for repmgr applications.
1800
1801 Run for btree only because access method shouldn't matter.
1802
1803 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1804 repmgr024
1805 Test of group-wide log archiving awareness.
1806 Verify that log archiving will use the ack from the clients in
1807 its decisions about what log files are allowed to be archived.
1808
1809 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1810 repmgr025
1811 repmgr heartbeat rerequest test.
1812
1813 Start an appointed master site and one client. Use a test hook
1814 to inhibit PAGE_REQ processing at the master (i.e., "lose" some
1815 messages).
1816 Start a second client that gets stuck in internal init. Wait
1817 long enough to rely on the heartbeat rerequest to request the
1818 missing pages, rescind the test hook and verify that all
1819 data appears on both clients.
1820
1821 Run for btree only because access method shouldn't matter.
1822
1823
1824 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1825 repmgr026
1826 Test of "full election" timeouts.
1827 1. Cold boot with all sites present.
1828 2. Cold boot with some sites missing.
1829 3. Partial-participation election with one client having seen a master,
1830 but another just starting up fresh.
1831 4. Partial participation, with all participants already having seen a
1832 master.
1833
1834
1835 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1836 repmgr027
1837 Test of "full election" timeouts, where a client starts up and joins the
1838 group during the middle of an election.
1839
1840
1841 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1842 repmgr028
1843 Repmgr allows applications to choose master explicitly, instead of
1844 relying on elections.
1845
1846 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1847 repmgr029
1848 Test repmgr group membership: create, join, re-join and remove from
1849 repmgr group and observe changes in group membership database.
1850
1851
1852 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1853 repmgr030
1854 repmgr multiple client-to-client peer test.
1855
1856 Start an appointed master and three clients. The third client
1857 configures the other two clients as peers and delays client
1858 sync. Add some data and confirm that the third client uses first
1859 client as a peer. Close the master so that the first client now
1860 becomes the master. Add some more data and confirm that the
1861 third client now uses the second client as a peer.
1862
1863 Run for btree only because access method shouldn't matter.
1864
1865
1866 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1867 repmgr032
1868 The (undocumented) AUTOROLLBACK config feature.
1869
1870 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1871 repmgr033
1872 Under quorum policy, if the number of peers in the group is less than a
1873 majority, that's still OK.
1874
1875 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1876 repmgr034
1877 Repmgr site removal and restart.
1878
1879 Start two repmgr sites, master and client1. The client1 removes
1880 itself and restarts, sometimes more than once. Start a third
1881 repmgr site client2 and make sure it can remove client1 from
1882 the group.
1883
1884 This test must use heartbeats to ensure that a client that has
1885 been removed and restarted without recovery can sync up.
1886
1887
1888 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1889 repmgr100
1890 Basic test of repmgr's multi-process master support.
1891
1892 Set up a simple 2-site group, create data and replicate it.
1893 Add a second process at the master and have it write some
1894 updates. It does not explicitly start repmgr (nor do any
1895 replication configuration, for that matter). Its first
1896 update triggers initiation of connections, and so it doesn't
1897 get to the client without a log request. But later updates
1898 should go directly.
1899
1900 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1901 repmgr101
1902 Repmgr support for multi-process master.
1903
1904 Start two processes at the master.
1905 Add a client site (not previously known to the master
1906 processes), and make sure
1907 both master processes connect to it.
1908
1909 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1910 repmgr102
1911 Ensuring exactly one listener process.
1912
1913 Start a repmgr process with a listener.
1914 Start a second process, and see that it does not become the listener.
1915 Shut down the first process (gracefully). Now a second process should
1916 become listener.
1917 Kill the listener process abruptly. Running failchk should show that
1918 recovery is necessary. Run recovery and start a clean listener.
1919
1920 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1921 repmgr105
1922 Repmgr recognition of peer setting, across processes.
1923
1924 Set up a master and two clients, synchronized with some data.
1925 Add a new client, configured to use c2c sync with one of the original
1926 clients. Check stats to make sure the correct c2c peer was used.
1927
1928 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1929 repmgr106
1930 Simple smoke test for repmgr elections with multi-process envs.
1931
1932 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1933 repmgr107
1934 Repmgr combined with replication-unaware process at master.
1935
1936 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1937 repmgr108
1938 Subordinate connections and processes should not trigger elections.
1939
1940 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1941 repmgr109
1942 Test repmgr's internal juggling of peer EID's.
1943
1944 Set up master and 2 clients, A and B.
1945 Add a third client (C), with two processes.
1946 The first process will be configured to know about A.
1947 The second process will know about B, and set that as peer,
1948 but when it joins the env site B will have to be shuffled
1949 into a later position in the list, because A is already first.
1950
1951 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1952 repmgr110
1953 Multi-process repmgr start-up policies.
1954
1955 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1956 repmgr111
1957 Multi-process repmgr with env open before set local site.
1958
1959 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1960 repmgr112
1961 Multi-process repmgr ack policies.
1962
1963 Subordinate processes sending live log records must observe the
1964 ack policy set by the main process. Also, a policy change made by a
1965 subordinate process should be observed by all processes.
1966
1967 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1968 rsrc001
1969 Recno backing file test. Try different patterns of adding
1970 records and making sure that the corresponding file matches.
1971
1972 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1973 rsrc002
1974 Recno backing file test #2: test of set_re_delim. Specify a backing
1975 file with colon-delimited records, and make sure they are correctly
1976 interpreted.
1977
1978 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1979 rsrc003
1980 Recno backing file test. Try different patterns of adding
1981 records and making sure that the corresponding file matches.
1982
1983 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1984 rsrc004
1985 Recno backing file test for EOF-terminated records.
1986
1987 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1988 scr###
1989 The scr### directories are shell scripts that test a variety of
1990 things, including things about the distribution itself. These
1991 tests won't run on most systems, so don't even try to run them.
1992
1993 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1994 sdb001 Tests mixing db and subdb operations
1995 Tests mixing db and subdb operations
1996 Create a db, add data, try to create a subdb.
1997 Test naming db and subdb with a leading - for correct parsing
1998 Existence check -- test use of -excl with subdbs
1999
2000 Test non-subdb and subdb operations
2001 Test naming (filenames begin with -)
2002 Test existence (cannot create subdb of same name with -excl)
2003
2004 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2005 sdb002
2006 Tests basic subdb functionality
2007 Small keys, small data
2008 Put/get per key
2009 Dump file
2010 Close, reopen
2011 Dump file
2012
2013 Use the first 10,000 entries from the dictionary.
2014 Insert each with self as key and data; retrieve each.
2015 After all are entered, retrieve all; compare output to original.
2016 Close file, reopen, do retrieve and re-verify.
2017 Then repeat using an environment.
2018
2019 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2020 sdb003
2021 Tests many subdbs
2022 Creates many subdbs and puts a small amount of
2023 data in each (many defaults to 1000)
2024
2025 Use the first 1000 entries from the dictionary as subdbnames.
2026 Insert each with entry as name of subdatabase and a partial list
2027 as key/data. After all are entered, retrieve all; compare output
2028 to original. Close file, reopen, do retrieve and re-verify.
2029
2030 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2031 sdb004
2032 Tests large subdb names
2033 subdb name = filecontents,
2034 key = filename, data = filecontents
2035 Put/get per key
2036 Dump file
2037 Dump subdbs, verify data and subdb name match
2038
2039 Create 1 db with many large subdbs. Use the contents as subdb names.
2040 Take the source files and dbtest executable and enter their names as
2041 the key with their contents as data. After all are entered, retrieve
2042 all; compare output to original. Close file, reopen, do retrieve and
2043 re-verify.
2044
2045 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2046 sdb005
2047 Tests cursor operations in subdbs
2048 Put/get per key
2049 Verify cursor operations work within subdb
2050 Verify cursor operations do not work across subdbs
2051
2052
2053 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2054 sdb006
2055 Tests intra-subdb join
2056
2057 We'll test 2-way, 3-way, and 4-way joins and figure that if those work,
2058 everything else does as well. We'll create test databases called
2059 sub1.db, sub2.db, sub3.db, and sub4.db. The number on the database
2060 describes the duplication -- duplicates are of the form 0, N, 2N, 3N,
2061 ... where N is the number of the database. Primary.db is the primary
2062 database, and sub0.db is the database that has no matching duplicates.
2063 All of these are within a single database.
2064
2065 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2066 sdb007
2067 Tests page size difference errors between subdbs.
2068 If the physical file already exists, we ignore pagesize specifications
2069 on any subsequent -creates.
2070
2071 1. Create/open a subdb with system default page size.
2072 Create/open a second subdb specifying a different page size.
2073 The create should succeed, but the pagesize of the new db
2074 will be the system default page size.
2075 2. Create/open a subdb with a specified, non-default page size.
2076 Create/open a second subdb specifying a different page size.
2077 The create should succeed, but the pagesize of the new db
2078 will be the specified page size from the first create.
2079
2080 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2081 sdb008
2082 Tests explicit setting of lorders for subdatabases -- the
2083 lorder should be ignored.
2084
2085 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2086 sdb009
2087 Test DB->rename() method for subdbs
2088
2089 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2090 sdb010
2091 Test DB->remove() method and DB->truncate() for subdbs
2092
2093 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2094 sdb011
2095 Test deleting Subdbs with overflow pages
2096 Create 1 db with many large subdbs.
2097 Test subdatabases with overflow pages.
2098
2099 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2100 sdb012
2101 Test subdbs with locking and transactions
2102 Tests creating and removing subdbs while handles
2103 are open works correctly, and in the face of txns.
2104
2105 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2106 sdb013
2107 Tests in-memory subdatabases.
2108 Create an in-memory subdb. Test for persistence after
2109 overflowing the cache. Test for conflicts when we have
2110 two in-memory files.
2111
2112 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2113 sdb014
2114 Tests mixing in-memory named and in-memory unnamed dbs.
2115 Create a regular in-memory db, add data.
2116 Create a named in-memory db.
2117 Try to create the same named in-memory db again (should fail).
2118 Try to create a different named in-memory db (should succeed).
2119
2120
2121 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2122 sdb015
2123 Tests basic in-memory named database functionality
2124 Small keys, small data
2125 Put/get per key
2126
2127 Use the first 10,000 entries from the dictionary.
2128 Insert each with self as key and data; retrieve each.
2129 After all are entered, retrieve all; compare output to original.
2130 Close file, reopen, do retrieve and re-verify.
2131 Then repeat using an environment.
2132
2133 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2134 sdb016
2135 Creates many in-memory named dbs and puts a small amount of
2136 data in each (many defaults to 100)
2137
2138 Use the first 100 entries from the dictionary as names.
2139 Insert each with entry as name of subdatabase and a partial list
2140 as key/data. After all are entered, retrieve all; compare output
2141 to original.
2142
2143 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2144 sdb017
2145 Test DB->rename() for in-memory named databases.
2146
2147 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2148 sdb018
2149 Tests join of in-memory named databases.
2150
2151 We'll test 2-way, 3-way, and 4-way joins and figure that if those work,
2152 everything else does as well. We'll create test databases called
2153 sub1.db, sub2.db, sub3.db, and sub4.db. The number on the database
2154 describes the duplication -- duplicates are of the form 0, N, 2N, 3N,
2155 ... where N is the number of the database. Primary.db is the primary
2156 database, and sub0.db is the database that has no matching duplicates.
2157 All of these are within a single database.
2158
2159 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2160 sdb019
2161 Tests in-memory subdatabases.
2162 Create an in-memory subdb. Test for persistence after
2163 overflowing the cache. Test for conflicts when we have
2164 two in-memory files.
2165
2166 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2167 sdb020
2168 Tests in-memory subdatabases.
2169 Create an in-memory subdb with one page size. Close, and
2170 open with a different page size: should succeed, but the underlying
2171 page size is not changed.
2172
2173 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2174 sdbtest001
2175 Tests multiple access methods in one subdb
2176 Open several subdbs, each with a different access method
2177 Small keys, small data
2178 Put/get per key per subdb
2179 Dump file, verify per subdb
2180 Close, reopen per subdb
2181 Dump file, verify per subdb
2182
2183 Make several subdb's of different access methods all in one DB.
2184 Rotate methods and repeat [#762].
2185 Use the first 10,000 entries from the dictionary.
2186 Insert each with self as key and data; retrieve each.
2187 After all are entered, retrieve all; compare output to original.
2188 Close file, reopen, do retrieve and re-verify.
2189
2190 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2191 sdbtest002
2192 Tests multiple access methods in one subdb access by multiple
2193 processes.
2194 Open several subdbs, each with a different access method
2195 Small keys, small data
2196 Put/get per key per subdb
2197 Fork off several child procs to each delete selected
2198 data from their subdb and then exit
2199 Dump file, verify contents of each subdb is correct
2200 Close, reopen per subdb
2201 Dump file, verify per subdb
2202
2203 Make several subdb's of different access methods all in one DB.
2204 Fork of some child procs to each manipulate one subdb and when
2205 they are finished, verify the contents of the databases.
2206 Use the first 10,000 entries from the dictionary.
2207 Insert each with self as key and data; retrieve each.
2208 After all are entered, retrieve all; compare output to original.
2209 Close file, reopen, do retrieve and re-verify.
2210
2211 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2212 sec001
2213 Test of security interface
2214
2215 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2216 sec002
2217 Test of security interface and catching errors in the
2218 face of attackers overwriting parts of existing files.
2219
2220 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2221 si001
2222 Secondary index put/delete with lorder test
2223
2224 Put data in primary db and check that pget on secondary
2225 index finds the right entries. Alter the primary in the
2226 following ways, checking for correct data each time:
2227 Overwrite data in primary database.
2228 Delete half of entries through primary.
2229 Delete half of remaining entries through secondary.
2230 Append data (for record-based primaries only).
2231
2232 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2233 si002
2234 Basic cursor-based secondary index put/delete test
2235
2236 Cursor put data in primary db and check that pget
2237 on secondary index finds the right entries.
2238 Open and use a second cursor to exercise the cursor
2239 comparison API on secondaries.
2240 Overwrite while walking primary, check pget again.
2241 Overwrite while walking secondary (use c_pget), check
2242 pget again.
2243 Cursor delete half of entries through primary, check.
2244 Cursor delete half of remainder through secondary, check.
2245
2246 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2247 si003
2248 si001 with secondaries created and closed mid-test
2249 Basic secondary index put/delete test with secondaries
2250 created mid-test.
2251
2252 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2253 si004
2254 si002 with secondaries created and closed mid-test
2255 Basic cursor-based secondary index put/delete test, with
2256 secondaries created mid-test.
2257
2258 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2259 si005
2260 Basic secondary index put/delete test with transactions
2261
2262 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2263 si006
2264
2265 Test -immutable_key interface.
2266
2267 DB_IMMUTABLE_KEY is an optimization to be used when a
2268 secondary key will not be changed. It does not prevent
2269 a deliberate change to the secondary key, it just does not
2270 propagate that change when it is made to the primary.
2271 This test verifies that a change to the primary is propagated
2272 to the secondary or not as specified by -immutable_key.
2273
2274 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2275 si007
2276 Secondary index put/delete with lorder test
2277
2278 This test is the same as si001 with the exception
2279 that we create and populate the primary and THEN
2280 create the secondaries and associate them with -create.
2281
2282 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2283 si008
2284 Secondary index put/delete with lorder test
2285
2286 This test is the same as si001 except that we
2287 create the secondaries with different byte orders:
2288 one native, one swapped.
2289
2290 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2291 sijointest: Secondary index and join test.
2292 This used to be si005.tcl.
2293
2294 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2295 sql001
2296 Test db_replicate using a simple SQL app.
2297
2298 Start db_replicate on master side and client side,
2299 and do various operations using dbsql on master side.
2300 After every operation, we will check the records on both sides,
2301 to make sure we get same results from both sides.
2302 Also try an insert operation on client side; it should fail.
2303
2304 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2305 test001
2306 Small keys/data
2307 Put/get per key
2308 Dump file
2309 Close, reopen
2310 Dump file
2311
2312 Use the first 10,000 entries from the dictionary.
2313 Insert each with self as key and data; retrieve each.
2314 After all are entered, retrieve all; compare output to original.
2315 Close file, reopen, do retrieve and re-verify.
2316
2317 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2318 test002
2319 Small keys/medium data
2320 Put/get per key
2321 Dump file
2322 Close, reopen
2323 Dump file
2324
2325 Use the first 10,000 entries from the dictionary.
2326 Insert each with self as key and a fixed, medium length data string;
2327 retrieve each. After all are entered, retrieve all; compare output
2328 to original. Close file, reopen, do retrieve and re-verify.
2329
2330 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2331 test003
2332 Small keys/large data
2333 Put/get per key
2334 Dump file
2335 Close, reopen
2336 Dump file
2337
2338 Take the source files and dbtest executable and enter their names
2339 as the key with their contents as data. After all are entered,
2340 retrieve all; compare output to original. Close file, reopen, do
2341 retrieve and re-verify.
2342
2343 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2344 test004
2345 Small keys/medium data
2346 Put/get per key
2347 Sequential (cursor) get/delete
2348
2349 Check that cursor operations work. Create a database.
2350 Read through the database sequentially using cursors and
2351 delete each element.
2352
2353 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2354 test005
2355 Small keys/medium data
2356 Put/get per key
2357 Close, reopen
2358 Sequential (cursor) get/delete
2359
2360 Check that cursor operations work. Create a database; close
2361 it and reopen it. Then read through the database sequentially
2362 using cursors and delete each element.
2363
2364 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2365 test006
2366 Small keys/medium data
2367 Put/get per key
2368 Keyed delete and verify
2369
2370 Keyed delete test.
2371 Create database.
2372 Go through database, deleting all entries by key.
2373 Then do the same for unsorted and sorted dups.
2374
2375 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2376 test007
2377 Small keys/medium data
2378 Put/get per key
2379 Close, reopen
2380 Keyed delete
2381
2382 Check that delete operations work. Create a database; close
2383 database and reopen it. Then issues delete by key for each
2384 entry. (Test006 plus reopen)
2385
2386 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2387 test008
2388 Small keys/large data
2389 Put/get per key
2390 Loop through keys by steps (which change)
2391 ... delete each key at step
2392 ... add each key back
2393 ... change step
2394 Confirm that overflow pages are getting reused
2395
2396 Take the source files and dbtest executable and enter their names as
2397 the key with their contents as data. After all are entered, begin
2398 looping through the entries; deleting some pairs and then readding them.
2399
2400 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2401 test009
2402 Small keys/large data
2403 Same as test008; close and reopen database
2404
2405 Check that we reuse overflow pages. Create database with lots of
2406 big key/data pairs. Go through and delete and add keys back
2407 randomly. Then close the DB and make sure that we have everything
2408 we think we should.
2409
2410 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2411 test010
2412 Duplicate test
2413 Small key/data pairs.
2414
2415 Use the first 10,000 entries from the dictionary.
2416 Insert each with self as key and data; add duplicate records for each.
2417 After all are entered, retrieve all; verify output.
2418 Close file, reopen, do retrieve and re-verify.
2419 This does not work for recno
2420
2421 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2422 test011
2423 Duplicate test
2424 Small key/data pairs.
2425 Test DB_KEYFIRST, DB_KEYLAST, DB_BEFORE and DB_AFTER.
2426 To test off-page duplicates, run with small pagesize.
2427
2428 Use the first 10,000 entries from the dictionary.
2429 Insert each with self as key and data; add duplicate records for each.
2430 Then do some key_first/key_last add_before, add_after operations.
2431 This does not work for recno
2432
2433 To test if dups work when they fall off the main page, run this with
2434 a very tiny page size.
2435
2436 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2437 test012
2438 Large keys/small data
2439 Same as test003 except use big keys (source files and
2440 executables) and small data (the file/executable names).
2441
2442 Take the source files and dbtest executable and enter their contents
2443 as the key with their names as data. After all are entered, retrieve
2444 all; compare output to original. Close file, reopen, do retrieve and
2445 re-verify.
2446
2447 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2448 test013
2449 Partial put test
2450 Overwrite entire records using partial puts.
2451 Make sure that NOOVERWRITE flag works.
2452
2453 1. Insert 10000 keys and retrieve them (equal key/data pairs).
2454 2. Attempt to overwrite keys with NO_OVERWRITE set (expect error).
2455 3. Actually overwrite each one with its datum reversed.
2456
2457 No partial testing here.
2458
2459 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2460 test014
2461 Exercise partial puts on short data
2462 Run 5 combinations of numbers of characters to replace,
2463 and number of times to increase the size by.
2464
2465 Partial put test, small data, replacing with same size. The data set
2466 consists of the first nentries of the dictionary. We will insert them
2467 (and retrieve them) as we do in test 1 (equal key/data pairs). Then
2468 we'll try to perform partial puts of some characters at the beginning,
2469 some at the end, and some at the middle.
2470
2471 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2472 test015
2473 Partial put test
2474 Partial put test where the key does not initially exist.
2475
2476 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2477 test016
2478 Partial put test
2479 Partial put where the datum gets shorter as a result of the put.
2480
2481 Partial put test where partial puts make the record smaller.
2482 Use the first 10,000 entries from the dictionary.
2483 Insert each with self as key and a fixed, medium length data string;
2484 retrieve each. After all are entered, go back and do partial puts,
2485 replacing a random-length string with the key value.
2486 Then verify.
2487
2488 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2489 test017
2490 Basic offpage duplicate test.
2491
2492 Run duplicates with small page size so that we test off page duplicates.
2493 Then after we have an off-page database, test with overflow pages too.
2494
2495 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2496 test018
2497 Offpage duplicate test
2498 Key_{first,last,before,after} offpage duplicates.
2499 Run duplicates with small page size so that we test off page
2500 duplicates.
2501
2502 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2503 test019
2504 Partial get test.
2505
2506 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2507 test020
2508 In-Memory database tests.
2509
2510 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2511 test021
2512 Btree range tests.
2513
2514 Use the first 10,000 entries from the dictionary.
2515 Insert each with self, reversed as key and self as data.
2516 After all are entered, retrieve each using a cursor SET_RANGE, and
2517 getting about 20 keys sequentially after it (in some cases we'll
2518 run out towards the end of the file).
2519
2520 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2521 test022
2522 Test of DB->getbyteswapped().
2523
2524 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2525 test023
2526 Duplicate test
2527 Exercise deletes and cursor operations within a duplicate set.
2528 Add a key with duplicates (first time on-page, second time off-page)
2529 Number the dups.
2530 Delete dups and make sure that CURRENT/NEXT/PREV work correctly.
2531
2532 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2533 test024
2534 Record number retrieval test.
2535 Test the Btree and Record number get-by-number functionality.
2536
2537 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2538 test025
2539 DB_APPEND flag test.
2540
2541 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2542 test026
2543 Small keys/medium data w/duplicates
2544 Put/get per key.
2545 Loop through keys -- delete each key
2546 ... test that cursors delete duplicates correctly
2547
2548 Keyed delete test through cursor. If ndups is small; this will
2549 test on-page dups; if it's large, it will test off-page dups.
2550
2551 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2552 test027
2553 Off-page duplicate test
2554 Test026 with parameters to force off-page duplicates.
2555
2556 Check that delete operations work. Create a database; close
2557 database and reopen it. Then issues delete by key for each
2558 entry.
2559
2560 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2561 test028
2562 Cursor delete test
2563 Test put operations after deleting through a cursor.
2564
2565 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2566 test029
2567 Test the Btree and Record number renumbering.
2568
2569 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2570 test030
2571 Test DB_NEXT_DUP Functionality.
2572
2573 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2574 test031
2575 Duplicate sorting functionality
2576 Make sure DB_NODUPDATA works.
2577
2578 Use the first 10,000 entries from the dictionary.
2579 Insert each with self as key and "ndups" duplicates
2580 For the data field, prepend random five-char strings (see test032)
2581 that we force the duplicate sorting code to do something.
2582 Along the way, test that we cannot insert duplicate duplicates
2583 using DB_NODUPDATA.
2584
2585 By setting ndups large, we can make this an off-page test
2586 After all are entered, retrieve all; verify output.
2587 Close file, reopen, do retrieve and re-verify.
2588 This does not work for recno
2589
2590 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2591 test032
2592 DB_GET_BOTH, DB_GET_BOTH_RANGE
2593
2594 Use the first 10,000 entries from the dictionary. Insert each with
2595 self as key and "ndups" duplicates. For the data field, prepend the
2596 letters of the alphabet in a random order so we force the duplicate
2597 sorting code to do something. By setting ndups large, we can make
2598 this an off-page test. By setting overflow to be 1, we can make
2599 this an overflow test.
2600
2601 Test the DB_GET_BOTH functionality by retrieving each dup in the file
2602 explicitly. Test the DB_GET_BOTH_RANGE functionality by retrieving
2603 the unique key prefix (cursor only). Finally test the failure case.
2604
2605 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2606 test033
2607 DB_GET_BOTH without comparison function
2608
2609 Use the first 10,000 entries from the dictionary. Insert each with
2610 self as key and data; add duplicate records for each. After all are
2611 entered, retrieve all and verify output using DB_GET_BOTH (on DB and
2612 DBC handles) and DB_GET_BOTH_RANGE (on a DBC handle) on existent and
2613 nonexistent keys.
2614
2615 XXX
2616 This does not work for rbtree.
2617
2618 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2619 test034
2620 test032 with off-page or overflow case with non-duplicates
2621 and duplicates.
2622
2623 DB_GET_BOTH, DB_GET_BOTH_RANGE functionality with off-page
2624 or overflow case within non-duplicates and duplicates.
2625
2626 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2627 test035
2628 Test033 with off-page non-duplicates and duplicates
2629 DB_GET_BOTH functionality with off-page non-duplicates
2630 and duplicates.
2631
2632 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2633 test036
2634 Test KEYFIRST and KEYLAST when the key doesn't exist
2635 Put nentries key/data pairs (from the dictionary) using a cursor
2636 and KEYFIRST and KEYLAST (this tests the case where use use cursor
2637 put for non-existent keys).
2638
2639 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2640 test037
2641 Test DB_RMW
2642
2643 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2644 test038
2645 DB_GET_BOTH, DB_GET_BOTH_RANGE on deleted items
2646
2647 Use the first 10,000 entries from the dictionary. Insert each with
2648 self as key and "ndups" duplicates. For the data field, prepend the
2649 letters of the alphabet in a random order so we force the duplicate
2650 sorting code to do something. By setting ndups large, we can make
2651 this an off-page test
2652
2653 Test the DB_GET_BOTH and DB_GET_BOTH_RANGE functionality by retrieving
2654 each dup in the file explicitly. Then remove each duplicate and try
2655 the retrieval again.
2656
2657 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2658 test039
2659 DB_GET_BOTH/DB_GET_BOTH_RANGE on deleted items without comparison
2660 function.
2661
2662 Use the first 10,000 entries from the dictionary. Insert each with
2663 self as key and "ndups" duplicates. For the data field, prepend the
2664 letters of the alphabet in a random order so we force the duplicate
2665 sorting code to do something. By setting ndups large, we can make
2666 this an off-page test.
2667
2668 Test the DB_GET_BOTH and DB_GET_BOTH_RANGE functionality by retrieving
2669 each dup in the file explicitly. Then remove each duplicate and try
2670 the retrieval again.
2671
2672 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2673 test040
2674 Test038 with off-page duplicates
2675 DB_GET_BOTH functionality with off-page duplicates.
2676
2677 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2678 test041
2679 Test039 with off-page duplicates
2680 DB_GET_BOTH functionality with off-page duplicates.
2681
2682 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2683 test042
2684 Concurrent Data Store test (CDB)
2685
2686 Multiprocess DB test; verify that locking is working for the
2687 concurrent access method product.
2688
2689 Use the first "nentries" words from the dictionary. Insert each with
2690 self as key and a fixed, medium length data string. Then fire off
2691 multiple processes that bang on the database. Each one should try to
2692 read and write random keys. When they rewrite, they'll append their
2693 pid to the data string (sometimes doing a rewrite sometimes doing a
2694 partial put). Some will use cursors to traverse through a few keys
2695 before finding one to write.
2696
2697 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2698 test043
2699 Recno renumbering and implicit creation test
2700 Test the Record number implicit creation and renumbering options.
2701
2702 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2703 test044
2704 Small system integration tests
2705 Test proper functioning of the checkpoint daemon,
2706 recovery, transactions, etc.
2707
2708 System integration DB test: verify that locking, recovery, checkpoint,
2709 and all the other utilities basically work.
2710
2711 The test consists of $nprocs processes operating on $nfiles files. A
2712 transaction consists of adding the same key/data pair to some random
2713 number of these files. We generate a bimodal distribution in key size
2714 with 70% of the keys being small (1-10 characters) and the remaining
2715 30% of the keys being large (uniform distribution about mean $key_avg).
2716 If we generate a key, we first check to make sure that the key is not
2717 already in the dataset. If it is, we do a lookup.
2718
2719 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2720 test045
2721 Small random tester
2722 Runs a number of random add/delete/retrieve operations.
2723 Tests both successful conditions and error conditions.
2724
2725 Run the random db tester on the specified access method.
2726
2727 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2728 test046
2729 Overwrite test of small/big key/data with cursor checks.
2730
2731 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2732 test047
2733 DBcursor->c_get get test with SET_RANGE option.
2734
2735 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2736 test048
2737 Cursor stability across Btree splits.
2738
2739 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2740 test049
2741 Cursor operations on uninitialized cursors.
2742
2743 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2744 test050
2745 Overwrite test of small/big key/data with cursor checks for Recno.
2746
2747 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2748 test051
2749 Fixed-length record Recno test.
2750 0. Test various flags (legal and illegal) to open
2751 1. Test partial puts where dlen != size (should fail)
2752 2. Partial puts for existent record -- replaces at beg, mid, and
2753 end of record, as well as full replace
2754
2755 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2756 test052
2757 Renumbering record Recno test.
2758
2759 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2760 test053
2761 Test of the DB_REVSPLITOFF flag in the Btree and Btree-w-recnum
2762 methods.
2763
2764 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2765 test054
2766 Cursor maintenance during key/data deletion.
2767
2768 This test checks for cursor maintenance in the presence of deletes.
2769 There are N different scenarios to tests:
2770 1. No duplicates. Cursor A deletes a key, do a GET for the key.
2771 2. No duplicates. Cursor is positioned right before key K, Delete K,
2772 do a next on the cursor.
2773 3. No duplicates. Cursor is positioned on key K, do a regular delete
2774 of K, do a current get on K.
2775 4. Repeat 3 but do a next instead of current.
2776 5. Duplicates. Cursor A is on the first item of a duplicate set, A
2777 does a delete. Then we do a non-cursor get.
2778 6. Duplicates. Cursor A is in a duplicate set and deletes the item.
2779 do a delete of the entire Key. Test cursor current.
2780 7. Continue last test and try cursor next.
2781 8. Duplicates. Cursor A is in a duplicate set and deletes the item.
2782 Cursor B is in the same duplicate set and deletes a different item.
2783 Verify that the cursor is in the right place.
2784 9. Cursors A and B are in the place in the same duplicate set. A
2785 deletes its item. Do current on B.
2786 10. Continue 8 and do a next on B.
2787
2788 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2789 test055
2790 Basic cursor operations.
2791 This test checks basic cursor operations.
2792 There are N different scenarios to tests:
2793 1. (no dups) Set cursor, retrieve current.
2794 2. (no dups) Set cursor, retrieve next.
2795 3. (no dups) Set cursor, retrieve prev.
2796
2797 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2798 test056
2799 Cursor maintenance during deletes.
2800 Check if deleting a key when a cursor is on a duplicate of that
2801 key works.
2802
2803 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2804 test057
2805 Cursor maintenance during key deletes.
2806 1. Delete a key with a cursor. Add the key back with a regular
2807 put. Make sure the cursor can't get the new item.
2808 2. Put two cursors on one item. Delete through one cursor,
2809 check that the other sees the change.
2810 3. Same as 2, with the two cursors on a duplicate.
2811
2812 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2813 test058
2814 Verify that deleting and reading duplicates results in correct ordering.
2815
2816 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2817 test059
2818 Cursor ops work with a partial length of 0.
2819 Make sure that we handle retrieves of zero-length data items correctly.
2820 The following ops, should allow a partial data retrieve of 0-length.
2821 db_get
2822 db_cget FIRST, NEXT, LAST, PREV, CURRENT, SET, SET_RANGE
2823
2824 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2825 test060
2826 Test of the DB_EXCL flag to DB->open().
2827 1) Attempt to open and create a nonexistent database; verify success.
2828 2) Attempt to reopen it; verify failure.
2829
2830 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2831 test061
2832 Test of txn abort and commit for in-memory databases.
2833 a) Put + abort: verify absence of data
2834 b) Put + commit: verify presence of data
2835 c) Overwrite + abort: verify that data is unchanged
2836 d) Overwrite + commit: verify that data has changed
2837 e) Delete + abort: verify that data is still present
2838 f) Delete + commit: verify that data has been deleted
2839
2840 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2841 test062
2842 Test of partial puts (using DB_CURRENT) onto duplicate pages.
2843 Insert the first 200 words into the dictionary 200 times each with
2844 self as key and <random letter>:self as data. Use partial puts to
2845 append self again to data; verify correctness.
2846
2847 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2848 test063
2849 Test of the DB_RDONLY flag to DB->open
2850 Attempt to both DB->put and DBC->c_put into a database
2851 that has been opened DB_RDONLY, and check for failure.
2852
2853 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2854 test064
2855 Test of DB->get_type
2856 Create a database of type specified by method.
2857 Make sure DB->get_type returns the right thing with both a normal
2858 and DB_UNKNOWN open.
2859
2860 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2861 test065
2862 Test of DB->stat, both -DB_FAST_STAT and row
2863 counts with DB->stat -txn.
2864
2865 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2866 test066
2867 Test of cursor overwrites of DB_CURRENT w/ duplicates.
2868
2869 Make sure a cursor put to DB_CURRENT acts as an overwrite in a
2870 database with duplicates.
2871
2872 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2873 test067
2874 Test of DB_CURRENT partial puts onto almost empty duplicate
2875 pages, with and without DB_DUP_SORT.
2876
2877 Test of DB_CURRENT partial puts on almost-empty duplicate pages.
2878 This test was written to address the following issue, #2 in the
2879 list of issues relating to bug #0820:
2880
2881 2. DBcursor->put, DB_CURRENT flag, off-page duplicates, hash and btree:
2882 In Btree, the DB_CURRENT overwrite of off-page duplicate records
2883 first deletes the record and then puts the new one -- this could
2884 be a problem if the removal of the record causes a reverse split.
2885 Suggested solution is to acquire a cursor to lock down the current
2886 record, put a new record after that record, and then delete using
2887 the held cursor.
2888
2889 It also tests the following, #5 in the same list of issues:
2890 5. DBcursor->put, DB_AFTER/DB_BEFORE/DB_CURRENT flags, DB_DBT_PARTIAL
2891 set, duplicate comparison routine specified.
2892 The partial change does not change how data items sort, but the
2893 record to be put isn't built yet, and that record supplied is the
2894 one that's checked for ordering compatibility.
2895
2896 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2897 test068
2898 Test of DB_BEFORE and DB_AFTER with partial puts.
2899 Make sure DB_BEFORE and DB_AFTER work properly with partial puts, and
2900 check that they return EINVAL if DB_DUPSORT is set or if DB_DUP is not.
2901
2902 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2903 test069
2904 Test of DB_CURRENT partial puts without duplicates-- test067 w/
2905 small ndups to ensure that partial puts to DB_CURRENT work
2906 correctly in the absence of duplicate pages.
2907
2908 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2909 test070
2910 Test of DB_CONSUME (Four consumers, 1000 items.)
2911
2912 Fork off six processes, four consumers and two producers.
2913 The producers will each put 20000 records into a queue;
2914 the consumers will each get 10000.
2915 Then, verify that no record was lost or retrieved twice.
2916
2917 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2918 test071
2919 Test of DB_CONSUME (One consumer, 10000 items.)
2920 This is DB Test 70, with one consumer, one producers, and 10000 items.
2921
2922 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2923 test072
2924 Test of cursor stability when duplicates are moved off-page.
2925
2926 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2927 test073
2928 Test of cursor stability on duplicate pages.
2929
2930 Does the following:
2931 a. Initialize things by DB->putting ndups dups and
2932 setting a reference cursor to point to each.
2933 b. c_put ndups dups (and correspondingly expanding
2934 the set of reference cursors) after the last one, making sure
2935 after each step that all the reference cursors still point to
2936 the right item.
2937 c. Ditto, but before the first one.
2938 d. Ditto, but after each one in sequence first to last.
2939 e. Ditto, but after each one in sequence from last to first.
2940 occur relative to the new datum)
2941 f. Ditto for the two sequence tests, only doing a
2942 DBC->c_put(DB_CURRENT) of a larger datum instead of adding a
2943 new one.
2944
2945 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2946 test074
2947 Test of DB_NEXT_NODUP.
2948
2949 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2950 test076
2951 Test creation of many small databases in a single environment. [#1528].
2952
2953 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2954 test077
2955 Test of DB_GET_RECNO [#1206].
2956
2957 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2958 test078
2959 Test of DBC->c_count(). [#303]
2960
2961 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2962 test079
2963 Test of deletes in large trees. (test006 w/ sm. pagesize).
2964
2965 Check that delete operations work in large btrees. 10000 entries
2966 and a pagesize of 512 push this out to a four-level btree, with a
2967 small fraction of the entries going on overflow pages.
2968
2969 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2970 test081
2971 Test off-page duplicates and overflow pages together with
2972 very large keys (key/data as file contents).
2973
2974 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2975 test082
2976 Test of DB_PREV_NODUP (uses test074).
2977
2978 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2979 test083
2980 Test of DB->key_range.
2981
2982 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2983 test084
2984 Basic sanity test (test001) with large (64K) pages.
2985
2986 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2987 test085
2988 Test of cursor behavior when a cursor is pointing to a deleted
2989 btree key which then has duplicates added. [#2473]
2990
2991 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2992 test086
2993 Test of cursor stability across btree splits/rsplits with
2994 subtransaction aborts (a variant of test048). [#2373]
2995
2996 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2997 test087
2998 Test of cursor stability when converting to and modifying
2999 off-page duplicate pages with subtransaction aborts. [#2373]
3000
3001 Does the following:
3002 a. Initialize things by DB->putting ndups dups and
3003 setting a reference cursor to point to each. Do each put twice,
3004 first aborting, then committing, so we're sure to abort the move
3005 to off-page dups at some point.
3006 b. c_put ndups dups (and correspondingly expanding
3007 the set of reference cursors) after the last one, making sure
3008 after each step that all the reference cursors still point to
3009 the right item.
3010 c. Ditto, but before the first one.
3011 d. Ditto, but after each one in sequence first to last.
3012 e. Ditto, but after each one in sequence from last to first.
3013 occur relative to the new datum)
3014 f. Ditto for the two sequence tests, only doing a
3015 DBC->c_put(DB_CURRENT) of a larger datum instead of adding a
3016 new one.
3017
3018 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3019 test088
3020 Test of cursor stability across btree splits with very
3021 deep trees (a variant of test048). [#2514]
3022
3023 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3024 test089
3025 Concurrent Data Store test (CDB)
3026
3027 Enhanced CDB testing to test off-page dups, cursor dups and
3028 cursor operations like c_del then c_get.
3029
3030 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3031 test090
3032 Test for functionality near the end of the queue using test001.
3033
3034 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3035 test091
3036 Test of DB_CONSUME_WAIT.
3037
3038 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3039 test092
3040 Test of DB_DIRTY_READ [#3395]
3041
3042 We set up a database with nentries in it. We then open the
3043 database read-only twice. One with dirty reads and one without.
3044 We open the database for writing and update some entries in it.
3045 Then read those new entries via db->get (clean and dirty), and
3046 via cursors (clean and dirty).
3047
3048 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3049 test093
3050 Test set_bt_compare (btree key comparison function) and
3051 set_h_compare (hash key comparison function).
3052
3053 Open a database with a comparison function specified,
3054 populate, and close, saving a list with that key order as
3055 we do so. Reopen and read in the keys, saving in another
3056 list; the keys should be in the order specified by the
3057 comparison function. Sort the original saved list of keys
3058 using the comparison function, and verify that it matches
3059 the keys as read out of the database.
3060
3061 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3062 test094
3063 Test using set_dup_compare.
3064
3065 Use the first 10,000 entries from the dictionary.
3066 Insert each with self as key and data; retrieve each.
3067 After all are entered, retrieve all; compare output to original.
3068 Close file, reopen, do retrieve and re-verify.
3069
3070 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3071 test095
3072 Bulk get test for methods supporting dups. [#2934]
3073
3074 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3075 test096
3076 Db->truncate test.
3077 For all methods:
3078 Test that truncate empties an existing database.
3079 Test that truncate-write in an aborted txn doesn't
3080 change the original contents.
3081 Test that truncate-write in a committed txn does
3082 overwrite the original contents.
3083 For btree and hash, do the same in a database with offpage dups.
3084
3085 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3086 test097
3087 Open up a large set of database files simultaneously.
3088 Adjust for local file descriptor resource limits.
3089 Then use the first 1000 entries from the dictionary.
3090 Insert each with self as key and a fixed, medium length data string;
3091 retrieve each. After all are entered, retrieve all; compare output
3092 to original.
3093
3094 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3095 test098
3096 Test of DB_GET_RECNO and secondary indices. Open a primary and
3097 a secondary, and do a normal cursor get followed by a get_recno.
3098 (This is a smoke test for "Bug #1" in [#5811].)
3099
3100 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3101 test099
3102
3103 Test of DB->get and DBC->c_get with set_recno and get_recno.
3104
3105 Populate a small btree -recnum database.
3106 After all are entered, retrieve each using -recno with DB->get.
3107 Open a cursor and do the same for DBC->c_get with set_recno.
3108 Verify that set_recno sets the record number position properly.
3109 Verify that get_recno returns the correct record numbers.
3110
3111 Using the same database, open 3 cursors and position one at
3112 the beginning, one in the middle, and one at the end. Delete
3113 by cursor and check that record renumbering is done properly.
3114
3115 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3116 test100
3117 Test for functionality near the end of the queue
3118 using test025 (DB_APPEND).
3119
3120 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3121 test101
3122 Test for functionality near the end of the queue
3123 using test070 (DB_CONSUME).
3124
3125 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3126 test102
3127 Bulk get test for record-based methods. [#2934]
3128
3129 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3130 test103
3131 Test bulk get when record numbers wrap around.
3132
3133 Load database with items starting before and ending after
3134 the record number wrap around point. Run bulk gets (-multi_key)
3135 with various buffer sizes and verify the contents returned match
3136 the results from a regular cursor get.
3137
3138 Then delete items to create a sparse database and make sure it
3139 still works. Test both -multi and -multi_key since they behave
3140 differently.
3141
3142 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3143 test106
3144
3145
3146
3147
3148 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3149 test107
3150 Test of read-committed (degree 2 isolation). [#8689]
3151
3152 We set up a database. Open a read-committed transactional cursor and
3153 a regular transactional cursor on it. Position each cursor on one page,
3154 and do a put to a different page.
3155
3156 Make sure that:
3157 - the put succeeds if we are using degree 2 isolation.
3158 - the put deadlocks within a regular transaction with
3159 a regular cursor.
3160
3161
3162 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3163 test109
3164
3165 Test of sequences.
3166
3167 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3168 test110
3169 Partial get test with duplicates.
3170
3171 For hash and btree, create and populate a database
3172 with dups. Randomly selecting offset and length,
3173 retrieve data from each record and make sure we
3174 get what we expect.
3175
3176 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3177 test111
3178 Test database compaction.
3179
3180 Populate a database. Remove a high proportion of entries.
3181 Dump and save contents. Compact the database, dump again,
3182 and make sure we still have the same contents.
3183 Add back some entries, delete more entries (this time by
3184 cursor), dump, compact, and do the before/after check again.
3185
3186 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3187 test112
3188 Test database compaction with a deep tree.
3189
3190 This is a lot like test111, but with a large number of
3191 entries and a small page size to make the tree deep.
3192 To make it simple we use numerical keys all the time.
3193
3194 Dump and save contents. Compact the database, dump again,
3195 and make sure we still have the same contents.
3196 Add back some entries, delete more entries (this time by
3197 cursor), dump, compact, and do the before/after check again.
3198
3199 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3200 test113
3201 Test database compaction with duplicates.
3202
3203 This is essentially test111 with duplicates.
3204 To make it simple we use numerical keys all the time.
3205
3206 Dump and save contents. Compact the database, dump again,
3207 and make sure we still have the same contents.
3208 Add back some entries, delete more entries (this time by
3209 cursor), dump, compact, and do the before/after check again.
3210
3211 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3212 test114
3213 Test database compaction with overflows.
3214
3215 Populate a database. Remove a high proportion of entries.
3216 Dump and save contents. Compact the database, dump again,
3217 and make sure we still have the same contents.
3218 Add back some entries, delete more entries (this time by
3219 cursor), dump, compact, and do the before/after check again.
3220
3221 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3222 test115
3223 Test database compaction with user-specified btree sort.
3224
3225 This is essentially test111 with the user-specified sort.
3226 Populate a database. Remove a high proportion of entries.
3227 Dump and save contents. Compact the database, dump again,
3228 and make sure we still have the same contents.
3229 Add back some entries, delete more entries (this time by
3230 cursor), dump, compact, and do the before/after check again.
3231
3232 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3233 test116
3234 Test of basic functionality of lsn_reset.
3235
3236 Create a database in an env. Copy it to a new file within
3237 the same env. Reset the page LSNs.
3238
3239 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3240 test117
3241 Test database compaction with requested fill percent.
3242
3243 Populate a database. Remove a high proportion of entries.
3244 Dump and save contents. Compact the database, requesting
3245 fill percentages starting at 10% and working our way up to
3246 100. On each cycle, make sure we still have the same contents.
3247
3248 Unlike the other compaction tests, this one does not
3249 use -freespace.
3250
3251 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3252 test119
3253 Test behavior when Berkeley DB returns DB_BUFFER_SMALL on a cursor.
3254
3255 If the user-supplied buffer is not large enough to contain
3256 the returned value, DB returns BUFFER_SMALL. If it does,
3257 check that the cursor does not move -- if it moves, it will
3258 skip items. [#13815]
3259
3260 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3261 test120
3262 Test of multi-version concurrency control.
3263
3264 Test basic functionality: a snapshot transaction started
3265 before a regular transaction's put can't see the modification.
3266 A snapshot transaction started after the put can see it.
3267
3268 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3269 test121
3270 Tests of multi-version concurrency control.
3271
3272 MVCC and cursor adjustment.
3273 Set up a -snapshot cursor and position it in the middle
3274 of a database.
3275 Write to the database, both before and after the cursor,
3276 and verify that it stays on the same position.
3277
3278 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3279 test122
3280 Tests of multi-version concurrency control.
3281
3282 MVCC and databases that turn multi-version on and off.
3283
3284 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3285 test123
3286 Concurrent Data Store cdsgroup smoke test.
3287
3288 Open a CDS env with -cdb_alldb.
3289 Start a "txn" with -cdsgroup.
3290 Create two databases in the env, do a cursor put
3291 in both within the same txn. This should succeed.
3292
3293 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3294 test124
3295
3296 Test db->verify with noorderchk and orderchkonly flags.
3297
3298 Create a db with a non-standard sort order. Check that
3299 it fails a regular verify and succeeds with -noorderchk.
3300 Do a similar test with a db containing subdbs, one with
3301 the standard order and another with non-standard.
3302
3303 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3304 test125
3305 Test cursor comparison API.
3306
3307 The cursor comparison API reports whether two cursors within
3308 the same database are at the same position. It does not report
3309 any information about relative position.
3310
3311 1. Test two uninitialized cursors (error).
3312 2. Test one uninitialized cursor, one initialized (error).
3313 3. Test two cursors in different databases (error).
3314 4. Put two cursors in the same place, test for match. Walk
3315 them back and forth a bit, more matching.
3316 5. Two cursors in the same spot. Delete through one.
3317
3318 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3319 test126
3320 Test database bulk update for non-duplicate databases.
3321
3322 Put with -multiple, then with -multiple_key,
3323 and make sure the items in database are what we put.
3324 Later, delete some items with -multiple, then with -multiple_key,
3325 and make sure if the correct items are deleted.
3326
3327 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3328 test127
3329 Test database bulk update.
3330
3331 This is essentially test126 with duplicates.
3332 To make it simple we use numerical keys all the time.
3333
3334 Put with -multiple, then with -multiple_key,
3335 and make sure the items in database are what we want.
3336 Later, delete some items with -multiple, then with -multiple_key,
3337 and make sure if the correct items are deleted.
3338
3339 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3340 test128
3341 Test database bulk update for non-duplicate databases, with different
3342 configurations.
3343
3344 This is essentially test126 with the following configurations:
3345 * sub database.
3346 * secondary database.
3347 * bulk buffer pre-sort.
3348
3349 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3350 test129
3351 Test database bulk update for duplicate database, with different
3352 configurations.
3353
3354 This is essentially test127 with the following configurations:
3355 * sub database.
3356 * bulk buffer pre-sort.
3357
3358 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3359 test130
3360 Test moving of subdatabase metadata pages.
3361
3362 Populate num_db sub-database. Open multiple handles on each.
3363 Remove a high proportion of entries.
3364 Dump and save contents. Compact the database, dump again,
3365 and make sure we still have the same contents.
3366 Make sure handles and cursors still work after compaction.
3367
3368 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3369 test131
3370 Test foreign database operations.
3371 Create a foreign db, and put some records into it.
3372 Then associate the foreign db with a secondary db, and
3373 put records into the primary db.
3374 Do operations in the foreign db and check results.
3375 Finally, verify the foreign relation between the foreign db
3376 and secondary db.
3377 Here, we test three different foreign delete constraints:
3378 - DB_FOREIGN_ABORT
3379 - DB_FOREIGN_CASCADE
3380 - DB_FOREIGN_NULLIFY
3381
3382 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3383 test132
3384 Test foreign database operations on sub databases and
3385 in-memory databases.
3386
3387 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3388 test133
3389 Test Cursor Cleanup.
3390 Open a primary database and a secondary database,
3391 then open 3 cursors on the secondary database, and
3392 point them at the first item.
3393 Do the following operations in loops:
3394 * The 1st cursor will delete the current item.
3395 * The 2nd cursor will also try to delete the current item.
3396 * Move all the 3 cursors to get the next item and check the returns.
3397 Finally, move the 3rd cursor once.
3398
3399 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3400 test134
3401 Test cursor cleanup for sub databases.
3402
3403 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3404 test135
3405 Test operations on similar overflow records. [#20329]
3406 Open 3 kinds of databases: one is not dup, and one is dup-unsorted
3407 while another one is dup-sorted.
3408 Then we put some similar but not identical overflow records into
3409 these databases.
3410 Also, we try to remove some records from these databases.
3411 We'll verify the records after put and after deletion.
3412 Here is how we define the 'similar overflow' in this test:
3413 * Both the key.size and data.size are not small than DB's pagesize:
3414 The key.size is around 2*pagesize and data.size equals to pagesize.
3415 * The keys are of same length, and they only differ in a small piece.
3416 The location of difference could be in the start/middle/end.
3417 * For dup databases, the dup datas have same rule as the key rule
3418 mentioned above.
3419
3420 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3421 test136
3422 Test operations on similar overflow records. [#20329]
3423 Here, we use subdatabases.
3424
3425 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3426 test137
3427 Test Automatic Resource Management. [#16188][#20281]
3428 Open an environment, and open a database in it.
3429 Do some operations in the database, including:
3430 insert, dump, delete
3431 Close the environment without closing the database.
3432 Re-open the database and verify the records are the ones we expected.
3433
3434 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3435 test138
3436 Test Automatic Resource Management. [#16188][#20281]
3437 Here, we test the following cases:
3438 Non-encrypt for cds
3439 Non-encrypt for tds
3440 Encrypt for ds
3441 Encrypt for cds
3442 Encrypt for tds
3443
3444 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3445 test139
3446
3447 Verify an open database.
3448 Create and populate a database, leave open, and run
3449 db->verify.
3450 Delete half the data, verify, compact, verify again.
3451
3452 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3453 test140
3454 Test expansion and contraction of hash chains with
3455 deletion, compaction, and recovery.
3456
3457 On each cycle, populate a database to create reasonably
3458 long hash chains, say 8 - 10 entries. Delete some
3459 entries, check for consistency, compact, and check
3460 for consistency again. We both commit and abort the
3461 compact, and in the case of the abort, compare
3462 the recovered database to the pre-compact database.
3463
3464 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3465 test141
3466 Test moving a large part of a hash table to a continguous
3467 block of free pages.
3468
3469 Create a database with a btree and a hash subdb. Remove
3470 all the data from the first (btree) db and then compact
3471 to cause the hash db to get moved.
3472
3473 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3474 test142
3475 Tests exclusive database handles.
3476 1. Test that exclusive database handles return an error in incompatible
3477 environments.
3478 2. Test that an exclusive subdatabase handle does not block opening a
3479 handle on another database in the same file.
3480 3. Run script tests on a subdatabase with both wait and no wait
3481 configuration.
3482 4. Run script tests on a database with both wait and no wait
3483 configuration.
3484
3485 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3486 txn001
3487 Begin, commit, abort testing.
3488
3489 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3490 txn002
3491 Verify that read-only transactions do not write log records.
3492
3493 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3494 txn003
3495 Test abort/commit/prepare of txns with outstanding child txns.
3496
3497 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3498 txn004
3499 Test of wraparound txnids (txn001)
3500
3501 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3502 txn005
3503 Test transaction ID wraparound and recovery.
3504
3505 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3506 txn008
3507 Test of wraparound txnids (txn002)
3508
3509 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3510 txn009
3511 Test of wraparound txnids (txn003)
3512
3513 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3514 txn010
3515 Test DB_ENV->txn_checkpoint arguments/flags
3516
3517 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3518 txn011
3519 Test durable and non-durable txns.
3520 Test a mixed env (with both durable and non-durable
3521 dbs), then a purely non-durable env. Make sure commit
3522 and abort work, and that only the log records we
3523 expect are written.
3524 Test that we can't get a durable handle on an open ND
3525 database, or vice versa. Test that all subdb's
3526 must be of the same type (D or ND).
3527
3528 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3529 txn012
3530 Test txn->getname and txn->setname.
3531
3532 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3533 txn013
3534 Test of txns used in the wrong environment.
3535 Set up two envs. Start a txn in one env, and attempt to use it
3536 in the other env. Verify we get the appropriate error message.
3537
3538 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
3539 txn014
3540 Test of parent and child txns working on the same database.
3541 A txn that will become a parent create a database.
3542 A txn that will not become a parent creates another database.
3543 Start a child txn of the 1st txn.
3544 Verify that the parent txn is disabled while child is open.
3545 1. Child reads contents with child handle (should succeed).
3546 2. Child reads contents with parent handle (should succeed).
3547 Verify that the non-parent txn can read from its database,
3548 and that the child txn cannot.
3549 Return to the child txn.
3550 3. Child writes with child handle (should succeed).
3551 4. Child writes with parent handle (should succeed).
3552
3553 Commit the child, verify that the parent can write again.
3554 Check contents of database with a second child.