0
点赞
收藏
分享

微信扫一扫

Java工程师成神之路

一、基础篇

1.1 JVM

1.1.1. Java内存模型,Java内存管理,Java堆和栈,垃圾回收

  • http://ifeve.com/jmm-faq/

1.1.2. 了解JVM各种参数及调优

1.1.3. 学习使用Java工具

  • http://kenai.com/projects/btrace
  • http://www.crashub.org/
  • https://github.com/taobao/TProfiler
  • https://github.com/CSUG/HouseMD
  • http://wiki.cyclopsgroup.org/jmxterm
  • https://github.com/jlusdy/TBJMap

1.1.4. 学习Java诊断工具

  • http://visualvm.java.net/oqlhelp.html

1.1.5. 自己编写各种outofmemory,stackoverflow程序

1.1.6. 使用工具尝试解决以下问题,并写下总结

1.1.7. 参考资料

  • http://www.cs.umd.edu/~pugh/java/memoryModel/
  • http://gee.cs.oswego.edu/dl/jmm/cookbook.html

1.2. Java基础知识

1.2.1. 阅读源代码

1.2.2. 熟悉Java中各种变量类型

1.2.3. 熟悉Java String的使用,熟悉String的各种函数

1.2.4. 熟悉Java中各种关键字

1.2.5. 学会使用List,Map,Stack,Queue,Set

1.2.6. Java IO & Java NIO,并学会使用

1.2.7. Java反射与javassist

1.2.8. Java序列化

1.2.9. 虚引用,弱引用,软引用

1.2.10. 熟悉Java系统属性

1.2.11. 熟悉Annotation用法

1.2.12. JMS

1.2.13. JMX

1.2.14. 泛型和继承,泛型和擦除

1.2.15. 自动拆箱装箱与字节码

1.2.16. 实现Callback

1.2.17. java.lang.Void类使用

1.2.18. Java Agentpremain函数

1.2.19. 单元测试

  • Jmockit,https://code.google.com/p/jmockit/
  • djUnit,http://works.dgic.co.jp/djunit/

1.2.20. Java实现通过正则表达式提取一段文本中的电子邮件,并将@替换为#输出

1.2.21. 学习使用常用的Java工具库

1.2.22. 什么是API & SPI

  • http://en.wikipedia.org/wiki/Service_provider_interface

1.2.23. 参考资料

  • http://openjdk.java.net/
  • http://commons.apache.org/
  • https://code.google.com/p/guava-libraries/
  • http://netty.io/
  • http://stackoverflow.com/questions/2954372/difference-between-spi-and-api
  • http://stackoverflow.com/questions/11404230/how-to-implement-the-api-spi-pattern-in-java

1.3. Java并发编程

1.3.1. 阅读源代码,并学会使用

1.3.2. 学习使用线程池,自己设计线程池需要注意什么

1.3.3. 锁

1.3.4. synchronized的作用是什么,synchronized和lock

1.3.5. sleep和wait

1.3.6. wait和notify

1.3.7. 写一个死锁的程序

1.3.8. 什么是守护线程,守护线程和非守护线程的区别以及用法

1.3.9. volatile关键字的理解

  • http://en.wikipedia.org/wiki/Volatile_variable
  • http://preshing.com/20130702/the-happens-before-relation/

1.3.10. 以下代码是不是线程安全?为什么?如果为count加上volatile修饰是否能够做到线程安全?你觉得该怎么做是线程安全的?

public class Sample {
  private static int count = 0;
  public static void increment() {
    count++;
  }
}

1.3.11. 解释一下下面两段代码的差别

// 代码1
public class Sample {
  private static int count = 0;
  synchronized public static void increment() {
    count++;
  }
}

// 代码2
public class Sample {
  private static AtomicInteger count = new AtomicInteger(0);
  public static void increment() {
    count.getAndIncrement();
  }
}

1.3.12. 参考资料

  • http://www.intel.com/content/www/us/en/processors/architectures-software-developer-manuals.html

二、 进阶篇

2.1. Java底层知识

2.1.1. 学习了解字节码、class文件格式

  • http://en.wikipedia.org/wiki/Java_bytecode
  • http://en.wikipedia.org/wiki/Java_bytecode_instruction_listings
  • http://www.csg.ci.i.u-tokyo.ac.jp/~chiba/javassist/
  • http://asm.ow2.org/

2.1.2. 写一个程序要求实现javap的功能(手工完成,不借助ASM等工具)

如Java源代码:

public static void main(String[] args) {
    int i = 0;
    i += 1;
    i *= 1;
    System.out.println(i);
  }

编译后读取class文件输出以下代码:

public static void main(java.lang.String[]);
  Code:
   Stack=2, Locals=2, Args_size=1
   0:   iconst_0
   1:   istore_1
   2:   iinc    1, 1
   5:   iload_1
   6:   iconst_1
   7:   imul
   8:   istore_1
   9:   getstatic       #2; //Field java/lang/System.out:Ljava/io/PrintStream;
   12:  iload_1
   13:  invokevirtual   #3; //Method java/io/PrintStream.println:(I)V
   16:  return
  LineNumberTable: 
   line 4: 0
   line 5: 2
   line 6: 5
   line 7: 9
   line 8: 16

2.1.3. CPU缓存,L1,L2,L3和伪共享

  • http://mechanical-sympathy.blogspot.com/2011/07/false-sharing.html

2.1.4. 什么是尾递归

2.1.5. 熟悉位运算

2.1.6. 参考资料

  • http://book.douban.com/subject/6522893/
  • http://en.wikipedia.org/wiki/Java_class_file
  • http://en.wikipedia.org/wiki/Java_bytecode
  • http://en.wikipedia.org/wiki/Java_bytecode_instruction_listings

2.2. 设计模式

2.2.1. 实现AOP

  • 动态代理模式: Javassist实现AOP
  • ASM实现AOP:http://asm.ow2.org/

2.2.2. 使用模板方法设计模式和策略设计模式实现IOC

2.2.3. 不用synchronized和lock,实现线程安全的单例模式

2.2.4. nio和reactor设计模式

2.2.5. 参考资料

  • http://cglib.sourceforge.net/
  • http://www.javassist.org/

2.3. 网络编程知识

2.3.1. Java RMI,Socket,HttpClient

2.3.2. 用Java写一个简单的静态文件的HTTP服务器

2.3.3. 了解nginx和apache服务器的特性并搭建一个对应的服务器

  • http://httpd.apache.org/

2.3.4. 用Java实现FTP、SMTP协议

2.3.5. 什么是CDN?如果实现?DNS起到什么作用?

  • http://www.squid-cache.org/ http://trafficserver.apache.org/
  • http://en.wikipedia.org/wiki/Domain_Name_System

2.3.6. 参考资料

  • http://tools.ietf.org/rfc/rfc5321.txt
  • http://en.wikipedia.org/wiki/Open/closed_principle

2.4. 框架知识

2.5. 应用服务器知识

  • 熟悉使用tomcat,http://tomcat.apache.org/
  • 熟悉使用jetty,http://www.eclipse.org/jetty/

三、 高级篇

3.1. 编译原理知识

3.1.1. 用Java实现以下表达式解析并返回结果(语法和Oracle中的select sysdate-1 from dual类似)

sysdate
sysdate - 1
sysdate - 1/24
sysdate - 1/(12*2)

3.1.2. 实现对一个List通过DSL筛选

QList<Map<String, Object>> mapList = new QList<Map<String, Object>>;
mapList.add({"name": "hatter test"});
mapList.add({"id": -1,"name": "hatter test"});
mapList.add({"id": 0, "name": "hatter test"});
mapList.add({"id": 1, "name": "test test"});
mapList.add({"id": 2, "name": "hatter test"});
mapList.add({"id": 3, "name": "test hatter"});
mapList.query("id is not null and id > 0 and name like '%hatter%'");

要求返回列表中匹配的对象,即最后两个对象;

3.1.3. 用Java实现以下程序(语法和变量作用域处理都和JavaScript类似):

代码:

var a = 1;
var b = 2;
var c = function() {
  var a = 3;
  println(a);
  println(b);
};
c();
println(a);
println(b);

输出:

3
2
1
2

3.1.4. 参考资料

  • https://javacc.java.net/ http://www.antlr.org/

3.2. 操作系统知识

3.3. 数据存储知识

3.3.1. 关系型数据库

3.3.2. NoSQL

3.3.3. 参考资料

  • http://redis.io/
  • https://code.google.com/p/leveldb/
  • http://hbase.apache.org/
  • http://cassandra.apache.org/
  • http://www.mongodb.org/
  • http://www.neo4j.org/

3.4. 大数据知识

3.4.1. Zookeeper,在linux上部署zk

3.4.2. Solr,Lucene,ElasticSearch

3.4.3. Storm,流式计算,了解Spark,S4

3.4.4. Hadoop,离线计算

  • MapReduce:部署JobTracker,TaskTracker,编写mr job
  • Hive:部署hive,书写hive sql,得到结果
  • Presto:类hive,不过比hive快,非常值得学习

3.4.5. 分布式日志收集flume,kafka,logstash

3.4.6. 数据挖掘,mahout

3.4.7. 参考资料

  • https://lucene.apache.org/solr/
  • https://github.com/nathanmarz/storm/wiki
  • http://hadoop.apache.org/
  • http://prestodb.io/
  • http://flume.apache.org/
  • http://logstash.net/
  • http://kafka.apache.org/
  • http://mahout.apache.org/

3.5. 网络安全知识

3.5.1. 什么是DES、AES

3.5.2. 什么是RSA、DSA

3.5.3. 什么是MD5,SHA1

3.5.4. 什么是SSL、TLS,为什么HTTPS相对比较安全

3.5.5. 什么是中间人攻击、如果避免中间人攻击

3.5.6. 什么是DOS、DDOS、CC攻击

3.5.7. 什么是CSRF攻击

3.5.8. 什么是CSS攻击

3.5.9. 什么是SQL注入攻击

3.5.10. 什么是Hash碰撞拒绝服务攻击

3.5.11. 了解并学习下面几种增强安全的技术

  • HOTP http://www.ietf.org/rfc/rfc4226.txt
  • TOTP http://tools.ietf.org/rfc/rfc6238.txt
  • OCRA http://tools.ietf.org/rfc/rfc6287.txt
  • http://en.wikipedia.org/wiki/Salt_(cryptography)

3.5.12. 用openssl签一个证书部署到apache或nginx

3.5.13. 参考资料

  • http://en.wikipedia.org/wiki/Block_cipher
  • http://en.wikipedia.org/wiki/Public-key_cryptography
  • http://en.wikipedia.org/wiki/Transport_Layer_Security
  • http://www.openssl.org/
  • https://code.google.com/p/google-authenticator/

四、 扩展篇

4.1. 相关知识

4.1.1. 云计算,分布式,高可用,可扩展

4.1.2. 虚拟化

  • http://www.linux-kvm.org/page/Main_Page
  • http://www.xenproject.org/
  • https://www.docker.io/

4.1.3. 监控

  • http://ganglia.info/

4.1.4. 负载均衡

4.1.5. 学习使用git

  • https://git.oschina.net/

4.1.6. 学习使用maven

4.1.7. 学习使用gradle

4.1.8. 学习一个小语种语言

4.1.9. 尝试了解编码的本质

public static void main(String[] args) throws IOException {
    String str = "Hello, 我们是中国人。";
    byte[] utf8Bytes = toUTF8Bytes(str);
    FileOutputStream fos = new FileOutputStream("f.txt");
    fos.write(utf8Bytes);
    fos.close();
}
public static byte[] toUTF8Bytes(String str) {
    return null; // TODO
}

想一下上面的程序能不能写一个转GBK的? 写个程序自动判断一个文件是哪种编码

4.1.10. 尝试了解时间的本质

  • ftp://ftp.iana.org/tz/data/asia
  • http://zh.wikipedia.org/wiki/%E4%B8%AD%E5%9C%8B%E6%99%82%E5%8D%80
  • 闰年 http://en.wikipedia.org/wiki/Leap_year
  • 闰秒 ftp://ftp.iana.org/tz/data/leapseconds
  • System.currentTimeMillis()返回的时间是什么

4.1.11. 参考资料

  • http://git-scm.com/
  • http://en.wikipedia.org/wiki/UTF-8
  • http://www.iana.org/time-zones

4.2. 扩展学习

4.2.1. JavaScript知识

4.2.1.1. 什么是prototype

4.2.1.2. 什么是闭包

4.2.1.3. 了解并学习一个JS框架

4.2.1.4. 写一个Greasemonkey插件

4.2.1.5. 学习node.js

4.2.2. 学习html5

4.2.3. 参考资料

  • http://jsfiddle.net/
  • http://jsbin.com/
  • http://runjs.cn/
  • http://userscripts.org/

五、 推荐书籍

  • 《深入理解Java虚拟机》
  • 《Effective Java》
  • 《七周七语言》
  • 《七周七数据》
  • 《Hadoop技术内幕》
  • 《Hbase In Action》
  • 《Mahout In Action》
  • 《这就是搜索引擎》
  • 《Solr In Action》
  • 《深入分析Java Web技术内幕》
  • 《大型网站技术架构》
  • 《高性能MySQL》
  • 《算法导论》
  • 《计算机程序设计艺术》
  • 《代码大全》
  • 《JavaScript权威指南》
举报

相关推荐

0 条评论