Skip to content

Instantly share code, notes, and snippets.

View SrinivasDhulipalla's full-sized avatar

SrinivasDhulipalla SrinivasDhulipalla

View GitHub Profile
@SrinivasDhulipalla
SrinivasDhulipalla / benchmark-commands.txt
Created February 17, 2020 10:21 — forked from jkreps/benchmark-commands.txt
Kafka Benchmark Commands
Producer
Setup
bin/kafka-topics.sh --zookeeper esv4-hcl197.grid.linkedin.com:2181 --create --topic test-rep-one --partitions 6 --replication-factor 1
bin/kafka-topics.sh --zookeeper esv4-hcl197.grid.linkedin.com:2181 --create --topic test --partitions 6 --replication-factor 3
Single thread, no replication
bin/kafka-run-class.sh org.apache.kafka.clients.tools.ProducerPerformance test7 50000000 100 -1 acks=1 bootstrap.servers=esv4-hcl198.grid.linkedin.com:9092 buffer.memory=67108864 batch.size=8196
@SrinivasDhulipalla
SrinivasDhulipalla / System Design.md
Created November 1, 2018 11:22 — forked from vasanthk/System Design.md
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@SrinivasDhulipalla
SrinivasDhulipalla / intensivedata.txt
Created November 1, 2018 11:00 — forked from SerCeMan/intensivedata.txt
Designing Data-Intensive Applications: The Big Ideas Behind Reliable, Scalable, and Maintainable Systems
# Designing Data-Intensive Applications: The Big Ideas Behind Reliable, Scalable, and Maintainable Systems
1. **Chapter 1. Reliable, Scalable and Maintainable Applications**
1. R faults != failures, faults cause failures. Systems should be fault-tolerant, resistant to some types of faults
2. S Amazon cares about 99.9% percentile because people with higher latencies usually are people who have the most data and therefore, they’re most valuable customers
3. S tail latency amplification - multiple requests one critical path during one page served
2. **Chapter 2. Data Models and Query Languages**
1. Hierarchical model - imperative querying, no way to change schema, children are ordered, no many-to-many
2. CODASYL (network) vs SQL
3. NoSQL - often no schema (precisely - schema on read vs schema on write)
package cv.hibernate;
import org.hibernate.FetchMode;
import org.hibernate.HibernateException;
import org.hibernate.MappingException;
import org.hibernate.QueryException;
import org.hibernate.cache.spi.access.CollectionRegionAccessStrategy;
import org.hibernate.cache.spi.entry.CacheEntryStructure;
import org.hibernate.collection.spi.PersistentCollection;
import org.hibernate.engine.spi.LoadQueryInfluencers;
/*
Infix to postfix conversion in C++
Input Postfix expression must be in a desired format.
Operands and operator, both must be single character.
Only '+' , '-' , '*', '/' and '$' (for exponentiation) operators are expected.
*/
#include<iostream>
#include<stack>
#include<string>