会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
orbc
首页
管理
2020年7月23日
XXP7 笔试题
摘要: XXP7 笔试题 1. junit 用法,before,beforeClass,after, afterClass 的执行顺序 2. 分布式锁 3. nginx 的请求转发算法,如何配置根据权重转发 4. 用 hashmap 实现 redis 有什么问题(死锁,死循环,可用 ConcurrentH
阅读全文
posted @ 2020-07-23 10:35 orbc
阅读(365)
评论(0)
推荐(0)
2020年7月22日
CGLib Proxy
摘要: Enhancer enhancer = new Enhancer(); enhancer.setSuperclass(Dog.class); enhancer.setCallback(new MethodInterceptor() { @Override public Object intercep
阅读全文
posted @ 2020-07-22 14:41 orbc
阅读(119)
评论(0)
推荐(0)
JDK Proxy
摘要: //创建一个实例对象,这个对象是被代理的对象 Person zhangsan = new Student("张三"); //创建一个与代理对象相关联的InvocationHandler InvocationHandler stuHandler = new StuInvocationHandler<P
阅读全文
posted @ 2020-07-22 14:17 orbc
阅读(165)
评论(0)
推荐(0)
2020年7月16日
Spring容器的初始化
摘要: AbstractApplicationContext @Override public void refresh() throws BeansException, IllegalStateException { synchronized (this.startupShutdownMonitor) {
阅读全文
posted @ 2020-07-16 09:06 orbc
阅读(142)
评论(0)
推荐(0)
2020年7月15日
Spring MVC
摘要: 一共有三个容器: Tomcat 容器 Spring 容器 Spring MVC容器
阅读全文
posted @ 2020-07-15 15:57 orbc
阅读(87)
评论(0)
推荐(0)
2020年7月13日
AOP
摘要: AOP(Aspect Oriented Programming): 通过预编译方式和运行期间动态代理实现程序功能的统一维护的一种技术。 对代理类进行访问控制,不会修改代理类中元素的数量。spring容器中的bean不是代理对象 Spring中是实现: JDK Proxy 和 CGLib Proxy
阅读全文
posted @ 2020-07-13 16:46 orbc
阅读(57)
评论(0)
推荐(0)
IoC
摘要: IoC(Inversion of Control): 一种设计思想 Spring中的实现: 主要类 BeanFactory DefaultListableBeanFactory ApplicationContext 实现原理: 加载配置文件或者扫描注解 依赖注入完成Bean的实例化 依赖注入(Dep
阅读全文
posted @ 2020-07-13 16:33 orbc
阅读(122)
评论(0)
推荐(0)
反射
摘要: 反射: 在运行状态中,通过类的Class,调用它的任意方法和属性。 Class获取方式: 通过字面量直接获取,如Class clazz = Person.class , 未完成初始化 通过Object类的getClass方法,如Class clazz = Person.getClass(),已完成初
阅读全文
posted @ 2020-07-13 15:56 orbc
阅读(92)
评论(0)
推荐(0)
CAS
摘要: CAS:Compare and Swap,即比较再交换。一种无锁算法 CAS有3个操作数 1、内存值 :V 2、复制的内存值,旧值:A 3、新值: B if(V == A){ V = B; } 步骤: t1和t2线程都同时去访问内存中同一变量,该变量的值为: A, 把 A 完全拷贝一份到自己的工作内
阅读全文
posted @ 2020-07-13 15:06 orbc
阅读(66)
评论(0)
推荐(0)