🐝
Mess around software system design
  • README
  • ArchitectureTradeOffAnalysis
    • Estimation
    • Middleware
    • Network
    • Server
    • Storage
  • Conversion cheat sheet
  • Scenarios
    • TinyURL
      • Estimation
      • Flowchart
      • Shortening mechanisms
      • Rest API
      • Performance
      • Storage
      • Follow-up
    • TaskScheduler
      • JDK delay queue
      • Timer based
      • RabbitMQ based
      • Kafka-based fixed delay time
      • Redis-based customized delay time
      • MySQL-based customized delay time
      • Timer TimingWheel
      • Industrial Scheduler
      • Workflow Engine
      • Airflow Arch
    • GoogleDrive
      • Estimation
      • Flowchart
      • Storage
      • Follow-up
    • Youtube
      • Estimation
      • Flowchart
      • Performance
      • Storage
      • Follow-up
      • Netflix
    • Uber
      • Estimation
      • Rest api
      • Flowchart
      • KNN algorithms
      • Geohash-based KNN mechanism
      • Redis implementation
      • Storage
    • Twitter
      • Estimation
      • Flowchart
      • Storage
      • Scalability
      • Follow-up
    • Instant messenger
      • Architecture overview
      • Presence
      • Unread count
      • Notifications
      • Read receipt
      • Large group chat
      • Storage-Offline 1:1 Chat
      • Storage-Offline group chat
      • Storage-Message roaming
      • NonFunc-Realtime
      • NonFunc-Reliability
      • NonFunc-Ordering
      • NonFunc-Security
      • Livecast-LinkedIn
    • Distributed Lock
      • Single machine
      • AP model based
      • CP model based
      • Chubby-TODO
    • Payment system
      • Resilience
      • Consistency
      • Flash sale
    • Key value store
      • Master-slave KV
      • Peer-to-peer KV
      • Distributed cache
  • Time series scenarios
    • Observability
      • TimeSeries data
      • Distributed traces
      • Logs
      • Metrics
      • NonFunc requirments
  • Search engine
    • Typeahead
    • Search engine
    • Distributed crawler
      • Estimation
      • Flowchart
      • Efficiency
      • Robustness
      • Performance
      • Storage
      • Standalone implementation
      • Python Scrapy framework
    • Stream search
  • Big data
    • GFS/HDFS
      • Data flow
      • High availability
      • Consistency
    • Map reduce
    • Big table/Hbase
    • Haystack
    • TopK
    • Stateful stream
    • Lambda architecture
    • storm架构
    • Beam架构
    • Comparing stream frameworks
    • Instagram-[TODO]
  • MicroSvcs
    • Service Registry
      • Flowchart
      • Data model
      • High availability
      • Comparison
      • Implementation
    • Service governance
      • Load balancing
      • Circuit breaker
      • Bulkhead
      • Downgrade
      • Timeout
      • API gateway
      • RateLimiter
        • Config
        • Algorithm comparison
        • Sliding window
        • Industrial impl
    • MicroSvcs_ConfigCenter-[TODO]
    • MicroSvcs_Security
      • Authentication
      • Authorization
      • Privacy
  • Cache
    • Typical topics
      • Expiration algorithm
      • Access patterns
      • Cache penetration
      • Big key
      • Hot key
      • Distributed lock
      • Data consistency
      • High availability
    • Cache_Redis
      • Data structure
      • ACID
      • Performance
      • Availability
      • Cluster
      • Applications
    • Cache_Memcached
  • Message queue
    • Overview
    • Kafka
      • Ordering
      • At least once
      • Message backlog
      • Consumer idempotency
      • High performance
      • Internal leader election
    • MySQL-based msg queue
    • Other msg queues
      • ActiveMQ-TODO
      • RabbitMQ-TODO
      • RocketMQ-TODO
      • Comparison between MQ
  • Traditional DB
    • Index data structure
    • Index categories
    • Lock
    • MVCC
    • Redo & Undo logs
    • Binlog
    • Schema design
    • DB optimization
    • Distributed transactions
    • High availability
    • Scalability
    • DB migration
    • Partition
    • Sharding
      • Sharding strategies
      • Sharding ID generator overview
        • Auto-increment key
        • UUID
        • Snowflake
        • Implement example
      • Cross-shard pagination queries
      • Non-shard key queries
      • Capacity planning
  • Non-Traditional DB
    • NoSQL overview
    • Rum guess
    • Data structure
    • MySQL based key value
    • KeyValueStore
    • ObjectStore
    • ElasticSearch
    • TableStore-[TODO]
    • Time series DB
    • DistributedAcidDatabase-[TODO]
  • Java basics
    • IO
    • Exception handling
  • Java concurrency
    • Overview
      • Synchronized
      • Reentrant lock
      • Concurrent collections
      • CAS
      • Others
    • Codes
      • ThreadLocal
      • ThreadPool
      • ThreadLifeCycle
      • SingletonPattern
      • Future
      • BlockingQueue
      • Counter
      • ConcurrentHashmap
      • DelayedQueue
  • Java JVM
    • Overview
    • Dynamic proxy
    • Class loading
    • Garbage collection
    • Visibility
  • Server
    • Nginx-[TODO]
  • Distributed system theories
    • Elementary school with CAP
    • Consistency
      • Eventual with Gossip
      • Strong with Raft
      • Tunable with Quorum
      • Fault tolerant with BFT-TODO
      • AutoMerge with CRDT
    • Time in distributed system
      • Logical time
      • Physical time
    • DDIA_Studying-[TODO]
  • Protocols
    • ApiDesign
      • REST
      • RPC
    • Websockets
    • Serialization
      • Thrift
      • Avro
    • HTTP
    • HTTPS
    • Netty-TODO
  • Statistical data structure
    • BloomFilter
    • HyperLoglog
    • CountMinSketch
  • DevOps
    • Container_Docker
    • Container_Kubernetes-[TODO]
  • Network components
    • CDN
    • DNS
    • Load balancer
    • Reverse proxy
    • 云中网络-TODO
  • Templates
    • interviewRecord
  • TODO
    • RecommendationSystem-[TODO]
    • SessionServer-[TODO]
    • Disk
    • Unix philosophy and Kafka
    • Bitcoin
    • Design pattern
      • StateMachine
      • Factory
    • Akka
    • GoogleDoc
      • CRDT
Powered by GitBook
On this page
  • 02/17
  • Service owner
  • System design
  • 03/02
  • Self introduction
  • Design Uber eats
  • Architecture design
  • Dive into detail
  • 疏忽的地方
  • 可扩展性

Was this helpful?

  1. Templates

interviewRecord

Previous云中网络-TODONextRecommendationSystem-[TODO]

Last updated 3 years ago

Was this helpful?

02/17

Service owner

  • 对于自己service的认知还缺很多

    • 知道service的bottleneck

    • 知道service的scale up/down方式

    • 知道service的metric

  • 又做development又做maintainence

    • Estimation怎么做,自己选什么样的machine

    • 为什么选8个cores, 而不是6个cores

    • 别人把这个requirement定义好了,对于service本身考虑

  • License based, 又是从AAD拿的

    • 自己的cache

    • 自己的cache怎么和AAD做synchronization

  • 怎么样represent自己作为service owner

System design

逻辑性

  • 想问题的方式,customer需要什么

  • 一定要从customer入手,tiny url需要什么,长什么样

  • Customer看到五个character, 可以怎么来

Assumption

  • Teams - 非常modern的application

  • read heavy, write less

  • Relation database支持的QPS

    • 50K, 普通的hardware肯定是不行的

    • 愿意用这么costy的hardware来support

  • Make了一些decision

    • 设计系统需要什么

    • 考察面试者有没有经过自己认真的思考

    • 有没有好的reason去支持他的决定

    • 要么你改了,要么自己不确定自己是否是正确的

    • Take feedback

      • 是否跟自己的想法,要做的是否是一致的

      • 了解面试官给自己feedback的原因,两个人想法有没有在一条线上

        • 从Slave那里去读的

        • 没有去想自己怎么样去回答

      • Balance为什么好,是否所有的都需要balance

面试官的expectation

  • Level +1 or -1

    • 如果很懂很懂,会调节面试

    • 如果只是知道一些concept,但是没法灵活运用

  • 先要figure out出requirement

  • Clarify assumption

  • 做些basic estimation

  • 做个high level design, 他们之间怎么talk to

    • 讲两三个detailed component:

      • API design

      • DB sharding

  • Scale

  • Disater recovery

讲自己擅长的一些东西

  • 擅长API design

    • naming

  • 擅长Decouple

  • 那个很表面

    • 做system design的时候他们不会和你说非常detail的东西

    • 把这些东西都往一个上面套的时候

自己做过的项目

  • 哪些可以换个方式做,都走的是short-term

  • 怎么样把short-term变成long-term

    • 这样就会有很多的想法

  • 去找senior和principal

    • 怎样让system考虑得更多,他们提到一些词或者想法

    • 很少有人

  • 知道很多edge case的东西是别人不知道的

    • 面试官会很surprise的,

  • metrics不会无缘无故的

    • 既然fire了能不能dive deep一点

    • 有些时候host, metrics

    • 各式各样的问题,整个analysis的过程会让自己对system更加了解

      • 要用怎么样的load balancer

      • build shape

    • flaky的问题

    • service不是我own的时候需要去刨根接地

03/02

Self introduction

  • 准备一些常见的问题:biggest challenge

    • 一开始还是比较high level, 能给一些具体的example

    • 和其他人怎么合作

    • 你和其他人意见不一致

Design Uber eats

  • Clarify更清楚

    • 需不需要ranking

    • 怎么样ranking

    • 这一页显示些什么东西

    • Feeds上有个照片或者meta data

    • Open hour

    • Menu

Architecture design

  • 可以做得更好是强调solution的trade off, 用MySQL和NoSQL的database用哪个更好

  • 区分Senior和Level4/5, 知道哪个会更好些

Dive into detail

  • geo-index: 如果没有了解过Geo Index

  • Elastic Search里面已经有了,用Tree的模式,是一个BiTree

  • 多刷题,多看题,GeoIndex比较经典的面试问题

  • NonSQL database:

    • 更容易改变Schema,

  • 熟悉哪些database, Cassandra

疏忽的地方

  • 下一步应该怎么做,直接return给user

  • 哪些restaurant是直接可以送到user这里的,

  • Filtering

    • Query时就可以做Filter

    • 有一个阶段去fetch restaurant data

  • Ranking

    • 即使是Product software engineer

    • 用什么样的machine learning model

可扩展性

  • 做estimation

  • 更重要的是sense of scalability

    • 具体的solution应该怎么样做 10K QPS或者1000K QPS

    • 最简单的sharding方式

      • 根据city来sharding

      • 一个区来sharding

  • 从Web到CDN

  • Server之前

  • Service data base:

  • 画个图,到哪几层

02/17
Service owner
System design
逻辑性
Assumption
面试官的expectation
讲自己擅长的一些东西
自己做过的项目
03/02
Self introduction
Design Uber eats
Architecture design
Dive into detail
疏忽的地方
可扩展性