1# Automatically built by dist/s_test; may require local editing.
2
3
4=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
5backup
6	Test of hotbackup functionality. 
7
8	Do all the of the following tests with and without 
9	the -c (checkpoint) option.  Make sure that -c and 
10	-d (data_dir) are not allowed together. 
11
12	(1) Test that plain and simple hotbackup works. 
13	(2) Test with -data_dir (-d). 
14	(3) Test updating an existing hot backup (-u).
15	(4) Test with absolute path. 
16	(5) Test with DB_CONFIG (-D), setting log_dir (-l)
17	and data_dir (-d).
18	(6) DB_CONFIG and update.  
19	(7) Repeat hot backup (non-update) with DB_CONFIG and 
20	existing directories. 
21
22=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
23bigfile001
24	Create a database greater than 4 GB in size.  Close, verify.
25	Grow the database somewhat.  Close, reverify.  Lather, rinse,
26	repeat.  Since it will not work on all systems, this test is
27	not run by default.
28
29=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
30bigfile002
31	This one should be faster and not require so much disk space,
32	although it doesn't test as extensively.  Create an mpool file
33	with 1K pages.  Dirty page 6000000.  Sync.
34
35=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
36dbm
37	Historic DBM interface test.  Use the first 1000 entries from the
38	dictionary.  Insert each with self as key and data; retrieve each.
39	After all are entered, retrieve all; compare output to original.
40	Then reopen the file, re-retrieve everything.  Finally, delete
41	everything.
42
43=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
44dead001
45	Use two different configurations to test deadlock detection among a
46	variable number of processes.  One configuration has the processes
47	deadlocked in a ring.  The other has the processes all deadlocked on
48	a single resource.
49
50=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
51dead002
52	Same test as dead001, but use "detect on every collision" instead
53	of separate deadlock detector.
54
55=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
56dead003
57
58	Same test as dead002, but explicitly specify DB_LOCK_OLDEST and
59	DB_LOCK_YOUNGEST.  Verify the correct lock was aborted/granted.
60
61=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
62dead006
63	use timeouts rather than the normal dd algorithm.
64
65=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
66dead007
67	Tests for locker and txn id wraparound.
68
69=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
70env001
71	Test of env remove interface (formerly env_remove).
72
73=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
74env002
75	Test of DB_LOG_DIR and env name resolution.
76	With an environment path specified using -home, and then again
77	with it specified by the environment variable DB_HOME:
78	1) Make sure that the set_lg_dir option is respected
79	a) as a relative pathname.
80	b) as an absolute pathname.
81	2) Make sure that the DB_LOG_DIR db_config argument is respected,
82	again as relative and absolute pathnames.
83	3) Make sure that if -both- db_config and a file are present,
84	only the file is respected (see doc/env/naming.html).
85
86=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
87env003
88	Test DB_TMP_DIR and env name resolution
89	With an environment path specified using -home, and then again
90	with it specified by the environment variable DB_HOME:
91	1) Make sure that the DB_TMP_DIR config file option is respected
92	a) as a relative pathname.
93	b) as an absolute pathname.
94	2) Make sure that the -tmp_dir config option is respected,
95	again as relative and absolute pathnames.
96	3) Make sure that if -both- -tmp_dir and a file are present,
97	only the file is respected (see doc/env/naming.html).
98
99=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
100env004
101	Test multiple data directories.  Do a bunch of different opens
102	to make sure that the files are detected in different directories.
103
104=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
105env005
106	Test that using subsystems without initializing them correctly
107	returns an error.  Cannot test mpool, because it is assumed in
108	the Tcl code.
109
110=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
111env006
112	Make sure that all the utilities exist and run.
113	Test that db_load -r options don't blow up.
114
115=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
116env007
117	Test DB_CONFIG config file options for berkdb env.
118	1) Make sure command line option is respected
119	2) Make sure that config file option is respected
120	3) Make sure that if -both- DB_CONFIG and the set_<whatever>
121	method is used, only the file is respected.
122	Then test all known config options.
123	Also test config options on berkdb open.  This isn't
124	really env testing, but there's no better place to put it.
125
126=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
127env008
128	Test environments and subdirectories.
129
130=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
131env009
132	Test calls to all the various stat functions.  We have several
133	sprinkled throughout the test suite, but this will ensure that
134	we run all of them at least once.
135
136=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
137env010
138	Run recovery in an empty directory, and then make sure we can still
139	create a database in that directory.
140
141=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
142env011
143	Run with region overwrite flag.
144
145=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
146env012
147	Test DB_REGISTER.
148
149	DB_REGISTER will fail on systems without fcntl.  If it
150	fails, make sure we got the expected DB_OPNOTSUP return.
151
152	Then, the real tests:
153	For each test, we start a process that opens an env with -register.
154
155	1. Verify that a 2nd process can enter the existing env with -register.
156
157	2. Kill the 1st process, and verify that the 2nd process can enter
158	with "-register -recover".
159
160	3. Kill the 1st process, and verify that the 2nd process cannot
161	enter with just "-register".
162
163	4. While the 1st process is still running, a 2nd process enters
164	with "-register".  Kill the 1st process.  Verify that a 3rd process
165	can enter with "-register -recover".  Verify that the 3rd process,
166	entering, causes process 2 to fail with the message DB_RUNRECOVERY.
167
168	5. We had a bug where recovery was always run with -register
169	if there were empty slots in the process registry file.  Verify
170	that recovery doesn't automatically run if there is an empty slot.
171
172=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
173env013
174	Test of basic functionality of fileid_reset.
175
176	Create a database in an env.  Copy it to a new file within
177	the same env.  Reset the file id and make sure it has changed.
178
179=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
180env014
181
182	Make sure that attempts to open an environment with
183	incompatible flags (e.g. replication without transactions)
184	fail with the appropriate messages.
185
186	A new thread of control joining an env automatically
187	initializes the same subsystems as the original env.
188	Make sure that the attempt to change subsystems when
189	joining an env fails with the appropriate messages.
190
191=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
192env015
193	Rename the underlying directory of an env, make sure everything
194	still works.  Test runs with regular named databases and with
195	in-memory named databases.
196
197=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
198env016
199	Replication settings and DB_CONFIG
200
201	Create a DB_CONFIG for various replication settings.  Use
202	rep_stat or getter functions to verify they're set correctly.
203
204=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
205fop001.tcl
206	Test file system operations, combined in a transaction. [#7363]
207
208=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
209fop002.tcl
210	Test file system operations in the presence of bad permissions.
211
212=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
213fop003
214
215	Test behavior of create and truncate for compatibility
216	with sendmail.
217	1.  DB_TRUNCATE is not allowed with locking or transactions.
218	2.  Can -create into zero-length existing file.
219	3.  Can -create into non-zero-length existing file if and
220	only if DB_TRUNCATE is specified.
221
222=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
223fop004
224	Test of DB->rename(). (formerly test075)
225	Test that files can be renamed from one directory to another.
226	Test that files can be renamed using absolute or relative
227	pathnames.
228
229=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
230fop005
231	Test of DB->remove()
232	Formerly test080.
233	Test use of dbremove with and without envs, with absolute
234	and relative paths, and with subdirectories.
235
236=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
237fop006
238	Test file system operations in multiple simultaneous
239	transactions.  Start one transaction, do a file operation.
240	Start a second transaction, do a file operation.  Abort
241	or commit txn1, then abort or commit txn2, and check for
242	appropriate outcome.
243
244=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
245fop007
246	Test file system operations on named in-memory databases.
247	Combine two ops in one transaction.
248
249=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
250fop008
251	Test file system operations on named in-memory databases.
252	Combine two ops in one transaction.
253
254=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
255jointest
256	Test duplicate assisted joins.  Executes 1, 2, 3 and 4-way joins
257	with differing index orders and selectivity.
258
259	We'll test 2-way, 3-way, and 4-way joins and figure that if those
260	work, everything else does as well.  We'll create test databases
261	called join1.db, join2.db, join3.db, and join4.db.  The number on
262	the database describes the duplication -- duplicates are of the
263	form 0, N, 2N, 3N, ...  where N is the number of the database.
264	Primary.db is the primary database, and null.db is the database
265	that has no matching duplicates.
266
267	We should test this on all btrees, all hash, and a combination thereof
268
269=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
270lock001
271	Make sure that the basic lock tests work.  Do some simple gets
272	and puts for a single locker.
273
274=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
275lock002
276	Exercise basic multi-process aspects of lock.
277
278=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
279lock003
280	Exercise multi-process aspects of lock.  Generate a bunch of parallel
281	testers that try to randomly obtain locks;  make sure that the locks
282	correctly protect corresponding objects.
283
284=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
285lock004
286	Test locker ids wraping around.
287
288=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
289lock005
290	Check that page locks are being released properly.
291
292=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
293lock006
294	Test lock_vec interface.  We do all the same things that
295	lock001 does, using lock_vec instead of lock_get and lock_put,
296	plus a few more things like lock-coupling.
297	1.  Get and release one at a time.
298	2.  Release with put_obj (all locks for a given locker/obj).
299	3.  Release with put_all (all locks for a given locker).
300	Regularly check lock_stat to verify all locks have been
301	released.
302
303=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
304log001
305	Read/write log records.
306	Test with and without fixed-length, in-memory logging,
307	and encryption.
308
309=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
310log002
311	Tests multiple logs
312	Log truncation
313	LSN comparison and file functionality.
314
315=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
316log003
317	Verify that log_flush is flushing records correctly.
318
319=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
320log004
321	Make sure that if we do PREVs on a log, but the beginning of the
322	log has been truncated, we do the right thing.
323
324=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
325log005
326	Check that log file sizes can change on the fly.
327
328=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
329log006
330	Test log file auto-remove.
331	Test normal operation.
332	Test a long-lived txn.
333	Test log_archive flags.
334	Test db_archive flags.
335	Test turning on later.
336	Test setting via DB_CONFIG.
337
338=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
339log007
340	Test of in-memory logging bugs. [#11505]
341
342	Test db_printlog with in-memory logs.
343
344=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
345log008
346	Test what happens if a txn_ckp record falls into a
347	different log file than the DBREG_CKP records generated
348	by the same checkpoint.
349
350=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
351log009
352	Test of logging and getting log file version information.
353	Each time we cross a log file boundary verify we can
354	get the version via the log cursorlag.
355	Do this both forward and backward.
356
357=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
358memp001
359	Randomly updates pages.
360
361=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
362memp002
363	Tests multiple processes accessing and modifying the same files.
364
365=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
366memp003
367	Test reader-only/writer process combinations; we use the access methods
368	for testing.
369
370=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
371memp004
372	Test that small read-only databases are mapped into memory.
373
374=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
375plat001
376
377	Test of portability of sequences.
378
379	Create and dump a database containing sequences.  Save the dump.
380	This test is used in conjunction with the upgrade tests, which
381	will compare the saved dump to a locally created dump.
382
383=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
384recd001
385	Per-operation recovery tests for non-duplicate, non-split
386	messages.  Makes sure that we exercise redo, undo, and do-nothing
387	condition.  Any test that appears with the message (change state)
388	indicates that we've already run the particular test, but we are
389	running it again so that we can change the state of the data base
390	to prepare for the next test (this applies to all other recovery
391	tests as well).
392
393	These are the most basic recovery tests.  We do individual recovery
394	tests for each operation in the access method interface.  First we
395	create a file and capture the state of the database (i.e., we copy
396	it.  Then we run a transaction containing a single operation.  In
397	one test, we abort the transaction and compare the outcome to the
398	original copy of the file.  In the second test, we restore the
399	original copy of the database and then run recovery and compare
400	this against the actual database.
401
402=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
403recd002
404	Split recovery tests.  For every known split log message, makes sure
405	that we exercise redo, undo, and do-nothing condition.
406
407=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
408recd003
409	Duplicate recovery tests.  For every known duplicate log message,
410	makes sure that we exercise redo, undo, and do-nothing condition.
411
412	Test all the duplicate log messages and recovery operations.  We make
413	sure that we exercise all possible recovery actions: redo, undo, undo
414	but no fix necessary and redo but no fix necessary.
415
416=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
417recd004
418	Big key test where big key gets elevated to internal page.
419
420=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
421recd005
422	Verify reuse of file ids works on catastrophic recovery.
423
424	Make sure that we can do catastrophic recovery even if we open
425	files using the same log file id.
426
427=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
428recd006
429	Nested transactions.
430
431=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
432recd007
433	File create/delete tests.
434
435	This is a recovery test for create/delete of databases.  We have
436	hooks in the database so that we can abort the process at various
437	points and make sure that the transaction doesn't commit.  We
438	then need to recover and make sure the file is correctly existing
439	or not, as the case may be.
440
441=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
442recd008
443	Test deeply nested transactions and many-child transactions.
444
445=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
446recd009
447	Verify record numbering across split/reverse splits and recovery.
448
449=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
450recd010
451	Test stability of btree duplicates across btree off-page dup splits
452	and reverse splits and across recovery.
453
454=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
455recd011
456	Verify that recovery to a specific timestamp works.
457
458=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
459recd012
460	Test of log file ID management. [#2288]
461	Test recovery handling of file opens and closes.
462
463=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
464recd013
465	Test of cursor adjustment on child transaction aborts. [#2373]
466
467=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
468recd014
469	This is a recovery test for create/delete of queue extents.  We
470	then need to recover and make sure the file is correctly existing
471	or not, as the case may be.
472
473=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
474recd015
475	This is a recovery test for testing lots of prepared txns.
476	This test is to force the use of txn_recover to call with the
477	DB_FIRST flag and then DB_NEXT.
478
479=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
480recd016
481	Test recovery after checksum error.
482
483=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
484recd017
485	Test recovery and security.  This is basically a watered
486	down version of recd001 just to verify that encrypted environments
487	can be recovered.
488
489=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
490recd018
491	Test recover of closely interspersed checkpoints and commits.
492
493=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
494recd019
495	Test txn id wrap-around and recovery.
496
497=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
498recd020
499	Test creation of intermediate directories -- an
500	undocumented, UNIX-only feature.
501
502=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
503recd021
504	Test of failed opens in recovery.
505
506	If a file was deleted through the file system (and not
507	within Berkeley DB), an error message should appear.
508	Test for regular files and subdbs.
509
510=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
511recd022
512	Test that pages allocated by an aborted subtransaction
513	within an aborted prepared parent transaction are returned
514	to the free list after recovery.  This exercises
515	__db_pg_prepare in systems without FTRUNCATE.  [#7403]
516
517=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
518recd023
519	Test recover of reverse split.
520
521=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
522rep001
523	Replication rename and forced-upgrade test.
524
525	Run rep_test in a replicated master environment.
526	Verify that the database on the client is correct.
527	Next, remove the database, close the master, upgrade the
528	client, reopen the master, and make sure the new master can
529	correctly run rep_test and propagate it in the other direction.
530
531=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
532rep002
533	Basic replication election test.
534
535	Run a modified version of test001 in a replicated master
536	environment; hold an election among a group of clients to
537	make sure they select a proper master from amongst themselves,
538	in various scenarios.
539
540=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
541rep003
542	Repeated shutdown/restart replication test
543
544	Run a quick put test in a replicated master environment;
545	start up, shut down, and restart client processes, with
546	and without recovery.  To ensure that environment state
547	is transient, use DB_PRIVATE.
548
549=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
550rep005
551	Replication election test with error handling.
552
553	Run a modified version of test001 in a replicated master environment;
554	hold an election among a group of clients to make sure they select
555	a proper master from amongst themselves, forcing errors at various
556	locations in the election path.
557
558=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
559rep006
560	Replication and non-rep env handles.
561
562	Run a modified version of test001 in a replicated master
563	environment; verify that the database on the client is correct.
564	Next, create a non-rep env handle to the master env.
565	Attempt to open the database r/w to force error.
566
567=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
568rep007
569	Replication and bad LSNs
570
571	Run rep_test in a replicated master env.
572	Close the client.  Make additional changes to master.
573	Close the master.  Open the client as the new master.
574	Make several different changes.  Open the old master as
575	the client.  Verify periodically that contents are correct.
576
577=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
578rep008
579	Replication, back up and synchronizing
580
581	Run a modified version of test001 in a replicated master
582	environment.
583	Close master and client.
584	Copy the master log to the client.
585	Clean the master.
586	Reopen the master and client.
587
588=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
589rep009
590	Replication and DUPMASTERs
591	Run test001 in a replicated environment.
592
593	Declare one of the clients to also be a master.
594	Close a client, clean it and then declare it a 2nd master.
595
596=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
597rep010
598	Replication and ISPERM
599
600	With consecutive message processing, make sure every
601	DB_REP_PERMANENT is responded to with an ISPERM when
602	processed.  With gaps in the processing, make sure
603	every DB_REP_PERMANENT is responded to with an ISPERM
604	or a NOTPERM.  Verify in both cases that the LSN returned
605	with ISPERM is found in the log.
606
607=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
608rep011
609	Replication: test open handle across an upgrade.
610
611	Open and close test database in master environment.
612	Update the client.  Check client, and leave the handle
613	to the client open as we close the masterenv and upgrade
614	the client to master.  Reopen the old master as client
615	and catch up.  Test that we can still do a put to the
616	handle we created on the master while it was still a
617	client, and then make sure that the change can be
618	propagated back to the new client.
619
620=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
621rep012
622	Replication and dead DB handles.
623
624	Run a modified version of test001 in a replicated master env.
625	Run in replicated environment with secondary indices too.
626	Make additional changes to master, but not to the client.
627	Downgrade the master and upgrade the client with open db handles.
628	Verify that the roll back on clients gives dead db handles.
629
630=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
631rep013
632	Replication and swapping master/clients with open dbs.
633
634	Run a modified version of test001 in a replicated master env.
635	Make additional changes to master, but not to the client.
636	Swap master and client.
637	Verify that the roll back on clients gives dead db handles.
638	Rerun the test, turning on client-to-client synchronization.
639	Swap and verify several times.
640
641=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
642rep014
643	Replication and multiple replication handles.
644	Test multiple client handles, opening and closing to
645	make sure we get the right openfiles.
646
647=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
648rep015
649	Locking across multiple pages with replication.
650
651	Open master and client with small pagesize and
652	generate more than one page and generate off-page
653	dups on the first page (second key) and last page
654	(next-to-last key).
655	Within a single transaction, for each database, open
656	2 cursors and delete the first and last entries (this
657	exercises locks on regular pages).  Intermittently
658	update client during the process.
659	Within a single transaction, for each database, open
660	2 cursors.  Walk to the off-page dups and delete one
661	from each end (this exercises locks on off-page dups).
662	Intermittently update client.
663
664=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
665rep016
666	Replication election test with varying required nvotes.
667
668	Run a modified version of test001 in a replicated master environment;
669	hold an election among a group of clients to make sure they select
670	the master with varying required participants.
671
672=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
673rep017
674	Concurrency with checkpoints.
675
676	Verify that we achieve concurrency in the presence of checkpoints.
677	Here are the checks that we wish to make:
678	While dbenv1 is handling the checkpoint record:
679	Subsequent in-order log records are accepted.
680	Accepted PERM log records get NOTPERM
681	A subsequent checkpoint gets NOTPERM
682	After checkpoint completes, next txn returns PERM
683
684=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
685rep018
686	Replication with dbremove.
687
688	Verify that the attempt to remove a database file
689	on the master hangs while another process holds a
690	handle on the client.
691
692
693=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
694rep019
695	Replication and multiple clients at same LSN.
696	Have several clients at the same LSN.  Run recovery at
697	different times.  Declare a client master and after sync-up
698	verify all client logs are identical.
699
700=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
701rep020
702	Replication elections - test election generation numbers.
703
704
705=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
706rep021
707	Replication and multiple environments.
708	Run similar tests in separate environments, making sure
709	that some data overlaps.  Then, "move" one client env
710	from one replication group to another and make sure that
711	we do not get divergent logs.  We either match the first
712	record and end up with identical logs or we get an error.
713	Verify all client logs are identical if successful.
714
715=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
716rep022
717	Replication elections - test election generation numbers
718	during simulated network partition.
719
720
721=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
722rep023
723	Replication using two master handles.
724
725	Open two handles on one master env.  Create two
726	databases, one through each master handle.  Process
727	all messages through the first master handle.  Make
728	sure changes made through both handles are picked
729	up properly.
730
731=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
732rep024
733	Replication page allocation / verify test
734
735	Start a master (site 1) and a client (site 2).  Master
736	closes (simulating a crash).  Site 2 becomes the master
737	and site 1 comes back up as a client.  Verify database.
738
739=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
740rep025
741	Test of DB_REP_JOIN_FAILURE.
742
743	One master, one client.
744	Generate several log files.
745	Remove old master log files.
746	Delete client files and restart client.
747	Put one more record to the master.  At the next
748	processing of messages, the client should get JOIN_FAILURE.
749	Recover with a hot failover.
750
751=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
752rep026
753	Replication elections - simulate a crash after sending
754	a vote.
755
756=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
757rep027
758	Replication and secondary indexes.
759
760	Set up a secondary index on the master and make sure
761	it can be accessed from the client.
762
763=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
764rep028
765	Replication and non-rep env handles. (Also see rep006.)
766
767	Open second non-rep env on client, and create a db
768	through this handle.  Open the db on master and put
769	some data.  Check whether the non-rep handle keeps
770	working.  Also check if opening the client database
771	in the non-rep env writes log records.
772
773=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
774rep029
775	Test of internal initialization.
776
777	One master, one client.
778	Generate several log files.
779	Remove old master log files.
780	Delete client files and restart client.
781	Put one more record to the master.
782
783=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
784rep030
785	Test of internal initialization multiple files and pagesizes.
786	Hold some databases open on master.
787
788	One master, one client using a data_dir for internal init.
789	Generate several log files.
790	Remove old master log files.
791	Delete client files and restart client.
792	Put one more record to the master.
793
794=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
795rep031
796	Test of internal initialization and blocked operations.
797
798	One master, one client.
799	Put one more record to the master.
800	Test that internal initialization blocks:
801	log_archive, rename, remove, fileid_reset, lsn_reset.
802	Sleep 30+ seconds.
803	Test that blocked operations are now unblocked.
804
805=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
806rep032
807	Test of log gap processing.
808
809	One master, one client.
810	Run rep_test.
811	Run rep_test without sending messages to client.
812	Make sure client missing the messages catches up properly.
813
814=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
815rep033
816	Test of internal initialization with rename and remove of dbs.
817
818	One master, one client.
819	Generate several databases.  Replicate to client.
820	Do some renames and removes, both before and after
821	closing the client.
822
823=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
824rep034
825	Test of STARTUPDONE notification.
826
827	STARTUPDONE can now be recognized without the need for new "live" log
828	records from the master (under favorable conditions).  The response to
829	the ALL_REQ at the end of synchronization includes an end-of-log marker
830	that now triggers it.  However, the message containing that end marker
831	could get lost, so live log records still serve as a back-up mechanism.
832	The end marker may also be set under c2c sync, but only if the serving
833	client has itself achieved STARTUPDONE.
834
835=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
836rep035
837	Test sync-up recovery in replication.
838
839	We need to fork off 3 child tclsh processes to operate
840	on Site 3's (client always) home directory:
841	Process 1 continually calls lock_detect.
842	Process 2 continually calls txn_checkpoint.
843	Process 3 continually calls memp_trickle.
844	Process 4 continually calls log_archive.
845	Sites 1 and 2 will continually swap being master
846	(forcing site 3 to continually run sync-up recovery)
847	New master performs 1 operation, replicates and downgrades.
848
849=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
850rep036
851	Multiple master processes writing to the database.
852	One process handles all message processing.
853
854=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
855rep037
856	Test of internal initialization and page throttling.
857
858	One master, one client, force page throttling.
859	Generate several log files.
860	Remove old master log files.
861	Delete client files and restart client.
862	Put one more record to the master.
863	Verify page throttling occurred.
864
865=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
866rep038
867	Test of internal initialization and ongoing master updates.
868
869	One master, one client.
870	Generate several log files.
871	Remove old master log files.
872	Delete client files and restart client.
873	Put more records on master while initialization is in progress.
874
875=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
876rep039
877	Test of interrupted internal initialization changes.  The
878	interruption is due to a changed master, or the client crashing,
879	or both.
880
881	One master, two clients.
882	Generate several log files. Remove old master log files.
883	Restart client, optionally having "cleaned" client env dir.  Either
884	way, this has the effect of forcing an internal init.
885	Interrupt the internal init.
886	Vary the number of times we process messages to make sure
887	the interruption occurs at varying stages of the first internal
888	initialization.
889
890	Run for btree and queue only because of the number of permutations.
891
892
893=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
894rep040
895	Test of racing rep_start and transactions.
896
897	One master, one client.
898	Have master in the middle of a transaction.
899	Call rep_start to make master a client.
900	Commit the transaction.
901	Call rep_start to make master the master again.
902
903=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
904rep041
905	Turn replication on and off at run-time.
906
907	Start a master with replication OFF (noop transport function).
908	Run rep_test to advance log files and archive.
909	Start up client; change master to working transport function.
910	Now replication is ON.
911	Do more ops, make sure client is up to date.
912	Close client, turn replication OFF on master, do more ops.
913	Repeat from point A.
914
915=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
916rep042
917	Concurrency with updates.
918
919	Verify racing role changes and updates don't result in
920	pages with LSN 0,1.  Set up an environment that is master.
921	Spawn child process that does a delete, but using the
922	$env check so that it sleeps in the middle of the call.
923	Master downgrades and then sleeps as a client so that
924	child will run.  Verify child does not succeed (should
925	get read-only error) due to role change in the middle of
926	its call.
927
928=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
929rep043
930
931	Constant writes during upgrade/downgrade.
932
933	Three envs take turns being master.  Each env
934	has a child process which does writes all the
935	time.  They will succeed when that env is master
936	and fail when it is not.
937
938=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
939rep044
940
941	Test rollbacks with open file ids.
942
943	We have one master with two handles and one client.
944	Each time through the main loop, we open a db, write
945	to the db, and close the db.  Each one of these actions
946	is propagated to the client, or a roll back is forced
947	by swapping masters.
948
949=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
950rep045
951
952	Replication with versions.
953
954	Mimic an application where a database is set up in the
955	background and then put into a replication group for use.
956	The "version database" identifies the current live
957	version, the database against which queries are made.
958	For example, the version database might say the current
959	version is 3, and queries would then be sent to db.3.
960	Version 4 is prepared for use while version 3 is in use.
961	When version 4 is complete, the version database is updated
962	to point to version 4 so queries can be directed there.
963
964	This test has a master and two clients.  One client swaps
965	roles with the master, and the other client runs constantly
966	in another process.
967
968=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
969rep046
970	Replication and basic bulk transfer.
971	Set bulk transfer replication option.
972	Run long txns on master and then commit.  Process on client
973	and verify contents.  Run a very long txn so that logging
974	must send the log.  Process and verify on client.
975
976=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
977rep047
978	Replication and log gap bulk transfers.
979	Set bulk transfer replication option.
980	Run test.  Start a new client (to test ALL_REQ and bulk).
981	Run small test again.  Clear messages for 1 client.
982	Run small test again to test LOG_REQ gap processing and bulk.
983	Process and verify on clients.
984
985=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
986rep048
987	Replication and log gap bulk transfers.
988	Have two master env handles.  Turn bulk on in
989	one (turns it on for both).  Turn it off in the other.
990	While toggling, send log records from both handles.
991	Process message and verify master and client match.
992
993=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
994rep049
995	Replication and delay syncing clients - basic test.
996
997	Open and start up a master and two clients.  Turn on delay sync
998	in the delayed client.  Change master, add data and process messages.
999	Verify delayed client does not match.  Make additional changes and
1000	update the delayted client.  Verify all match.
1001	Add in a fresh delayed client to test delay of ALL_REQ.
1002	Process startup messages and verify freshc client has no database.
1003	Sync and verify fresh client matches.
1004
1005=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1006rep050
1007	Replication and delay syncing clients - change master test.
1008
1009	Open and start up master and 4 clients.  Turn on delay for 3 clients.
1010	Switch masters, add data and verify delayed clients are out of date.
1011	Make additional changes to master.  And change masters again.
1012	Sync/update delayed client and verify.  The 4th client is a brand
1013	new delayed client added in to test the non-verify path.
1014
1015	Then test two different things:
1016	1. Swap master again while clients are still delayed.
1017	2. Swap master again while sync is proceeding for one client.
1018
1019=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1020rep051
1021	Test of compaction with replication.
1022
1023	Run rep_test in a replicated master environment.
1024	Delete a large number of entries and compact with -freespace.
1025	Propagate the changes to the client and make sure client and
1026	master match.
1027
1028=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1029rep052
1030	Test of replication with NOWAIT.
1031
1032	One master, one client.  After initializing
1033	everything normally, close client and let the
1034	master get ahead -- far enough that the master
1035	no longer has the client's last log file.
1036	Reopen the client and turn on NOWAIT.
1037	Process a few messages to get the client into
1038	recovery mode, and verify that lockout occurs
1039	on a txn API call (txn_begin) and an env API call.
1040	Process all the messages and verify that lockout
1041	is over.
1042
1043=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1044rep053
1045	Replication and basic client-to-client synchronization.
1046
1047	Open and start up master and 1 client.
1048	Start up a second client later and verify it sync'ed from
1049	the original client, not the master.
1050
1051=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1052rep054
1053	Test of internal initialization where a far-behind
1054	client takes over as master.
1055
1056	One master, two clients.
1057	Run rep_test and process.
1058	Close client 1.
1059	Run rep_test, opening new databases, and processing
1060	messages.  Archive as we go so that log files get removed.
1061	Close master and reopen client 1 as master.  Process messages.
1062	Verify that new master and client are in sync.
1063	Run rep_test again, adding data to one of the new
1064	named databases.
1065
1066=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1067rep055
1068	Test of internal initialization and log archiving.
1069
1070	One master, one client.
1071	Generate several log files.
1072	Remove old master log files and generate several more.
1073	Get list of archivable files from db_archive and restart client.
1074	As client is in the middle of internal init, remove
1075	the log files returned earlier by db_archive.
1076
1077=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1078rep056
1079	Replication test with in-memory named databases.
1080
1081	Rep056 is just a driver to run rep001 with in-memory
1082	named databases.
1083
1084=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1085rep057
1086	Replication test of internal initialization with
1087	in-memory named databases.
1088
1089	Rep057 is just a driver to run rep029 with in-memory
1090	named databases.
1091
1092=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1093rep058
1094
1095	Replication with early databases
1096
1097	Mimic an application where they create a database before
1098	calling rep_start, thus writing log records on a client
1099	before it is a client.  Verify we cannot join repl group.
1100
1101=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1102rep060
1103	Test of normally running clients and internal initialization.
1104	Have a client running normally, but slow/far behind the master.
1105	Then the master checkpoints and archives, causing the client
1106	to suddenly be thrown into internal init.  This test tests
1107	that we clean up the old files/pages in mpool and dbreg.
1108	Also test same thing but the app holding an open dbp as well.
1109
1110=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1111rep061
1112	Test of internal initialization multiple files and pagesizes
1113	with page gaps.
1114
1115	One master, one client.
1116	Generate several log files.
1117	Remove old master log files.
1118	Delete client files and restart client.
1119	Put one more record to the master.
1120	Force some page messages to get dropped.
1121
1122=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1123rep062
1124	Test of internal initialization where client has a different
1125	kind of database than the master.
1126
1127	Create a master of one type, and let the client catch up.
1128	Close the client.
1129	Remove the database on the master, and create a new
1130	database of the same name but a different type.
1131	Run the master ahead far enough that internal initialization
1132	will be required on the reopen of the client.
1133	Reopen the client and verify.
1134
1135=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1136rep063
1137	Replication election test with simulated different versions
1138	for each site.  This tests that old sites with real priority
1139	trump ELECTABLE sites with zero priority even with greater LSNs.
1140	There is a special case in the code for testing that if the
1141	priority is <= 10, we simulate mixed versions for elections.
1142
1143	Run a rep_test in a replicated master environment and close;
1144	hold an election among a group of clients to make sure they select
1145	the master with varying LSNs and priorities.
1146
1147=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1148rep064
1149	Replication rename and forced-upgrade test.
1150
1151	The test verifies that the client correctly
1152	(internally) closes files when upgrading to master.
1153	It does this by having the master have a database
1154	open, then crashing.  The client upgrades to master,
1155	and attempts to remove the open database.
1156
1157=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1158rep065
1159	Tests replication running with different versions.
1160	This capability is introduced with 4.5.
1161
1162	Start a replication group of 1 master and N sites, all
1163	running some historical version greater than or equal to 4.4.
1164	Take down a client and bring it up again running current.
1165	Run some upgrades, make sure everything works.
1166
1167	Each site runs the tcllib of its own version, but uses
1168	the current tcl code (e.g. test.tcl).
1169
1170=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1171rep066
1172	Replication and dead log handles.
1173
1174	Run rep_test on master and a client.
1175	Simulate client crashes (master continues) until log 2.
1176	Open 2nd master env handle and put something in log and flush.
1177	Downgrade master, restart client as master.
1178	Run rep_test on newmaster until log 2.
1179	New master writes log records, newclient processes records
1180	and 2nd newclient env handle calls log_flush.
1181	New master commits, newclient processes and should succeed.
1182	Make sure 2nd handle detects the old log handle and doesn't
1183	write to a stale handle (if it does, the processing of the
1184	commit will fail).
1185
1186=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1187rep067
1188	Replication election test with large timeouts.
1189
1190	Test replication elections among clients with widely varying
1191	timeouts.  This test is used to simulate a customer that
1192	wants to force full participation in an election, but only
1193	if all sites are present (i.e. if all sites are restarted
1194	together).  If any site has already been part of the group,
1195	then we want to be able to elect a master based on majority.
1196	Using varied timeouts, we can force full participation if
1197	all sites are present with "long_timeout" amount of time and
1198	then revert to majority.
1199
1200	A long_timeout would be several minutes whereas a normal
1201	short timeout would be a few seconds.
1202
1203=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1204rep068
1205	Verify replication of dbreg operations does not hang clients.
1206	In a simple replication group, create a database with very
1207	little data.  With DB_TXN_NOSYNC the database can be created
1208	at the client even though the log is not flushed.  If we crash
1209	and restart, the application of the log starts over again, even
1210	though the database is still there.  The application can open
1211	the database before replication tries to re-apply the create.
1212	This causes a hang as replication waits to be able to get a
1213	handle lock.
1214
1215	Run for btree only because access method shouldn't matter.
1216
1217
1218=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1219rep069
1220	Test of internal initialization and elections.
1221
1222	If a client is in a recovery mode of any kind, it
1223	participates in elections at priority 0 so it can
1224	never be elected master.
1225
1226=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1227rep070
1228	Test of startup_done condition with idle master.
1229
1230	Join a client to an existing master, and verify that
1231	the client detects startup_done even if the master
1232	does not execute any new transactions.
1233
1234=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1235rep071
1236	Test of multiple simultaneous client env handles and
1237	upgrading/downgrading.  Tests use of temp db handle
1238	internally.
1239
1240	Open a master and 2 handles to the same client env.
1241	Run rep_test.
1242	Close master and upgrade client to master using one env handle.
1243	Run rep_test again, and then downgrade back to client.
1244
1245=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1246rep072
1247	Verify that internal init does not leak resources from
1248	the locking subsystem.
1249
1250=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1251rep073
1252
1253	Test of allowing clients to create and update their own scratch
1254	databases within the environment.  Doing so requires the use
1255	use of the DB_TXN_NOT_DURABLE flag for those databases.
1256
1257=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1258rep074
1259	Verify replication withstands send errors processing requests.
1260
1261	Run for btree only because access method shouldn't matter.
1262
1263
1264=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1265rep075
1266	Replication and prepared transactions.
1267	Test having outstanding prepared transactions and simulating
1268	crashing or upgrading or downgrading sites.
1269
1270
1271=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1272rep076
1273	Replication elections - what happens if elected client
1274	does not become master?
1275
1276	Set up a master and 3 clients.  Take down master, run election.
1277	The elected client will ignore the fact that it's been elected,
1278	so we still have 2 clients.
1279
1280	Run another election, a regular election that allows the winner
1281	to become master, and make sure it goes okay.  We do this both
1282	for the client that ignored its election and for the other client.
1283
1284	This simulates what would happen if, say, we had a temporary
1285	network partition and lost the winner.
1286
1287=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1288rep077
1289
1290	Replication, recovery and applying log records immediately.
1291	Master and 1 client.  Start up both sites.
1292	Close client and run rep_test on the master so that the
1293	log record is the same LSN the client would be expecting.
1294	Reopen client with recovery and verify the client does not
1295	try to apply that "expected" record before it synchronizes
1296	with the master.
1297
1298=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1299rep078
1300
1301	Replication and basic lease test.
1302	Set leases on master and 2 clients.
1303	Do a lease operation and process to all clients.
1304	Read with lease on master.  Do another lease operation
1305	and don't process on any client.  Try to read with
1306	on the master and verify it fails.  Process the messages
1307	to the clients and retry the read.
1308
1309=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1310rep079
1311	Replication leases and invalid usage.
1312
1313	Open a client without leases.  Attempt to set leases after rep_start.
1314	Attempt to declare as master without election.
1315	Run an election with an nsites parameter value.
1316	Elect a master with leases.  Put some data and send to clients.
1317	Cleanly shutdown master env.  Restart without
1318	recovery and verify leases are expired and refreshed.
1319	Add a new client without leases to a group using leases.
1320
1321=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1322rep080
1323	NOAUTOINIT with empty client logs.
1324
1325	Verify that a fresh client trying to join the group for
1326	the first time observes the setting of DELAY_SYNC and NOAUTOINIT
1327	properly.
1328
1329
1330=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1331repmgr001
1332	Check repmgr stats.
1333
1334	Run for btree only because access method shouldn't matter.
1335
1336
1337=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1338rpc001
1339	Test RPC server timeouts for cursor, txn and env handles.
1340
1341=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1342rpc002
1343	Test invalid RPC functions and make sure we error them correctly
1344	Test server home directory error cases
1345
1346=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1347rpc003
1348	Test RPC and secondary indices.
1349
1350=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1351rpc004
1352	Test RPC server and security
1353
1354=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1355rpc005
1356	Test RPC server handle ID sharing
1357
1358=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1359rpc006
1360	Test RPC server and multiple operations to server.
1361	Make sure the server doesn't deadlock itself, but
1362	returns DEADLOCK to the client.
1363
1364=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1365rsrc001
1366	Recno backing file test.  Try different patterns of adding
1367	records and making sure that the corresponding file matches.
1368
1369=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1370rsrc002
1371	Recno backing file test #2: test of set_re_delim.  Specify a backing
1372	file with colon-delimited records, and make sure they are correctly
1373	interpreted.
1374
1375=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1376rsrc003
1377	Recno backing file test.  Try different patterns of adding
1378	records and making sure that the corresponding file matches.
1379
1380=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1381rsrc004
1382	Recno backing file test for EOF-terminated records.
1383
1384=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1385scr###
1386	The scr### directories are shell scripts that test a variety of
1387	things, including things about the distribution itself.  These
1388	tests won't run on most systems, so don't even try to run them.
1389
1390=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1391sdb001	Tests mixing db and subdb operations
1392	Tests mixing db and subdb operations
1393	Create a db, add data, try to create a subdb.
1394	Test naming db and subdb with a leading - for correct parsing
1395	Existence check -- test use of -excl with subdbs
1396
1397	Test non-subdb and subdb operations
1398	Test naming (filenames begin with -)
1399	Test existence (cannot create subdb of same name with -excl)
1400
1401=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1402sdb002
1403	Tests basic subdb functionality
1404	Small keys, small data
1405	Put/get per key
1406	Dump file
1407	Close, reopen
1408	Dump file
1409
1410	Use the first 10,000 entries from the dictionary.
1411	Insert each with self as key and data; retrieve each.
1412	After all are entered, retrieve all; compare output to original.
1413	Close file, reopen, do retrieve and re-verify.
1414	Then repeat using an environment.
1415
1416=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1417sdb003
1418	Tests many subdbs
1419	Creates many subdbs and puts a small amount of
1420	data in each (many defaults to 1000)
1421
1422	Use the first 1000 entries from the dictionary as subdbnames.
1423	Insert each with entry as name of subdatabase and a partial list
1424	as key/data.  After all are entered, retrieve all; compare output
1425	to original.  Close file, reopen, do retrieve and re-verify.
1426
1427=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1428sdb004
1429	Tests large subdb names
1430	subdb name = filecontents,
1431	key = filename, data = filecontents
1432	Put/get per key
1433	Dump file
1434	Dump subdbs, verify data and subdb name match
1435
1436	Create 1 db with many large subdbs.  Use the contents as subdb names.
1437	Take the source files and dbtest executable and enter their names as
1438	the key with their contents as data.  After all are entered, retrieve
1439	all; compare output to original. Close file, reopen, do retrieve and
1440	re-verify.
1441
1442=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1443sdb005
1444	Tests cursor operations in subdbs
1445	Put/get per key
1446	Verify cursor operations work within subdb
1447	Verify cursor operations do not work across subdbs
1448
1449
1450=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1451sdb006
1452	Tests intra-subdb join
1453
1454	We'll test 2-way, 3-way, and 4-way joins and figure that if those work,
1455	everything else does as well.  We'll create test databases called
1456	sub1.db, sub2.db, sub3.db, and sub4.db.  The number on the database
1457	describes the duplication -- duplicates are of the form 0, N, 2N, 3N,
1458	...  where N is the number of the database.  Primary.db is the primary
1459	database, and sub0.db is the database that has no matching duplicates.
1460	All of these are within a single database.
1461
1462=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1463sdb007
1464	Tests page size difference errors between subdbs.
1465	If the physical file already exists, we ignore pagesize specifications
1466	on any subsequent -creates.
1467
1468	1.  Create/open a subdb with system default page size.
1469	Create/open a second subdb specifying a different page size.
1470	The create should succeed, but the pagesize of the new db
1471	will be the system default page size.
1472	2.  Create/open a subdb with a specified, non-default page size.
1473	Create/open a second subdb specifying a different page size.
1474	The create should succeed, but the pagesize of the new db
1475	will be the specified page size from the first create.
1476
1477=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1478sdb008
1479	Tests explicit setting of lorders for subdatabases -- the
1480	lorder should be ignored.
1481
1482=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1483sdb009
1484	Test DB->rename() method for subdbs
1485
1486=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1487sdb010
1488	Test DB->remove() method and DB->truncate() for subdbs
1489
1490=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1491sdb011
1492	Test deleting Subdbs with overflow pages
1493	Create 1 db with many large subdbs.
1494	Test subdatabases with overflow pages.
1495
1496=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1497sdb012
1498	Test subdbs with locking and transactions
1499	Tests creating and removing subdbs while handles
1500	are open works correctly, and in the face of txns.
1501
1502=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1503sdb013
1504	Tests in-memory subdatabases.
1505	Create an in-memory subdb.  Test for persistence after
1506	overflowing the cache.  Test for conflicts when we have
1507	two in-memory files.
1508
1509=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1510sdb014
1511	Tests mixing in-memory named and in-memory unnamed dbs.
1512	Create a regular in-memory db, add data.
1513	Create a named in-memory db.
1514	Try to create the same named in-memory db again (should fail).
1515	Try to create a different named in-memory db (should succeed).
1516
1517
1518=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1519sdb015
1520	Tests basic in-memory named database functionality
1521	Small keys, small data
1522	Put/get per key
1523
1524	Use the first 10,000 entries from the dictionary.
1525	Insert each with self as key and data; retrieve each.
1526	After all are entered, retrieve all; compare output to original.
1527	Close file, reopen, do retrieve and re-verify.
1528	Then repeat using an environment.
1529
1530=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1531sdb016
1532	Creates many in-memory named dbs and puts a small amount of
1533	data in each (many defaults to 100)
1534
1535	Use the first 100 entries from the dictionary as names.
1536	Insert each with entry as name of subdatabase and a partial list
1537	as key/data.  After all are entered, retrieve all; compare output
1538	to original.
1539
1540=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1541sdb017
1542	Test DB->rename() for in-memory named databases.
1543
1544=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1545sdb018
1546	Tests join of in-memory named databases.
1547
1548	We'll test 2-way, 3-way, and 4-way joins and figure that if those work,
1549	everything else does as well.  We'll create test databases called
1550	sub1.db, sub2.db, sub3.db, and sub4.db.  The number on the database
1551	describes the duplication -- duplicates are of the form 0, N, 2N, 3N,
1552	...  where N is the number of the database.  Primary.db is the primary
1553	database, and sub0.db is the database that has no matching duplicates.
1554	All of these are within a single database.
1555
1556=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1557sdb019
1558	Tests in-memory subdatabases.
1559	Create an in-memory subdb.  Test for persistence after
1560	overflowing the cache.  Test for conflicts when we have
1561	two in-memory files.
1562
1563=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1564sdb020
1565	Tests in-memory subdatabases.
1566	Create an in-memory subdb with one page size.  Close, and
1567	open with a different page size: should fail.
1568
1569=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1570sdbtest001
1571	Tests multiple access methods in one subdb
1572	Open several subdbs, each with a different access method
1573	Small keys, small data
1574	Put/get per key per subdb
1575	Dump file, verify per subdb
1576	Close, reopen per subdb
1577	Dump file, verify per subdb
1578
1579	Make several subdb's of different access methods all in one DB.
1580	Rotate methods and repeat [#762].
1581	Use the first 10,000 entries from the dictionary.
1582	Insert each with self as key and data; retrieve each.
1583	After all are entered, retrieve all; compare output to original.
1584	Close file, reopen, do retrieve and re-verify.
1585
1586=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1587sdbtest002
1588	Tests multiple access methods in one subdb access by multiple
1589	processes.
1590	Open several subdbs, each with a different access method
1591	Small keys, small data
1592	Put/get per key per subdb
1593	Fork off several child procs to each delete selected
1594	data from their subdb and then exit
1595	Dump file, verify contents of each subdb is correct
1596	Close, reopen per subdb
1597	Dump file, verify per subdb
1598
1599	Make several subdb's of different access methods all in one DB.
1600	Fork of some child procs to each manipulate one subdb and when
1601	they are finished, verify the contents of the databases.
1602	Use the first 10,000 entries from the dictionary.
1603	Insert each with self as key and data; retrieve each.
1604	After all are entered, retrieve all; compare output to original.
1605	Close file, reopen, do retrieve and re-verify.
1606
1607=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1608sec001
1609	Test of security interface
1610
1611=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1612sec002
1613	Test of security interface and catching errors in the
1614	face of attackers overwriting parts of existing files.
1615
1616=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1617si001
1618	Secondary index put/delete with lorder test
1619
1620	Put data in primary db and check that pget on secondary
1621	index finds the right entries.  Alter the primary in the
1622	following ways, checking for correct data each time:
1623	Overwrite data in primary database.
1624	Delete half of entries through primary.
1625	Delete half of remaining entries through secondary.
1626	Append data (for record-based primaries only).
1627
1628=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1629si002
1630	Basic cursor-based secondary index put/delete test
1631
1632	Cursor put data in primary db and check that pget
1633	on secondary index finds the right entries.
1634	Overwrite while walking primary, check pget again.
1635	Overwrite while walking secondary (use c_pget), check
1636	pget again.
1637	Cursor delete half of entries through primary, check.
1638	Cursor delete half of remainder through secondary, check.
1639
1640=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1641si003
1642	si001 with secondaries created and closed mid-test
1643	Basic secondary index put/delete test with secondaries
1644	created mid-test.
1645
1646=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1647si004
1648	si002 with secondaries created and closed mid-test
1649	Basic cursor-based secondary index put/delete test, with
1650	secondaries created mid-test.
1651
1652=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1653si005
1654	Basic secondary index put/delete test with transactions
1655
1656=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1657si006
1658
1659	Test -immutable_key interface.
1660
1661	DB_IMMUTABLE_KEY is an optimization to be used when a
1662	secondary key will not be changed.  It does not prevent
1663	a deliberate change to the secondary key, it just does not
1664	propagate that change when it is made to the primary.
1665	This test verifies that a change to the primary is propagated
1666	to the secondary or not as specified by -immutable_key.
1667
1668=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1669si007
1670	Secondary index put/delete with lorder test
1671
1672	This test is the same as si001 with the exception
1673	that we create and populate the primary and THEN
1674	create the secondaries and associate them with -create.
1675
1676=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1677si008
1678	Secondary index put/delete with lorder test
1679
1680	This test is the same as si001 except that we
1681	create the secondaries with different byte orders:
1682	one native, one swapped.
1683
1684=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1685sijointest: Secondary index and join test.
1686	This used to be si005.tcl.
1687
1688=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1689test001
1690	Small keys/data
1691	Put/get per key
1692	Dump file
1693	Close, reopen
1694	Dump file
1695
1696	Use the first 10,000 entries from the dictionary.
1697	Insert each with self as key and data; retrieve each.
1698	After all are entered, retrieve all; compare output to original.
1699	Close file, reopen, do retrieve and re-verify.
1700
1701=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1702test002
1703	Small keys/medium data
1704	Put/get per key
1705	Dump file
1706	Close, reopen
1707	Dump file
1708
1709	Use the first 10,000 entries from the dictionary.
1710	Insert each with self as key and a fixed, medium length data string;
1711	retrieve each. After all are entered, retrieve all; compare output
1712	to original. Close file, reopen, do retrieve and re-verify.
1713
1714=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1715test003
1716	Small keys/large data
1717	Put/get per key
1718	Dump file
1719	Close, reopen
1720	Dump file
1721
1722	Take the source files and dbtest executable and enter their names
1723	as the key with their contents as data.  After all are entered,
1724	retrieve all; compare output to original. Close file, reopen, do
1725	retrieve and re-verify.
1726
1727=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1728test004
1729	Small keys/medium data
1730	Put/get per key
1731	Sequential (cursor) get/delete
1732
1733	Check that cursor operations work.  Create a database.
1734	Read through the database sequentially using cursors and
1735	delete each element.
1736
1737=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1738test005
1739	Small keys/medium data
1740	Put/get per key
1741	Close, reopen
1742	Sequential (cursor) get/delete
1743
1744	Check that cursor operations work.  Create a database; close
1745	it and reopen it.  Then read through the database sequentially
1746	using cursors and delete each element.
1747
1748=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1749test006
1750	Small keys/medium data
1751	Put/get per key
1752	Keyed delete and verify
1753
1754	Keyed delete test.
1755	Create database.
1756	Go through database, deleting all entries by key.
1757	Then do the same for unsorted and sorted dups.
1758
1759=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1760test007
1761	Small keys/medium data
1762	Put/get per key
1763	Close, reopen
1764	Keyed delete
1765
1766	Check that delete operations work.  Create a database; close
1767	database and reopen it.  Then issues delete by key for each
1768	entry.  (Test006 plus reopen)
1769
1770=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1771test008
1772	Small keys/large data
1773	Put/get per key
1774	Loop through keys by steps (which change)
1775	... delete each key at step
1776	... add each key back
1777	... change step
1778	Confirm that overflow pages are getting reused
1779
1780	Take the source files and dbtest executable and enter their names as
1781	the key with their contents as data.  After all are entered, begin
1782	looping through the entries; deleting some pairs and then readding them.
1783
1784=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1785test009
1786	Small keys/large data
1787	Same as test008; close and reopen database
1788
1789	Check that we reuse overflow pages.  Create database with lots of
1790	big key/data pairs.  Go through and delete and add keys back
1791	randomly.  Then close the DB and make sure that we have everything
1792	we think we should.
1793
1794=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1795test010
1796	Duplicate test
1797	Small key/data pairs.
1798
1799	Use the first 10,000 entries from the dictionary.
1800	Insert each with self as key and data; add duplicate records for each.
1801	After all are entered, retrieve all; verify output.
1802	Close file, reopen, do retrieve and re-verify.
1803	This does not work for recno
1804
1805=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1806test011
1807	Duplicate test
1808	Small key/data pairs.
1809	Test DB_KEYFIRST, DB_KEYLAST, DB_BEFORE and DB_AFTER.
1810	To test off-page duplicates, run with small pagesize.
1811
1812	Use the first 10,000 entries from the dictionary.
1813	Insert each with self as key and data; add duplicate records for each.
1814	Then do some key_first/key_last add_before, add_after operations.
1815	This does not work for recno
1816
1817	To test if dups work when they fall off the main page, run this with
1818	a very tiny page size.
1819
1820=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1821test012
1822	Large keys/small data
1823	Same as test003 except use big keys (source files and
1824	executables) and small data (the file/executable names).
1825
1826	Take the source files and dbtest executable and enter their contents
1827	as the key with their names as data.  After all are entered, retrieve
1828	all; compare output to original. Close file, reopen, do retrieve and
1829	re-verify.
1830
1831=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1832test013
1833	Partial put test
1834	Overwrite entire records using partial puts.
1835	Make sure that NOOVERWRITE flag works.
1836
1837	1. Insert 10000 keys and retrieve them (equal key/data pairs).
1838	2. Attempt to overwrite keys with NO_OVERWRITE set (expect error).
1839	3. Actually overwrite each one with its datum reversed.
1840
1841	No partial testing here.
1842
1843=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1844test014
1845	Exercise partial puts on short data
1846	Run 5 combinations of numbers of characters to replace,
1847	and number of times to increase the size by.
1848
1849	Partial put test, small data, replacing with same size.  The data set
1850	consists of the first nentries of the dictionary.  We will insert them
1851	(and retrieve them) as we do in test 1 (equal key/data pairs).  Then
1852	we'll try to perform partial puts of some characters at the beginning,
1853	some at the end, and some at the middle.
1854
1855=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1856test015
1857	Partial put test
1858	Partial put test where the key does not initially exist.
1859
1860=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1861test016
1862	Partial put test
1863	Partial put where the datum gets shorter as a result of the put.
1864
1865	Partial put test where partial puts make the record smaller.
1866	Use the first 10,000 entries from the dictionary.
1867	Insert each with self as key and a fixed, medium length data string;
1868	retrieve each. After all are entered, go back and do partial puts,
1869	replacing a random-length string with the key value.
1870	Then verify.
1871
1872=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1873test017
1874	Basic offpage duplicate test.
1875
1876	Run duplicates with small page size so that we test off page duplicates.
1877	Then after we have an off-page database, test with overflow pages too.
1878
1879=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1880test018
1881	Offpage duplicate test
1882	Key_{first,last,before,after} offpage duplicates.
1883	Run duplicates with small page size so that we test off page
1884	duplicates.
1885
1886=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1887test019
1888	Partial get test.
1889
1890=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1891test020
1892	In-Memory database tests.
1893
1894=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1895test021
1896	Btree range tests.
1897
1898	Use the first 10,000 entries from the dictionary.
1899	Insert each with self, reversed as key and self as data.
1900	After all are entered, retrieve each using a cursor SET_RANGE, and
1901	getting about 20 keys sequentially after it (in some cases we'll
1902	run out towards the end of the file).
1903
1904=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1905test022
1906	Test of DB->getbyteswapped().
1907
1908=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1909test023
1910	Duplicate test
1911	Exercise deletes and cursor operations within a duplicate set.
1912	Add a key with duplicates (first time on-page, second time off-page)
1913	Number the dups.
1914	Delete dups and make sure that CURRENT/NEXT/PREV work correctly.
1915
1916=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1917test024
1918	Record number retrieval test.
1919	Test the Btree and Record number get-by-number functionality.
1920
1921=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1922test025
1923	DB_APPEND flag test.
1924
1925=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1926test026
1927	Small keys/medium data w/duplicates
1928	Put/get per key.
1929	Loop through keys -- delete each key
1930	... test that cursors delete duplicates correctly
1931
1932	Keyed delete test through cursor.  If ndups is small; this will
1933	test on-page dups; if it's large, it will test off-page dups.
1934
1935=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1936test027
1937	Off-page duplicate test
1938	Test026 with parameters to force off-page duplicates.
1939
1940	Check that delete operations work.  Create a database; close
1941	database and reopen it.  Then issues delete by key for each
1942	entry.
1943
1944=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1945test028
1946	Cursor delete test
1947	Test put operations after deleting through a cursor.
1948
1949=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1950test029
1951	Test the Btree and Record number renumbering.
1952
1953=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1954test030
1955	Test DB_NEXT_DUP Functionality.
1956
1957=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1958test031
1959	Duplicate sorting functionality
1960	Make sure DB_NODUPDATA works.
1961
1962	Use the first 10,000 entries from the dictionary.
1963	Insert each with self as key and "ndups" duplicates
1964	For the data field, prepend random five-char strings (see test032)
1965	that we force the duplicate sorting code to do something.
1966	Along the way, test that we cannot insert duplicate duplicates
1967	using DB_NODUPDATA.
1968
1969	By setting ndups large, we can make this an off-page test
1970	After all are entered, retrieve all; verify output.
1971	Close file, reopen, do retrieve and re-verify.
1972	This does not work for recno
1973
1974=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1975test032
1976	DB_GET_BOTH, DB_GET_BOTH_RANGE
1977
1978	Use the first 10,000 entries from the dictionary.  Insert each with
1979	self as key and "ndups" duplicates.   For the data field, prepend the
1980	letters of the alphabet in a random order so we force the duplicate
1981	sorting code to do something.  By setting ndups large, we can make
1982	this an off-page test.
1983
1984	Test the DB_GET_BOTH functionality by retrieving each dup in the file
1985	explicitly.  Test the DB_GET_BOTH_RANGE functionality by retrieving
1986	the unique key prefix (cursor only).  Finally test the failure case.
1987
1988=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
1989test033
1990	DB_GET_BOTH without comparison function
1991
1992	Use the first 10,000 entries from the dictionary.  Insert each with
1993	self as key and data; add duplicate records for each.  After all are
1994	entered, retrieve all and verify output using DB_GET_BOTH (on DB and
1995	DBC handles) and DB_GET_BOTH_RANGE (on a DBC handle) on existent and
1996	nonexistent keys.
1997
1998	XXX
1999	This does not work for rbtree.
2000
2001=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2002test034
2003	test032 with off-page duplicates
2004	DB_GET_BOTH, DB_GET_BOTH_RANGE functionality with off-page duplicates.
2005
2006=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2007test035
2008	Test033 with off-page duplicates
2009	DB_GET_BOTH functionality with off-page duplicates.
2010
2011=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2012test036
2013	Test KEYFIRST and KEYLAST when the key doesn't exist
2014	Put nentries key/data pairs (from the dictionary) using a cursor
2015	and KEYFIRST and KEYLAST (this tests the case where use use cursor
2016	put for non-existent keys).
2017
2018=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2019test037
2020	Test DB_RMW
2021
2022=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2023test038
2024	DB_GET_BOTH, DB_GET_BOTH_RANGE on deleted items
2025
2026	Use the first 10,000 entries from the dictionary.  Insert each with
2027	self as key and "ndups" duplicates.  For the data field, prepend the
2028	letters of the alphabet in a random order so we force the duplicate
2029	sorting code to do something.  By setting ndups large, we can make
2030	this an off-page test
2031
2032	Test the DB_GET_BOTH and DB_GET_BOTH_RANGE functionality by retrieving
2033	each dup in the file explicitly.  Then remove each duplicate and try
2034	the retrieval again.
2035
2036=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2037test039
2038	DB_GET_BOTH/DB_GET_BOTH_RANGE on deleted items without comparison
2039	function.
2040
2041	Use the first 10,000 entries from the dictionary.  Insert each with
2042	self as key and "ndups" duplicates.  For the data field, prepend the
2043	letters of the alphabet in a random order so we force the duplicate
2044	sorting code to do something.  By setting ndups large, we can make
2045	this an off-page test.
2046
2047	Test the DB_GET_BOTH and DB_GET_BOTH_RANGE functionality by retrieving
2048	each dup in the file explicitly.  Then remove each duplicate and try
2049	the retrieval again.
2050
2051=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2052test040
2053	Test038 with off-page duplicates
2054	DB_GET_BOTH functionality with off-page duplicates.
2055
2056=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2057test041
2058	Test039 with off-page duplicates
2059	DB_GET_BOTH functionality with off-page duplicates.
2060
2061=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2062test042
2063	Concurrent Data Store test (CDB)
2064
2065	Multiprocess DB test; verify that locking is working for the
2066	concurrent access method product.
2067
2068	Use the first "nentries" words from the dictionary.  Insert each with
2069	self as key and a fixed, medium length data string.  Then fire off
2070	multiple processes that bang on the database.  Each one should try to
2071	read and write random keys.  When they rewrite, they'll append their
2072	pid to the data string (sometimes doing a rewrite sometimes doing a
2073	partial put).  Some will use cursors to traverse through a few keys
2074	before finding one to write.
2075
2076=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2077test043
2078	Recno renumbering and implicit creation test
2079	Test the Record number implicit creation and renumbering options.
2080
2081=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2082test044
2083	Small system integration tests
2084	Test proper functioning of the checkpoint daemon,
2085	recovery, transactions, etc.
2086
2087	System integration DB test: verify that locking, recovery, checkpoint,
2088	and all the other utilities basically work.
2089
2090	The test consists of $nprocs processes operating on $nfiles files.  A
2091	transaction consists of adding the same key/data pair to some random
2092	number of these files.  We generate a bimodal distribution in key size
2093	with 70% of the keys being small (1-10 characters) and the remaining
2094	30% of the keys being large (uniform distribution about mean $key_avg).
2095	If we generate a key, we first check to make sure that the key is not
2096	already in the dataset.  If it is, we do a lookup.
2097
2098=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2099test045
2100	Small random tester
2101	Runs a number of random add/delete/retrieve operations.
2102	Tests both successful conditions and error conditions.
2103
2104	Run the random db tester on the specified access method.
2105
2106=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2107test046
2108	Overwrite test of small/big key/data with cursor checks.
2109
2110=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2111test047
2112	DBcursor->c_get get test with SET_RANGE option.
2113
2114=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2115test048
2116	Cursor stability across Btree splits.
2117
2118=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2119test049
2120	Cursor operations on uninitialized cursors.
2121
2122=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2123test050
2124	Overwrite test of small/big key/data with cursor checks for Recno.
2125
2126=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2127test051
2128	Fixed-length record Recno test.
2129	0. Test various flags (legal and illegal) to open
2130	1. Test partial puts where dlen != size (should fail)
2131	2. Partial puts for existent record -- replaces at beg, mid, and
2132	end of record, as well as full replace
2133
2134=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2135test052
2136	Renumbering record Recno test.
2137
2138=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2139test053
2140	Test of the DB_REVSPLITOFF flag in the Btree and Btree-w-recnum
2141	methods.
2142
2143=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2144test054
2145	Cursor maintenance during key/data deletion.
2146
2147	This test checks for cursor maintenance in the presence of deletes.
2148	There are N different scenarios to tests:
2149	1. No duplicates.  Cursor A deletes a key, do a  GET for the key.
2150	2. No duplicates.  Cursor is positioned right before key K, Delete K,
2151	do a next on the cursor.
2152	3. No duplicates.  Cursor is positioned on key K, do a regular delete
2153	of K, do a current get on K.
2154	4. Repeat 3 but do a next instead of current.
2155	5. Duplicates. Cursor A is on the first item of a duplicate set, A
2156	does a delete.  Then we do a non-cursor get.
2157	6. Duplicates.  Cursor A is in a duplicate set and deletes the item.
2158	do a delete of the entire Key. Test cursor current.
2159	7. Continue last test and try cursor next.
2160	8. Duplicates.  Cursor A is in a duplicate set and deletes the item.
2161	Cursor B is in the same duplicate set and deletes a different item.
2162	Verify that the cursor is in the right place.
2163	9. Cursors A and B are in the place in the same duplicate set.  A
2164	deletes its item.  Do current on B.
2165	10. Continue 8 and do a next on B.
2166
2167=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2168test055
2169	Basic cursor operations.
2170	This test checks basic cursor operations.
2171	There are N different scenarios to tests:
2172	1. (no dups) Set cursor, retrieve current.
2173	2. (no dups) Set cursor, retrieve next.
2174	3. (no dups) Set cursor, retrieve prev.
2175
2176=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2177test056
2178	Cursor maintenance during deletes.
2179	Check if deleting a key when a cursor is on a duplicate of that
2180	key works.
2181
2182=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2183test057
2184	Cursor maintenance during key deletes.
2185	1.  Delete a key with a cursor.  Add the key back with a regular
2186	put.  Make sure the cursor can't get the new item.
2187	2.  Put two cursors on one item.  Delete through one cursor,
2188	check that the other sees the change.
2189	3.  Same as 2, with the two cursors on a duplicate.
2190
2191=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2192test058
2193	Verify that deleting and reading duplicates results in correct ordering.
2194
2195=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2196test059
2197	Cursor ops work with a partial length of 0.
2198	Make sure that we handle retrieves of zero-length data items correctly.
2199	The following ops, should allow a partial data retrieve of 0-length.
2200	db_get
2201	db_cget FIRST, NEXT, LAST, PREV, CURRENT, SET, SET_RANGE
2202
2203=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2204test060
2205	Test of the DB_EXCL flag to DB->open().
2206	1) Attempt to open and create a nonexistent database; verify success.
2207	2) Attempt to reopen it;  verify failure.
2208
2209=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2210test061
2211	Test of txn abort and commit for in-memory databases.
2212	a) Put + abort: verify absence of data
2213	b) Put + commit: verify presence of data
2214	c) Overwrite + abort: verify that data is unchanged
2215	d) Overwrite + commit: verify that data has changed
2216	e) Delete + abort: verify that data is still present
2217	f) Delete + commit: verify that data has been deleted
2218
2219=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2220test062
2221	Test of partial puts (using DB_CURRENT) onto duplicate pages.
2222	Insert the first 200 words into the dictionary 200 times each with
2223	self as key and <random letter>:self as data.  Use partial puts to
2224	append self again to data;  verify correctness.
2225
2226=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2227test063
2228	Test of the DB_RDONLY flag to DB->open
2229	Attempt to both DB->put and DBC->c_put into a database
2230	that has been opened DB_RDONLY, and check for failure.
2231
2232=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2233test064
2234	Test of DB->get_type
2235	Create a database of type specified by method.
2236	Make sure DB->get_type returns the right thing with both a normal
2237	and DB_UNKNOWN open.
2238
2239=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2240test065
2241	Test of DB->stat, both -DB_FAST_STAT and row
2242	counts with DB->stat -txn.
2243
2244=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2245test066
2246	Test of cursor overwrites of DB_CURRENT w/ duplicates.
2247
2248	Make sure a cursor put to DB_CURRENT acts as an overwrite in a
2249	database with duplicates.
2250
2251=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2252test067
2253	Test of DB_CURRENT partial puts onto almost empty duplicate
2254	pages, with and without DB_DUP_SORT.
2255
2256	Test of DB_CURRENT partial puts on almost-empty duplicate pages.
2257	This test was written to address the following issue, #2 in the
2258	list of issues relating to bug #0820:
2259
2260	2. DBcursor->put, DB_CURRENT flag, off-page duplicates, hash and btree:
2261	In Btree, the DB_CURRENT overwrite of off-page duplicate records
2262	first deletes the record and then puts the new one -- this could
2263	be a problem if the removal of the record causes a reverse split.
2264	Suggested solution is to acquire a cursor to lock down the current
2265	record, put a new record after that record, and then delete using
2266	the held cursor.
2267
2268	It also tests the following, #5 in the same list of issues:
2269	5. DBcursor->put, DB_AFTER/DB_BEFORE/DB_CURRENT flags, DB_DBT_PARTIAL
2270	set, duplicate comparison routine specified.
2271	The partial change does not change how data items sort, but the
2272	record to be put isn't built yet, and that record supplied is the
2273	one that's checked for ordering compatibility.
2274
2275=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2276test068
2277	Test of DB_BEFORE and DB_AFTER with partial puts.
2278	Make sure DB_BEFORE and DB_AFTER work properly with partial puts, and
2279	check that they return EINVAL if DB_DUPSORT is set or if DB_DUP is not.
2280
2281=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2282test069
2283	Test of DB_CURRENT partial puts without duplicates-- test067 w/
2284	small ndups to ensure that partial puts to DB_CURRENT work
2285	correctly in the absence of duplicate pages.
2286
2287=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2288test070
2289	Test of DB_CONSUME (Four consumers, 1000 items.)
2290
2291	Fork off six processes, four consumers and two producers.
2292	The producers will each put 20000 records into a queue;
2293	the consumers will each get 10000.
2294	Then, verify that no record was lost or retrieved twice.
2295
2296=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2297test071
2298	Test of DB_CONSUME (One consumer, 10000 items.)
2299	This is DB Test 70, with one consumer, one producers, and 10000 items.
2300
2301=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2302test072
2303	Test of cursor stability when duplicates are moved off-page.
2304
2305=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2306test073
2307	Test of cursor stability on duplicate pages.
2308
2309	Does the following:
2310	a. Initialize things by DB->putting ndups dups and
2311	setting a reference cursor to point to each.
2312	b. c_put ndups dups (and correspondingly expanding
2313	the set of reference cursors) after the last one, making sure
2314	after each step that all the reference cursors still point to
2315	the right item.
2316	c. Ditto, but before the first one.
2317	d. Ditto, but after each one in sequence first to last.
2318	e. Ditto, but after each one in sequence from last to first.
2319	occur relative to the new datum)
2320	f. Ditto for the two sequence tests, only doing a
2321	DBC->c_put(DB_CURRENT) of a larger datum instead of adding a
2322	new one.
2323
2324=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2325test074
2326	Test of DB_NEXT_NODUP.
2327
2328=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2329test076
2330	Test creation of many small databases in a single environment. [#1528].
2331
2332=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2333test077
2334	Test of DB_GET_RECNO [#1206].
2335
2336=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2337test078
2338	Test of DBC->c_count(). [#303]
2339
2340=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2341test079
2342	Test of deletes in large trees.  (test006 w/ sm. pagesize).
2343
2344	Check that delete operations work in large btrees.  10000 entries
2345	and a pagesize of 512 push this out to a four-level btree, with a
2346	small fraction of the entries going on overflow pages.
2347
2348=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2349test081
2350	Test off-page duplicates and overflow pages together with
2351	very large keys (key/data as file contents).
2352
2353=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2354test082
2355	Test of DB_PREV_NODUP (uses test074).
2356
2357=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2358test083
2359	Test of DB->key_range.
2360
2361=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2362test084
2363	Basic sanity test (test001) with large (64K) pages.
2364
2365=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2366test085
2367	Test of cursor behavior when a cursor is pointing to a deleted
2368	btree key which then has duplicates added. [#2473]
2369
2370=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2371test086
2372	Test of cursor stability across btree splits/rsplits with
2373	subtransaction aborts (a variant of test048).  [#2373]
2374
2375=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2376test087
2377	Test of cursor stability when converting to and modifying
2378	off-page duplicate pages with subtransaction aborts. [#2373]
2379
2380	Does the following:
2381	a. Initialize things by DB->putting ndups dups and
2382	setting a reference cursor to point to each.  Do each put twice,
2383	first aborting, then committing, so we're sure to abort the move
2384	to off-page dups at some point.
2385	b. c_put ndups dups (and correspondingly expanding
2386	the set of reference cursors) after the last one, making sure
2387	after each step that all the reference cursors still point to
2388	the right item.
2389	c. Ditto, but before the first one.
2390	d. Ditto, but after each one in sequence first to last.
2391	e. Ditto, but after each one in sequence from last to first.
2392	occur relative to the new datum)
2393	f. Ditto for the two sequence tests, only doing a
2394	DBC->c_put(DB_CURRENT) of a larger datum instead of adding a
2395	new one.
2396
2397=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2398test088
2399	Test of cursor stability across btree splits with very
2400	deep trees (a variant of test048). [#2514]
2401
2402=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2403test089
2404	Concurrent Data Store test (CDB)
2405
2406	Enhanced CDB testing to test off-page dups, cursor dups and
2407	cursor operations like c_del then c_get.
2408
2409=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2410test090
2411	Test for functionality near the end of the queue using test001.
2412
2413=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2414test091
2415	Test of DB_CONSUME_WAIT.
2416
2417=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2418test092
2419	Test of DB_DIRTY_READ [#3395]
2420
2421	We set up a database with nentries in it.  We then open the
2422	database read-only twice.  One with dirty reads and one without.
2423	We open the database for writing and update some entries in it.
2424	Then read those new entries via db->get (clean and dirty), and
2425	via cursors (clean and dirty).
2426
2427=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2428test093
2429	Test set_bt_compare (btree key comparison function) and
2430	set_h_compare (hash key comparison function).
2431
2432	Open a database with a comparison function specified,
2433	populate, and close, saving a list with that key order as
2434	we do so.  Reopen and read in the keys, saving in another
2435	list; the keys should be in the order specified by the
2436	comparison function.  Sort the original saved list of keys
2437	using the comparison function, and verify that it matches
2438	the keys as read out of the database.
2439
2440=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2441test094
2442	Test using set_dup_compare.
2443
2444	Use the first 10,000 entries from the dictionary.
2445	Insert each with self as key and data; retrieve each.
2446	After all are entered, retrieve all; compare output to original.
2447	Close file, reopen, do retrieve and re-verify.
2448
2449=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2450test095
2451	Bulk get test for methods supporting dups. [#2934]
2452
2453=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2454test096
2455	Db->truncate test.
2456	For all methods:
2457	Test that truncate empties an existing database.
2458	Test that truncate-write in an aborted txn doesn't
2459	change the original contents.
2460	Test that truncate-write in a committed txn does
2461	overwrite the original contents.
2462	For btree and hash, do the same in a database with offpage dups.
2463
2464=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2465test097
2466	Open up a large set of database files simultaneously.
2467	Adjust for local file descriptor resource limits.
2468	Then use the first 1000 entries from the dictionary.
2469	Insert each with self as key and a fixed, medium length data string;
2470	retrieve each. After all are entered, retrieve all; compare output
2471	to original.
2472
2473=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2474test098
2475	Test of DB_GET_RECNO and secondary indices.  Open a primary and
2476	a secondary, and do a normal cursor get followed by a get_recno.
2477	(This is a smoke test for "Bug #1" in [#5811].)
2478
2479=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2480test099
2481
2482	Test of DB->get and DBC->c_get with set_recno and get_recno.
2483
2484	Populate a small btree -recnum database.
2485	After all are entered, retrieve each using -recno with DB->get.
2486	Open a cursor and do the same for DBC->c_get with set_recno.
2487	Verify that set_recno sets the record number position properly.
2488	Verify that get_recno returns the correct record numbers.
2489
2490	Using the same database, open 3 cursors and position one at
2491	the beginning, one in the middle, and one at the end.  Delete
2492	by cursor and check that record renumbering is done properly.
2493
2494=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2495test100
2496	Test for functionality near the end of the queue
2497	using test025 (DB_APPEND).
2498
2499=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2500test101
2501	Test for functionality near the end of the queue
2502	using test070 (DB_CONSUME).
2503
2504=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2505test102
2506	Bulk get test for record-based methods. [#2934]
2507
2508=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2509test103
2510	Test bulk get when record numbers wrap around.
2511
2512	Load database with items starting before and ending after
2513	the record number wrap around point.  Run bulk gets (-multi_key)
2514	with various buffer sizes and verify the contents returned match
2515	the results from a regular cursor get.
2516
2517	Then delete items to create a sparse database and make sure it
2518	still works.  Test both -multi and -multi_key since they behave
2519	differently.
2520
2521=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2522test106
2523
2524
2525
2526
2527=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2528test107
2529	Test of read-committed (degree 2 isolation). [#8689]
2530
2531	We set up a database.  Open a read-committed transactional cursor and
2532	a regular transactional cursor on it. Position each cursor on one page,
2533	and do a put to a different page.
2534
2535	Make sure that:
2536	- the put succeeds if we are using degree 2 isolation.
2537	- the put deadlocks within a regular transaction with
2538	a regular cursor.
2539
2540
2541=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2542test109
2543
2544	Test of sequences.
2545
2546=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2547test110
2548	Partial get test with duplicates.
2549
2550	For hash and btree, create and populate a database
2551	with dups. Randomly selecting offset and length,
2552	retrieve data from each record and make sure we
2553	get what we expect.
2554
2555=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2556test111
2557	Test database compaction.
2558
2559	Populate a database.  Remove a high proportion of entries.
2560	Dump and save contents.  Compact the database, dump again,
2561	and make sure we still have the same contents.
2562	Add back some entries, delete more entries (this time by
2563	cursor), dump, compact, and do the before/after check again.
2564
2565=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2566test112
2567	Test database compaction with a deep tree.
2568
2569	This is a lot like test111, but with a large number of
2570	entries and a small page size to make the tree deep.
2571	To make it simple we use numerical keys all the time.
2572
2573	Dump and save contents.  Compact the database, dump again,
2574	and make sure we still have the same contents.
2575	Add back some entries, delete more entries (this time by
2576	cursor), dump, compact, and do the before/after check again.
2577
2578=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2579test113
2580	Test database compaction with duplicates.
2581
2582	This is essentially test111 with duplicates.
2583	To make it simple we use numerical keys all the time.
2584
2585	Dump and save contents.  Compact the database, dump again,
2586	and make sure we still have the same contents.
2587	Add back some entries, delete more entries (this time by
2588	cursor), dump, compact, and do the before/after check again.
2589
2590=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2591test114
2592	Test database compaction with overflows.
2593
2594	Populate a database.  Remove a high proportion of entries.
2595	Dump and save contents.  Compact the database, dump again,
2596	and make sure we still have the same contents.
2597	Add back some entries, delete more entries (this time by
2598	cursor), dump, compact, and do the before/after check again.
2599
2600=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2601test115
2602	Test database compaction with user-specified btree sort.
2603
2604	This is essentially test111 with the user-specified sort.
2605	Populate a database.  Remove a high proportion of entries.
2606	Dump and save contents.  Compact the database, dump again,
2607	and make sure we still have the same contents.
2608	Add back some entries, delete more entries (this time by
2609	cursor), dump, compact, and do the before/after check again.
2610
2611=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2612test116
2613	Test of basic functionality of lsn_reset.
2614
2615	Create a database in an env.  Copy it to a new file within
2616	the same env.  Reset the page LSNs.
2617
2618=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2619test117
2620	Test database compaction with requested fill percent.
2621
2622	Populate a database.  Remove a high proportion of entries.
2623	Dump and save contents.  Compact the database, requesting
2624	fill percentages starting at 10% and working our way up to
2625	100.  On each cycle, make sure we still have the same contents.
2626
2627	Unlike the other compaction tests, this one does not
2628	use -freespace.
2629
2630=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2631test119
2632	Test behavior when Berkeley DB returns DB_BUFFER_SMALL on a cursor.
2633
2634	If the user-supplied buffer is not large enough to contain
2635	the returned value, DB returns BUFFER_SMALL.  If it does,
2636	check that the cursor does not move -- if it moves, it will
2637	skip items. [#13815]
2638
2639=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2640test120
2641	Test of multi-version concurrency control.
2642
2643	Test basic functionality: a snapshot transaction started
2644	before a regular transaction's put can't see the modification.
2645	A snapshot transaction started after the put can see it.
2646
2647=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2648test121
2649	Tests of multi-version concurrency control.
2650
2651	MVCC and cursor adjustment.
2652	Set up a -snapshot cursor and position it in the middle
2653	of a database.
2654	Write to the database, both before and after the cursor,
2655	and verify that it stays on the same position.
2656
2657=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2658test122
2659	Tests of multi-version concurrency control.
2660
2661	MVCC and databases that turn multi-version on and off.
2662
2663=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2664test123
2665	Concurrent Data Store cdsgroup smoke test.
2666
2667	Open a CDS env with -cdb_alldb.
2668	Start a "txn" with -cdsgroup.
2669	Create two databases in the env, do a cursor put 
2670	in both within the same txn.  This should succeed.  
2671
2672=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2673txn001
2674	Begin, commit, abort testing.
2675
2676=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2677txn002
2678	Verify that  read-only transactions do not write log records.
2679
2680=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2681txn003
2682	Test abort/commit/prepare of txns with outstanding child txns.
2683
2684=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2685txn004
2686	Test of wraparound txnids (txn001)
2687
2688=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2689txn005
2690	Test transaction ID wraparound and recovery.
2691
2692=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2693txn008
2694	Test of wraparound txnids (txn002)
2695
2696=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2697txn009
2698	Test of wraparound txnids (txn003)
2699
2700=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2701txn010
2702	Test DB_ENV->txn_checkpoint arguments/flags
2703
2704=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2705txn011
2706	Test durable and non-durable txns.
2707	Test a mixed env (with both durable and non-durable
2708	dbs), then a purely non-durable env.  Make sure commit
2709	and abort work, and that only the log records we
2710	expect are written.
2711	Test that we can't get a durable handle on a ND
2712	database, or vice versa.  Test that all subdb's
2713	must be of the same type (D or ND).
2714
2715=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2716txn012
2717	Test txn->getname and txn->setname.
2718
2719=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2720txn013
2721	Test of txns used in the wrong environment.
2722	Set up two envs.  Start a txn in one env, and attempt to use it
2723	in the other env.  Verify we get the appropriate error message.
2724
2725=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
2726txn014
2727	Test of parent and child txns working on the same database.
2728	A txn that will become a parent create a database.
2729	A txn that will not become a parent creates another database.
2730	Start a child txn of the 1st txn.
2731	Verify that the parent txn is disabled while child is open.
2732	1. Child reads contents with child handle (should succeed).
2733	2. Child reads contents with parent handle (should succeed).
2734	Verify that the non-parent txn can read from its database,
2735	and that the child txn cannot.
2736	Return to the child txn.
2737	3. Child writes with child handle (should succeed).
2738	4. Child writes with parent handle (should succeed).
2739
2740	Commit the child, verify that the parent can write again.
2741	Check contents of database with a second child.
2742