Alibaba ants gold dress 2020 financial core sector through internships surface (Redis + Memcache + TCP + IOC + AOP +

Alibaba ants gold dress 2020 financial core sector through internships surface (Redis + Memcache + TCP + IOC + AOP +

Side (personal feeling pretty good answer)

1. Self-introduction
2. The said project, the project asked very deep (done an article on the issue of positioning FULL GC and optimization of the project as well as a more complicated project I mentioned before)

2.1 Is it clear through the system for their own production in the positioning of the project?
2.2 Is it clear to the various modules of the system?
Tps 2.3 per interface?
2.4 dependent on the downstream systems for?
2.5 For the middleware, the framework is clear?

3. Do you think you're doing the project highlights the most things?
Similar differences in the middle of the redis 4. memcache, the advantages and disadvantages? Use Precautions What?

memcache type of data can be stored only string type, and can be stored redis character, list, sorted List, hash data type;
memcache does not support data persistence, redis support RDB, AOF persistence;
memcache do not support cluster, redis support redis-cluster cluster

5. redis Distributed Lock talk

I mentioned the redis SETNX () method, and the use of the redis KV structure, Lock use the map structure as a key, Key corresponding value, map the use request requestId as a map of the key, the expiration time as the map value, acquire the lock using cas algorithm, more time is overdue to acquire and release locks

6. TCP, UDP
concurrency 7. multiple concurrent projects, there is no pressure measured before, and QPS, a message requesting the amount is too large, use task queues will create its own without the memory burst?
8. Redis cluster master data synchronization from

主从集群实现了数据的读写分离,主服务器负责读写,偏重写,从服务器只负责读。主服务器启动之后向从服务器发送日志文件,从服务器根据日志文件进行数据的更新,之后如果主服务器有写操作,也会向从服务器发送相应的写操作

9. Zookeeper实现选举的原理

zk的选举过程中其起始所有结点的状态为looking,当某个结点的选票超过所有结点数的一半,该结点就会成为leader,结点状态为leading,其他结点会成为followers,结点状态为following。选举的依据是(sid,zxid)数据,sid代表结点的ID,zxid代表事务ID,选举过程中每个结点第一轮选举会选举自己作为leader,将(sid,zxid)发送给其他结点,其他结点收到数据(sid,zxid)与自身的数据做比较,如果zxid比自身zxid的要大,则直接选举当前结点;如果小于,坚持选举自己;如果zxid相等,比较sid哪个大,大者作为leader。

10. 说说分布式(我说的是Dubbo)
11. 数据库事务,分布式数据一致性如何实现?

读者可以了解一下ZAB协议,我大概就是围着ZAB协议说的

12. SpringIOC,SpringAOP

我简单说了说IOC,AOP的原理,以及原理依赖的模式

13. 数据库事务的隔离级别

四大隔离界别:Uncommitted-read Commited-read Repeated-read Serializable分别针对数据库脏读,不可重复读,虚读问题

14. 谈谈RPC

RPC远程调用,说了说原理,使用到的组件,以及RPC主要的任务:序列化,传输数据,方法调用(方法对应的ID)

15. 算法题:笔试题-最短路径问题(这道题是通过的)
某物流派送员p,需要给a、b、c、d4个快递点派送包裹,请问派送员需要选择什么的路线,才能完成最短路程的派送。假设如图派送员的起点坐标(0,0),派送路线只能沿着图中的方格边行驶,每个小格都是正方形,且边长为1,如p到d的距离就是4。随机输入n个派送点坐标,求输出最短派送路线值(从起点开始完成n个点派送并回到起始点的距离)。

我的做法是使用排列算法,将所有的情况排列出来,计算最短路径

二面(个人感觉回答的特别垃圾,六道问题回答了两道)

1. 自我介绍
2. 怼项目,各个角度刁难
3. FULL GC问题排查工具

我做项目时其实没有使用什么工具,就是用Linux命令TOP,TOP交互命令 1,H;jsatck,jstat以及JVM的相关参数和JVM日志的查看

4. 从事开发遇到最具有难度的问题
5. Spring事务,嵌套事务

这道题其实我是被问懵了,我回答得相当不好,一直回答事务隔离那一块,面试完我总结了一下有关Spring事务相关知识点

6. 面向接口编程的好处是什么

问的问题太抽象,我回答不好,面试官说不够完善

7. 数据库两个insert同时操作同一张表,第一个线程操作一半,问第二个线程会发生什么?

我回答的稀巴烂,下来查了一下,大概就是说这里涉及到的锁是间歇锁,读者可以看看相关知识

8. 说说死锁

举个例子,两个线程1和2,两个锁a和b,线程1拿到a锁后申请要b锁,而同时线程2已经拿到b锁,要申请a锁,两个线程之间陷入僵持状态

总结

After two faces technical, that is, HR, this is not to say. The overall feeling of ants gold dress interview, the interviewer is very professional, very familiar with the basic knowledge required, be sure to prepare before the interview and then go to the interview. LeetCode title should brush.
Remember before the interview be sure to brush the question and preparing items on the resume are not familiar with do not write up, ready to write up the project 2-3 technical solutions.

At last

Codeword is not easy, that help can help point a praise, so that more people need to see

Another year of job hunting season here, I prepared a set of Java programmers selection of high-frequency written interview Zhenti for you, to help you capture offer BAT, the range of topics from basic to advanced junior Java distributed architecture so a series of interview questions and answers, to give you as a reference, you need to add three thousand people can exchange group 860,113,481, the following is part shots, learn together and progress together

Alibaba ants gold dress 2020 financial core sector through internships surface (Redis + Memcache + TCP + IOC + AOP +

Guess you like

Origin blog.51cto.com/14230003/2418861