上一页 1 2 3 4 5 6 ··· 13 下一页

2022年2月25日

elastaicsearch简单入门项目

摘要: application.yml spring: elasticsearch: host: 目标服务器 #本机就localhost,远程则写公网地址,注意开放端口,下同,例如127.0.0.1 port: 9300 cluster-name: my-application rest: uris: ht 阅读全文

posted @ 2022-02-25 16:12 Esquecer 阅读(79) 评论(0) 推荐(0) 编辑

elasticsearch 相关(ELK)

摘要: windows环境 els版本是7.12.0,下载地址https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.12.0-windows-x86_64.zip kibana 7.12.0 https://artifact 阅读全文

posted @ 2022-02-25 11:24 Esquecer 阅读(20) 评论(0) 推荐(0) 编辑

2020年4月10日

GC垃圾回收

摘要: 一、堆内存分区 YGC Minor GCEden区不足 FGCFull GC Old区不足多数情况下对老年代回收的时候对年轻代也会回收 二、GC方法 第一种:标记清除 原理:分为标记和清除两个阶段:首先标记出所有的需要回收的对象,在标记完成以后统一回收所有被标记的对象。特点:(1)效率问题,标记和清 阅读全文

posted @ 2020-04-10 17:12 Esquecer 阅读(210) 评论(0) 推荐(0) 编辑

2020年3月31日

Java锁相关知识

摘要: 阅读全文

posted @ 2020-03-31 17:01 Esquecer 阅读(93) 评论(0) 推荐(0) 编辑

2020年3月27日

Codeforces Round #629 (Div. 3) A、B、C

摘要: 传送门:点我 A:Divisibility Problem 大意:T组数据 给定a b ,a每次只能加一,问多少次操作后能让a%b==0 思路:如果a比b大,那么答案是(a/b+1)*b-a或者直接输出0(不用操作) 如果a比b小,答案是b-a 代码: #include<bits/stdc++.h> 阅读全文

posted @ 2020-03-27 22:56 Esquecer 阅读(165) 评论(0) 推荐(0) 编辑

2020年3月20日

AtomicInteger的Increment方法的自己实现。

摘要: package demo01; import sun.misc.Unsafe; import java.lang.reflect.Field; public class testUnsafe { static final Unsafe unsafe; static final long offset 阅读全文

posted @ 2020-03-20 21:46 Esquecer 阅读(275) 评论(0) 推荐(0) 编辑

2020年3月18日

两个线程,一个输出字母一个输出数字,输出A1B2C3....Z26

摘要: 思路1 :用一个变量记录属于哪个线程执行,然后另外一个线程阻塞掉即可。 public class main { static volatile int a = 1; public static void main(String[] args) { new Thread(new Runnable() 阅读全文

posted @ 2020-03-18 14:26 Esquecer 阅读(712) 评论(0) 推荐(0) 编辑

2020年3月17日

NIO记录

摘要: 小demo: 服务器端代码 package demoNio; import com.oracle.nio.BufferSecrets; import java.io.IOException; import java.net.InetSocketAddress; import java.nio.Buf 阅读全文

posted @ 2020-03-17 23:45 Esquecer 阅读(151) 评论(0) 推荐(0) 编辑

2020年2月11日

mysql优化相关

摘要: mysql 可以使用field函数进行自定义排序 格式为:select * from table order by field(str1,str2,str3,str4); 查看一条sql语句实际使用时间 set profiling=1; show profiles; show profile;sho 阅读全文

posted @ 2020-02-11 20:56 Esquecer 阅读(125) 评论(0) 推荐(0) 编辑

2020年2月9日

一些Nginx的Linux命令和conf配置文件

摘要: lsof -i :80 查看80端口状态 netstat -tunlp 查看所有端口状态 可以跟上 | grep xxxx 例如 netstat -tunlp | grep nginx 检查nginx配置文件命令 ../sbin/nginx -g ../conf/nginx.conf 只更新ngin 阅读全文

posted @ 2020-02-09 11:19 Esquecer 阅读(741) 评论(0) 推荐(0) 编辑

上一页 1 2 3 4 5 6 ··· 13 下一页

导航