O'Reilly logo

Release It! by Michael T. Nygard

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Antipattern4.11 Unbounded Result Sets

Design with skepticism, and you will achieve resilience. Ask, “What can system X do to hurt me?” and then design a way to dodge, duck, dip, dive, and dodge whatever wrench your supposed ally throws.

If your application is like most, it probably treats its database server with far too much trust. I’m going to try to convince you that a healthy dose of skepticism will help your application dodge a bullet or two.

A common structure in the code goes like this: send a query to the database, and then loop over the result set, processing each row. Often, processing a row means adding a new data object to a collection. What ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required