Wednesday, January 29, 2014

AWS - terminate instance

aws ec2 describe-instances --filters Name=private-ip-address,Values={IP Address} | grep -i InstanceId
aws ec2 terminate-instances --instance-ids {{ instance_id }}

Monday, January 13, 2014

Idempotent

Idempotent Operations: Operations that have no side-effects if executed multiple times. 
Example: An operation that retrieves values from a data resource and say, prints it 

Non-Idempotent Operations: Operations that would cause some harm if executed multiple times. (As they change some values or states) 
Example: An operation that withdraws from a bank account

http://stackoverflow.com/questions/1077412/what-is-an-idempotent-operation