Selecting all bins/selective bins, which gives better performance?

As we already know that aerospike always select the complete record with all bins and later we can select specific bins. My query is if I need merely 10 bins out of a record with 200 bins, Is it better to retrieve all and filter later as per usage or perform a select with selective fields would give better performance

Selecting just the bins you need will save on network bandwidth usage between Aerospike and client. From an Aerospike point of view, you just utilizing the network send buffers more efficiently when retrieving selected bins only. You have to decide between the data size in your bins - for e.g. does each bin has 1KB data (large => selection really helps) or 8 bytes (tiny amount - may be not much impact to bandwidth, especially if you transactions per second are very low) of data?, your available network bandwidth - Mbps? Gbps? - and what your application needs? are you pulling 10 bins at a time but eventually need all 200 (then don’t select) or only need 10 bins (use selected bins)?

To extend the above answer, when you read all bins or even a single bin - aerospike pulls the entire thing off disk. If the idea is to save disk IO on Aerospike side - you wont.

© 2015 Copyright Aerospike, Inc. | All rights reserved. Creators of the Aerospike Database.