Error handling
If an error occurs as a result of the database operation, an exception is raised. Aerospike::Exceptions::Aerospike is inherited from StandardError, and can be caught using normal rescue clauses.
The Aerospike::Exceptions::Aerospike class provides an accessor to result_code that describes the exact cause of the Aerospike server error.