先在pom文件引入freemark,thymeleaf的依赖,thymeleaf的html文件放在Resource-templates-thymeleaf目录下,freekmarker的ftl文件放在Resource-templates-freemarker目录下,再properties文件设置各自 ...
分类:
编程语言 时间:
2019-12-25 23:44:27
阅读次数:
117
进入到我们ik分词器安装目录下的config目录 <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd"><properties> <comm ...
分类:
其他好文 时间:
2019-12-25 23:37:10
阅读次数:
120
1、配置类 import com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceBuilder; import org.springframework.boot.context.properties.ConfigurationPrope ...
分类:
编程语言 时间:
2019-12-25 18:57:49
阅读次数:
103
语法demo: PUT es-demo { "settings":{ "number_of_shards":5, "number_of_replicas":1 }, "mappings":{ "TypeName":{ "dynamic":"strict", "properties":{ "title ...
分类:
其他好文 时间:
2019-12-25 01:10:17
阅读次数:
94
关于 一般上来说,当我们创建一个SpringBoot项目时,IDE会默认帮我们创建一个application.properties配置文件。有些朋友习惯把.properties文件改成.yml文件。那么这两种文件类型有什么区别呢? 区别 1.内容格式比较: .properties文件,通过.来连接, ...
分类:
移动开发 时间:
2019-12-24 23:38:17
阅读次数:
93
方法1:绑定对象bean调用 1、在application.properties或者application.yml里面添加我们的配置项: 2、创建一个配置类(该类和我们上面配置项的属性一一对应): import org.springframework.boot.context.properties. ...
分类:
移动开发 时间:
2019-12-24 23:33:17
阅读次数:
115
写在前面的话 相关背景及资源: "曹工说Spring Boot源码(1) Bean Definition到底是什么,附spring思维导图分享" "曹工说Spring Boot源码(2) Bean Definition到底是什么,咱们对着接口,逐个方法讲解" "曹工说Spring Boot源码(3) ...
分类:
编程语言 时间:
2019-12-24 23:21:34
阅读次数:
89
一、配置文件占位符 1、application.properties server.port=8088 debug=false product.id=ID:${random.uuid} product.name=da mao mao product.weight=${random.int} prod ...
分类:
编程语言 时间:
2019-12-24 15:22:11
阅读次数:
93
生成公钥和私钥代码 package utils import ( "crypto/rand" "crypto/rsa" "crypto/x509" "encoding/pem" "fmt" "io/ioutil" ) func GenRSAPubAndPri(bits int,filepath st... ...
分类:
其他好文 时间:
2019-12-24 13:51:24
阅读次数:
137
pycharm2019,中文显示乱码异常,配置了encoding为utf8还是不行,需要设置备用字体 原因是某些英文字体库不支持非英文字符,无法显示 设置fallback字体 File settings Edit Font 如果APPLY后还是无法解决 配色方案中的配色方案字体 类似的,如果运行控制 ...
分类:
其他好文 时间:
2019-12-24 13:46:44
阅读次数:
81