-
Go 定时任务
周期性任务 每5秒执行一次。 func main() { ticker := time.NewTicker(time.Second * 5) g
2021-07-21,阅读:1796,标签:Go
-
Go 数字转字符串
int 类型 使用strconv.Itoa转换。 var age = 18 fmt.Println(strconv.Itoa(age)) int64 类型 使用
2021-07-20,阅读:1493,标签:Go
-
Go 加密算法之 sha1
代码 func main() { // 0f9de62fce790f9a083d5c99e95740ceb90c27ed data := []
2021-07-19,阅读:2692,标签:Go
-
Go 加密算法之 md5
代码 func main() { arr := md5.Sum([]byte("hello world")) // 乱码 log.Pr
2021-07-18,阅读:1876,标签:Go
-
Java 中判断奇偶性的方法
%2 与2取模。 System.out.println(0%2); // 0 System.out.println(1%2); // 1 System.out.
2021-07-17,阅读:2175,标签:Java
-
wget ERROR The certificate was signed using an insecure algorithm
错误信息 --2021-05-27 13:16:43-- https://www.php.net/distributions/php-7.3.24.tar.g
2021-07-16,阅读:2647,标签:wget
-
javac 错误: 编码 GBK 的不可映射字符
原因 Windows平台下PowerShell默认的编码为GBK。 解决 指定编码格式为UTF-8。 javac -encoding UTF-8 Test.ja
-
AWS 更换 SSH 登陆密钥对
生成公钥 根据pem生成 ssh-keygen -f test.pem -y 输出 ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQ
-
SpringMVC 中的 redirect 和 forward 区别
代码 @Controller public class RedirectForwardController { @GetMapping("/test1
-
Windows 使用 Wireshark 抓取本地数据包
说明 Wireshark需安装Npcap后,才能抓取本地数据包。 安装 Npcap Npcap 1.20下载地址:https://nmap.org/npcap/
-
只有一部分接口跨域问题
现象 已经配置了Nginx,使其拦截OPTIONS请求,解决跨域问题。 大部分接口可以跨域访问了,但有一个接口还是提示跨域请求。 排查 查看Nginx的acce
-
IDEA jclasslib 插件改为英文
原因 jclasslib插件做了本地化功能,因此在中文电脑中显示为中文。 修改 点击Help,点击Edit Custom Vm Options…,增加以下配置后
-
SQL Server 修改计算机名后修改服务名
版本 基于SQL Server 2012。 说明 修改计算机名,使用SQL Server Management Studio登录时服务名就要改为新的计算机名。
2021-07-09,阅读:2037,标签:SQL Server
-
Test.class found in top-level directory (unnamed package not allowed in module)
具体错误 Error occurred during initialization of boot layer java.lang.module.FindExc
2021-07-08,阅读:4534,标签:Java
-
IDEA java: package is not visible
错误信息 java: package jdk.nashorn.internal.runtime.regexp.joni.constants is not vis
-
IDEA Cannot resolve plugin org.apache.maven.plugins:maven-clean-plugin:2.5
问题 maven-clean-plugin无法下载,项目无法编译运行。 解决方法 IDEA 中 在IDEA中可以直接在pom.xml中右键,选择Maven,再选
-
PHP No input file specified 解决办法
场景 Windows、php-cgi、Nginx、ThinkPHP 启动 php-cgi 监听9000端口,指定配置文件 .\php-cgi.exe -b 12
-
Chrome & Edge 常用快捷键
快捷键 清除缓存 Ctrl + Shift + Delete 浏览器任务管理器 Shift + Esc 显示或隐藏书签栏 Ctrl + Shift + B 在页
-
Visual Studio Code 快捷键更改为 Intellij IDEA
插件 VS Code中有一款插件叫做IntelliJ IDEA Keybindings 下载 下载页面:https://github.com/kasecato/
-
Windows 删除服务
查看服务名 右键 - 属性 - 服务名称 删除服务 以管理员身份打开CMD,执行以下命令(该命令在PowerShell中不报错,但也无效) sc delete
2021-07-02,阅读:1497,标签:Windows