摘要:
关键字Synchronized: 当使用Synchrnized (o) ,锁定 o 的时候,锁定的是 o 指向的堆内存中 new 出来的对象,而非 o 引用,当锁定 o 以后,一旦 o 指向了其他对象,这个时候锁定的对象也会发生改变。在工作开发中经常 new 出一个对象当锁太麻烦了,常用的方法是锁定 阅读全文
摘要:
# Redis configuration file example.## Note that in order to read the configuration file, Redis must be# started with the file path as first argument:# 阅读全文
摘要:
Spring Boot 内嵌了tomcat 。我们可以将Boot打成 jar 包丢到服务器上运行才行。 Spring Boot已经帮我们打理好了这一切,如果项目是继承自 spring-boot-starter-parent ,在pom文件中插入下段配置就可以 <build> <plugins> <p 阅读全文