JAVA Knowledge Graph

1 JAVA basics

1.1 Algorithm

  Direct Insertion Sort, Hill Sort, Bubble Sort, Quick Sort, Direct Selection Sort, Heap Sort, Merge Sort, Radix Sort

  Binary search tree, red-black tree, B-tree, B+ tree, LSM tree

  BitSet、LRU、LFU、KMP

 

1.2 Basics

  Migration of string constant pool

  Internal details of the intern method of string, changes in jdk1.6 and jdk1.7

  equals和hashcode

  Generics, exceptions, reflection

  Solution to hash conflict

  The principle of foreach loop

  The role of static, final, transient and other keywords 

  The underlying implementation principle of the volatile keyword

  Which sorting method is used by the Collections.sort method

  Future interface, FutureTask implementation in common thread pools, etc. 

 

1.3 Design Patterns and Design Principles

  singleton pattern

  factory pattern

  decorator pattern

  Observer Design Pattern

  ThreadLocal Design Pattern

   

1.4 Regular expressions

  capturing and non-capturing groups

  Greedy, Reluctant, Exclusive Mode

 

1.5 java memory model and garbage collection algorithm

  Class loading mechanism, that is, the parent delegation model

  java memory allocation model (default HotSpot)

    Thread shared: heap area, permanent area Thread exclusive: virtual machine stack, native method stack, program counter

  Memory allocation mechanism: young generation (Eden area, two Survivor areas), old generation, permanent generation and their allocation process

  happens-before rule

  Instruction reordering, memory fences

  Memory Generation Improvements for Java 8

  Garbage collection algorithm (mark-sweep\copy algorithm\mark-sort)

  Commonly used garbage collectors (new generation\old generation)

  Common gc parameters

  Common tools (jps, jstat, jmap, jstack, graphical tools jConsole, Visual VM, MAT, jprofiler)

 

1.6 Source code for locks and concurrent containers

  synchronized and volatile understanding

  The principle of the Unsafe class, use it to implement CAS. Hence the birth of the AtomicInteger series, etc.

  The solution of ABA problems that CAS may generate, such as adding the number of revisions, version number

  The realization principle of synchronizer AQS

  Exclusive lock, shared lock; reentrant exclusive lock ReentrantLock, shared lock implementation principle

  Fair and unfair locks

  The implementation principle of the read-write lock ReentrantReadWriteLock

  LockSupportTools

  Condition interface and its realization principle

  Implementation principle of HashMap, HashSet, ArrayList, LinkedList, HashTable, ConcurrentHashMap, TreeMap

  Concurrency issues with HashMap

  Implementation principle of ConcurrentLinkedQueue

  Fork/Join framework

  CountDownLatch和CyclicBarrier

 

1.7 Thread pool source code

  Internal Execution Principle

  The difference between various thread pools

 

2 web aspects

2.1 Architecture Design of SpringMVC

   SpringMVC's overall processing flow of requests

   The relationship between DispatcherServlet, container, and components

   SpringBoot

 

2.2 SpringAOP source code

   AOP implementation classification

   AOP implementation (AOP alliance, aspectj, jboss AOP, AOP implemented by Spring itself, Spring embedded aspectj)

   The calling process of SpringAOP

   SpringAOP custom implementation (ProxyFactoryBean\aspectj)

 

2.3 Spring Transactions and Distributed Transactions Jotm Atomikos

  Problems with jdbc transactions

  The principle of suspending and resuming transactions

  Propagation properties of transactions

  

  How Spring defines the interface of the transaction system and how to integrate the jdbc transaction and the Hibernate transaction

  Spring transaction interceptor TransactionInterceptor panorama

  Implementation of separation of transaction code from business code (AOP+ThreadLocal)

  

   X/Open DTP model, two-phase commit, JTA interface definition

   The realization principle of Jotm and Atomikos

   

   Implementation principles and differences of PROPAGATION_REQUIRES_NEW and PROPAGATION_NESTED

   transaction model

 

2.4 Database isolation level

   read uncommitted, read committed, repeatable read, serializable

 

2.5 Database

   Database performance optimization

   死锁(Record Locks、Gap Locks、Next-Key Locks)

   Locking of insert into select statement 

   The concept of ACID properties of transactions

   MVCC understanding of innodb

   undo redo binlog

 

2.6 ORM framework: mybatis

   

2.7 SpringSecurity、shiro、SSO

 

2.8 datasource

    (c3p0\druid\jdbcTemplate) 

 

2.9 http protocol & https implementation principle

    http three handshake and four wave

    http status code 301 302 405 

    HTTPS implementation principle

 

 

3 Distributed aspects

3.1  ZooKeeper

  Client Architecture

  Server-side stand-alone and cluster versions, corresponding request handlers

  The establishment and activation process of the cluster version session

  Leader election process and implementation

  ZAB protocol realizes the principle of consistency

  Implement distributed locks, distributed ID distributors 

  Detailed parsing of transaction log and snapshot files

 

3.2 Serialization and Deserialization Framework

  Avro Research

  Thrift Research

  Protobuf Research

  Protostuff Research

  Hessian

 

3.3 RPC framework dubbo source code

  Implementation of dubbo extension mechanism (compared to SPI mechanism)

  Service release process

  Service subscription process

  Design of RPC Communication

 

3.4 NIO module (Netty and Mina, thrift source code)

  TCP handshake and disconnect and finite state machine

  backlog

  BIO NIO

  The difference between blocking/non-blocking, synchronous/asynchronous

  Blocking IO, non-blocking IO, multiplexing IO, asynchronous IO

  Reactor threading model

  The docking implementation of jdk's poll, epoll and the underlying poll, epoll

  Netty's own epoll implementation

  The rough implementation of poll and epoll at the kernel layer

  Edge-triggered and horizontal-triggered for epoll

  Netty's EventLoopGroup design

  Netty's ByteBuf Design

  Netty的ChannelHandler

  Zero Copy of Netty

  Netty's threading model

 

3.5 Message queue kafka, RocketMQ, Notify, Hermes, flume

  Kafka's file storage design

  Kafka's replica replication process

  Leader election process for Kafka replicas

  Kafka's message loss problem

  Kafka's message order problem

  Kafka's isr design and more than half comparison

  

  Transaction design of Notify and RocketMQ

  File based kafka, RocketMQ and database based Notify and Hermes

  What aspects should be considered when designing a messaging system

  Lost messages, message duplication, high availability and other topics  

 

3.6 Database sub-database sub-table mycat

 

3.7 NoSql database mongodb

 

3.8 Cache system memcached redis

  The difference between memcached redis

 

  Redis maintains and manages the client, read and write buffers

  Implementation of redis transaction

  Implementation of Jedis client

  Implementation of JedisPool and ShardedJedisPool

  redis epoll implementation, file events and time events in a loop

  RDB persistence of redis, save and bgsave

  redis AOF command append, file write, file sync to disk

  Redis AOF rewrite, measures taken to reduce blocking time

  Redis's LRU memory recovery algorithm

  Redis master slave replication

  Sentinel high availability solution of redis

  Cluster sharding scheme of redis

 

3.9 Design principles of web server tomcat and ngnix

  The overall architecture design of tomcat

  Tomcat concurrency control of communication

  The whole processing flow of http request reaching tomcat

 

3.10 ELK log real-time processing query system (Elasticsearch, Logstash, Kibana)

 

3.11 Service aspect

  SOA and Microservices

  Merge deployment of services, automatic fast switching and rollback of multiple versions

  Governance of services: throttling, downgrading

  Linear scaling of services (Extension of Redis: consistent hashing, migration tools)

  Service Link Monitoring and Alerting: CAT, Dapper, Pinpoint

 

3.12 Spring Cloud

  Spring Cloud Zookeeper: for service registration and discovery

  Spring Cloud Config: Distributed Configuration

  Spring Cloud Netflix Eureka: for rest service registration and discovery

  Spring Cloud Netflix Hystrix: Isolation, circuit breaker and degradation of services

  Spring Cloud Netflix Zuul: Dynamic Routing, API Gateway

 

3.13 Distributed Transactions

  JTA distributed transaction interface definition, integration with Spring transaction system

  TCC distributed transaction concept

  TCC distributed transaction implementation framework case 1: tcc-transaction

  TCC distributed transaction implementation framework case 2: ByteTCC

 

3.14 Consensus Algorithm

  raft

  ZooKeeper

  paxos

 

 

transferred from

https://maimai.cn/article/detail?fid=103467612

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326621417&siteId=291194637