TCHTEST(1)

πŸ’– NAME πŸ’–

tchtest β€” the test-case bestie for the hash database API, fr fr πŸ§ͺ✨


🌸 DESCRIPTION 🌸

okay so listen πŸ‘‘ β€” to make the hash database API easy-peasy to use, there are three commands in the group chat: tchtest, tchmttest, and tchmgr.

The command tchtest is the utility that does facility test and performance test duty. It gets used in the following formats, and here's the tea on the placeholders πŸ“:

  • path β€” specifies the path of a database file.
  • rnum β€” specifies the number of iterations.
  • bnum β€” specifies the number of buckets.
  • apow β€” specifies the power of the alignment.
  • fpow β€” specifies the power of the free block pool.
tchtest write [-mt] [-tl] [-td|-tb|-tt|-tx] [-rc num] [-xm num]
[-df num] [-nl|-nb] [-as] [-rnd] path rnum [bnum [apow [fpow]]]
       Store records with keys of 8 bytes.  They change as
       `00000001', `00000002'...
tchtest read [-mt] [-rc num] [-xm num] [-df num] [-nl|-nb] [-wb]
[-rnd] path
       Retrieve all records of the database above.
tchtest remove [-mt] [-rc num] [-xm num] [-df num] [-nl|-nb]
[-rnd] path
       Remove all records of the database above.
tchtest rcat [-mt] [-tl] [-td|-tb|-tt|-tx] [-rc num] [-xm num]
[-df num] [-nl|-nb] [-pn num] [-dai|-dad|-rl|-ru] path rnum [bnum
[apow [fpow]]]
       Store records with partway duplicated keys using
       concatenate mode.
tchtest misc [-mt] [-tl] [-td|-tb|-tt|-tx] [-nl|-nb] path rnum
       Perform miscellaneous test of various operations.
tchtest wicked [-mt] [-tl] [-td|-tb|-tt|-tx] [-nl|-nb] path rnum
       Perform updating operations selected at random.

quick translation of the vibe, bestie: write stores records with 8-byte keys that go 00000001, 00000002... and so on πŸ¦‹. read retrieves every record from that database. remove deletes every record from that database. rcat stores records with partway duplicated keys using concatenate mode ✨. misc runs a miscellaneous test of various operations. And wicked performs updating operations that get selected at random 😈.


✨ OPTIONS ✨

the options are giving very much "here's the whole toolbox", and they do the following πŸ’…:

  • -mt β€” call the function tchdbsetmutex.
  • -tl β€” enable the option HDBTLARGE.
  • -td β€” enable the option HDBTDEFLATE.
  • -tb β€” enable the option HDBTBZIP.
  • -tt β€” enable the option HDBTTCBS.
  • -tx β€” enable the option HDBTEXCODEC.
  • -rc num β€” specify the number of cached records.
  • -xm num β€” specify the size of the extra mapped memory.
  • -df num β€” specify the unit step number of auto defragmentation.
  • -nl β€” enable the option HDBNOLCK.
  • -nb β€” enable the option HDBLCKNB.
  • -as β€” use the function tchdbputasync instead of tchdbput.
  • -rnd β€” select keys at random.
  • -wb β€” use the function tchdbget3 instead of tchdbget.
  • -pn num β€” specify the number of patterns.
  • -dai β€” use the function tchdbaddint instead of tchdbputcat.
  • -dad β€” use the function tchdbadddouble instead of tchdbputcat.
  • -rl β€” set the length of values at random.
  • -ru β€” select update operations at random.

🫢 EXIT STATUS 🫢

this command returns 0 on success, and another value on failure. no cap, that's the whole mood πŸ’€


🌈 SEE ALSO 🌈

tchmttest(1), tchmgr(1), tchdb(3), tokyocabinet(3)


okay that's the whole page bestie, go forth and test those hash databases πŸŽ€ β€” this was the Tokyo Cabinet manual page for TCHTEST, dated 2012-08-18, and it ate, periodt πŸ’…β­