學(xué)習(xí)筆記 - 2018
1胳蛮、Bmob 云存儲(chǔ)
2坐慰、Model & Module
Model 模型
Module 模塊
3谭期、jenkins
Spring Cloud 沒(méi)有提供發(fā)布平臺(tái)饱亮,因?yàn)閖enkins已經(jīng)足夠完善了个盆,推薦使用jenkins來(lái)部署Spring Boot項(xiàng)目
4灸拍、java -jar app.jar --spring.profiles.active=dev就是啟動(dòng)測(cè)試環(huán)境的配置文件
5、找到博客也就找到人和組織了
6砾省、thymeleaf
Spring Cloud只是后端服務(wù)治理的一套框架鸡岗,唯一和前端有關(guān)系的是thymeleaf,Spring推薦使用它做模板引擎
7编兄、zuul
前端app或者網(wǎng)頁(yè)通過(guò)zuul來(lái)調(diào)用后端的服務(wù)轩性,如果包含靜態(tài)資源也可以使用nginx做一下代理轉(zhuǎn)發(fā)
8、nginx
9狠鸳、Turbine揣苏、zipkin可以用來(lái)做熔斷和性能監(jiān)控
10、lombok
lombok注解為java類(lèi)生成Getter/Setter方法
11件舵、Spring Security
在Spring Boot中使用Spring Security實(shí)現(xiàn)權(quán)限控制
12卸察、去除toolbar中左邊距問(wèn)題
在項(xiàng)目中的解決辦法是:
加載一個(gè)屬性:app:contentInsetStart="0dp"
另外,也可以重寫(xiě)style
原文地址:去除toolbar中左邊距問(wèn)題
13铅祸、java中 String StringBuffer StringBuilder
String 長(zhǎng)度大小不可變
StringBuffer 和 StringBuilder 長(zhǎng)度可變
StringBuffer 線程安全 StringBuilder 線程不安全
StringBuilder 速度快
14坑质、lawyer
15、阻塞隊(duì)列
LinA
15临梗、js獲取url傳遞參數(shù)涡扼,js獲取url?號(hào)后面的參數(shù)
<Script language="javascript">
function GetRequest() {
var url = location.search; //獲取url中"?"符后的字串
var theRequest = new Object();
if (url.indexOf("?") != -1) {
var str = url.substr(1);
strs = str.split("&");
for(var i = 0; i < strs.length; i ++) {
theRequest[strs[i].split("=")[0]]=unescape(strs[i].split("=")[1]);
}
}
return theRequest;
}
</script>
其他參數(shù)獲取介紹:
//設(shè)置或獲取對(duì)象指定的文件名或路徑盟庞。
alert(window.location.pathname);
//設(shè)置或獲取整個(gè) URL 為字符串吃沪。
alert(window.location.href);
//設(shè)置或獲取與 URL 關(guān)聯(lián)的端口號(hào)碼。
alert(window.location.port);
//設(shè)置或獲取 URL 的協(xié)議部分什猖。
alert(window.location.protocol);
//設(shè)置或獲取 href 屬性中在井號(hào)“#”后面的分段票彪。
alert(window.location.hash);
//設(shè)置或獲取 location 或 URL 的 hostname 和 port 號(hào)碼。
alert(window.location.host);
//設(shè)置或獲取 href 屬性中跟在問(wèn)號(hào)后面的部分不狮。
alert(window.location.search);
js獲取url傳遞參數(shù)降铸,js獲取url?號(hào)后面的參數(shù)
16荤傲、JPA
MySQL Workbench
@Entity(name="")
@Temoral(TemporalType.TIMESTAMP)
priavte Date dateCreated;
public interface TaskRepository extend CrudRepository<Task, Integer> {}
@Service
@Transactional
public class TaskService {
private final TaskRepository task....;
}
logger.level ...=debug
17垮耳、
select count(0) from (
select * from tName
) a