File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
system-design/framework/spring Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -311,6 +311,6 @@ myStack.pop();//报错:java.lang.IllegalArgumentException: Stack is empty.
311311- ** 阻塞队列:** 阻塞队列可以看成在队列基础上加了阻塞操作的队列。当队列为空的时候,出队操作阻塞,当队列满的时候,入队操作阻塞。使用阻塞队列我们可以很容易实现“生产者 - 消费者“模型。
312312- ** 线程池中的请求/任务队列:** 线程池中没有空闲线程时,新的任务请求线程资源时,线程池该如何处理呢?答案是将这些请求放在队列中,当有空闲线程的时候,会循环中反复从队列中获取任务来执行。队列分为无界队列(基于链表)和有界队列(基于数组)。无界队列的特点就是可以一直入列,除非系统资源耗尽,比如 :` FixedThreadPool ` 使用无界队列 ` LinkedBlockingQueue ` 。但是有界队列就不一样了,当队列满的话后面再有任务/请求就会拒绝,在 Java 中的体现就是会抛出` java.util.concurrent.RejectedExecutionException ` 异常。
313313- Linux 内核进程队列(按优先级排队)
314- - 现实生活中的派对 ,播放器上的播放列表;
314+ - 现实生活中的排队 ,播放器上的播放列表;
315315- 消息队列
316316- 等等......
Original file line number Diff line number Diff line change @@ -136,7 +136,7 @@ public @interface SpringBootConfiguration {
136136@Retention (RetentionPolicy . RUNTIME )
137137@Documented
138138@Inherited
139- @AutoConfigurationPackage // 作用:将main包下的所欲组件注册到容器中
139+ @AutoConfigurationPackage // 作用:将main包下的所有组件注册到容器中
140140@Import ({AutoConfigurationImportSelector . class}) // 加载自动装配类 xxxAutoconfiguration
141141public @interface EnableAutoConfiguration {
142142 String ENABLED_OVERRIDE_PROPERTY = " spring.boot.enableautoconfiguration" ;
You can’t perform that action at this time.
0 commit comments