Notes After Bitcoin, other coins started popping up-
Litecoin(using its hashing algo) only allowed mining using GPUs or CPUs. Monero(using its hashing algo) only allowed mining using CPUs. Ethereum also introduced something called smart contracts. What problems might come up in smart contracts? If the code is non-deterministic then it’ll be a problem. Data of the code must be isolated so each smart contract is run in classes and objects. Infinite loops
Notes Bitcoin Reasoning for making bitcoin Anonymous Decentralized money system No trust in the government money system How does this work in a no trust environment?
Use asymmetric encryption scheme like public/private key pairs.
Double spend problem Double spend (make a transaction and then unrecord it and then spend that money again)
How do you solve this? Similar to the consensus problem where everyone must agree on transactions. We can’t use consensus algos like Paxos or RAFT because its not a closed membership situation(no global view of number of servers....
Notes Types of locks -
Write lock Read lock Predicate lock - Lock where multiple rows are locked for reads(WHERE clause) All of these locks are long locks(Meaning all are acquired first and then all are released)(2 Phase locking) If we wanna improve performance(and decrease isolation levels), we can reduce long locks to short locks.
Types of anomalies - Phantom Reads is we do a search condition (using WHERE clause) and then Read1, Write1 and Read2....
How To Set Correct SSH Directory Permissions in Linux Set Correct SSH Directory Permissions in Linux If you ever encounter errors while trying to SSH into a server, you can set correct ssh directory permissions on the .ssh directory using the chmod command.
# chmod u+rwx,go-rwx ~/.ssh OR # chmod 0700 ~/.ssh If ssh complains of wrong permissions on any of the above files, you can set the correct permissions for any of the files like this:...
Notes Bigtable doesn’t support multi-row/multi-table transactions.
Why does Google need multi-table transactions? Removing duplicates(Multiple URLs may lead to the same website), calculation of pagerank will get affected.
Built on top of big table, because didn’t have that many people working on it and also didn’t have source code access to big table.
Locks Locks in percolator could have been implemented in two ways -
In place(in database) Problem with this is that you can’t maintain complex locks with queues and techniques like wound wait, wait die, etc....