X Tutup
Skip to content

Commit 3bed00a

Browse files
committed
interview doc
1 parent a434f3b commit 3bed00a

File tree

7 files changed

+1330
-728
lines changed

7 files changed

+1330
-728
lines changed

docs/.DS_Store

0 Bytes
Binary file not shown.

docs/interview/Elasticsearch-FAQ.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ categories: Interview
8787
8888

8989

90-
### 🎯 ES 中的**索引(Index)、类型(Type,7.x 之后废弃)、文档(Document)、字段(Field)**分别是什么?
90+
### 🎯 ES 中的索引(Index)、类型(Type,7.x 之后废弃)、文档(Document)、字段(Field)分别是什么?
9191

9292
- **Index**:类似“库”,由多个分片(Shard)组成。
9393

@@ -148,7 +148,7 @@ categories: Interview
148148

149149
### 🎯 倒排索引是什么?为什么 ES 查询快?
150150

151-
传统的我们的检索是通过文章,逐个遍历找到对应关键词的位置。**而倒排索引,是通过分词策略,形成了词和文章的映射关系表,这种词典+映射表即为倒排索引**。有了倒排索引,就能实现`o(1)时间复杂度` 的效率检索文章了,极大的提高了检索效率。![在这里插入图片描述](https://img-blog.csdnimg.cn/2019011923160111.png)
151+
传统的我们的检索是通过文章,逐个遍历找到对应关键词的位置。**而倒排索引,是通过分词策略,形成了词和文章的映射关系表,这种词典+映射表即为倒排索引**。有了倒排索引,就能实现`o(1)时间复杂度` 的效率检索文章了,极大的提高了检索效率。![在这里插入图片描述](https://www3.nd.edu/~pbui/teaching/cse.30331.fa16/static/img/mapreduce-wordcount.png)
152152

153153
学术的解答方式:
154154

docs/interview/JVM-FAQ.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1900,6 +1900,8 @@ System.out.println("max_memory(-xmx)="+maxMemory+"字节," +(maxMemory/(double
19001900

19011901
### 🎯 如何查看JVM的内存使用情况?
19021902

1903+
> JVM 内存可以通过 JDK 自带工具(jstat、jmap、jcmd)在命令行查看,也可以用 jconsole、visualvm 图形化分析。如果线上系统,我会用 Arthas 或结合 Prometheus + Grafana 做实时监控。在代码里,还可以通过 JMX 的 MemoryMXBean 获取堆内存使用情况。
1904+
19031905
一、命令行工具
19041906

19051907
1. **`jps` + `jstat` 组合**

docs/interview/Java-Basics-FAQ.md

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1656,7 +1656,7 @@ List<Integer> list = new ArrayList<>();
16561656
> Integer a = 127;
16571657
> Integer b = 127;
16581658
> System.out.println(a == b); // true(同一缓存对象)
1659-
>
1659+
>
16601660
> Integer c = 128;
16611661
> Integer d = 128;
16621662
> System.out.println(c == d); // false(新创建对象)
@@ -2574,8 +2574,6 @@ class NumberBox<T extends Number> {
25742574
25752575
### 🎯 注解的原理?
25762576

2577-
**📋 标准话术**
2578-
25792577
> "Java注解是一种特殊的'接口',用于为代码提供元数据信息:
25802578
>
25812579
> **注解的本质**
@@ -2635,8 +2633,6 @@ class NumberBox<T extends Number> {
26352633
>
26362634
> 反射是框架设计的灵魂,但在日常开发中应谨慎使用。"
26372635
2638-
**💻 代码示例**
2639-
26402636
```java
26412637
import java.lang.annotation.*;
26422638
import java.lang.reflect.*;

0 commit comments

Comments
 (0)
X Tutup