Search

What the Quote?

"I'm wrestling a flibbertigibbet for control of a cupcake."

Steven Rodgers

"Duck is the new monkey."

Greg Rotz

"There's always room for cello."

Laura Hearron

« PNG support in the Notes client? Maybe they should start with full support for GIF... | Main| Every time you use window.open, God kills a kitten »

0.01 nanoseconds

Category lotusscript
Ever since Peter von Stöckel posted about using NotesDatabase.GetProfileDocCollection to quickly create an empty NotesDocumentCollection, I've been meaning to benchmark it against a database with hundreds of thousands of documents, but keep forgetting to. Earlier tonight I had a reason for needing an empty collection, was reminded of the benchmarks Nick Wall provided on Peter's post (tested on a Domino 6.5.3 server), and realized that my web server log would be an ideal candidate to see if the speeds are similar in the Notes 8 client... at the time, it contained 541,269 documents. Here's how it turned out:

 db.Search
({@False}, Nothing, 0)
db.Search
({@False}, datTomorrow, 0)
db.GetProfileDocCollection
("EmptyCollection")
13.0740.1910.04
23.2950.2010
33.1040.2010
43.1250.20
53.0540.2010
63.2050.190.01
73.0840.20.01
83.1150.20
93.0940.20
103.2250.20
Average
(in seconds)
3.13750.19840.006
Per document
(in nanoseconds)
5.97650.36650.011


Still scales pretty well. Let me know if you've done any benchmarking against a huge database that also contains a significant number of profiles... my DomLog only contains one.

(cross-posted at BleedYellow)

Comments

Gravatar Image1 - Any idea how this compares to the Notes 8 method of creating an empty NotesDocumentCollection? Emoticon

Gravatar Image2 - Oh, that one's tickless. Emoticon Every other approach is impacted at least a little bit by how many notes are in a database - the first two, because they have to rule out every data note (the second method is just more efficient at doing so), the third because it has to rule out every profile note - whereas db.createDocumentCollection doesn't care. It just creates the empty container, so it's lightning fast. But it's undocumented for the time being, so use at thy own risk. Emoticon

Gravatar Image3 - Nice benchmark Tim, and reassuring that my theory holds this far. As you said, it would be nice to see what happens in a huge DB containing lots of profile documents as well.

Post A Comment

:-D:-o:-p:-x:-(:-):-\:angry::cool::cry::emb::grin::huh::laugh::lips::rolleyes:;-)