or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Do you want to remove this version name and description?
Syncing
xxxxxxxxxx
回首過去,看 KKBOX 怎麼走搜尋音樂這條路 - Eason Chen
歡迎來到 https://hackmd.io/c/COSCUP2018 共筆
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →點擊本頁上方的 開始用 Markdown 一起寫筆記!
手機版請點選上方 按鈕展開議程列表。
常見問題
有哪些地方用到搜尋
曲庫資料放在mysql
效能不可靠(用關聯度在全文檢索會1. 累積大量 query 資料拖慢效能 2. 準確度不佳)
搜尋工作要交給專業的來
應用
聊天機器人
KUBE (免費 無廣告)
KUBE 官方
KUBE
統計
目前用Elasticsearch當搜尋的核心架構
MeCab 日文分詞工具
OpenCC 繁簡轉換
容錯處理
編輯字串越少越相近 越大越不同
例如搜尋Dangerous,會出現Danger Mouse,因為找不到完全一樣的,所以會找最接近的
Autocomplete
Edge n-gram
Context Suggester
資料處理
配置
如果data node異常而且又是master node會有短暫空窗區
所以乾脆分離 master歸master
Cron server to gearman worker
索引更新現在是1小時1次,所以會影響搜尋結果,速度和正確是互斥的要自己取決平衡點
導入 Consul 原因
升級 ES 到 5.6
升級計畫
連續執行5天,確認搜尋結果和差異是符合預期的
備援計畫
升級效益
為什麼沒有升到6.x?
因為還在觀望中
讓子彈飛一會兒
升級成本很高
監控
用過幾套
Munin
圖太復古
太忙會掉圖
Kibana + Marvel
性能指標豐富
介面操作容易
資料來源穩定
kibana vs Grafana
Kibana
資料來源: ES
Grafana
資料來源:
Grafana介面很像戰情中心
且好修改
https://grafana.com/dashboards/7259
地表最完整ES Dashboard
Github SourceCode
https://github.com/KKBOX/grafana-elasticsearch-dashboard
踩坑全紀錄
Case 1 - Swap Issue
某天在打電動 Slack 突然噴錯誤通知,趕快先重開機
第5台掛了,第4台接手,但因為第4台機器IO效能不及格,在接手歌單時才會有問題
server 5開始動用到SWAP
效能大幅下降
Disabled swap
swap is the killer for efficient
The offical recommanding turning off swapping.
Case 2 - 機器負載分布不均
本來就不可能每台機器負載都一樣
索引文件分配不均
熱門資料分散
重構是為了減少機器運算效能
調整過後就回到自動Sharding
Case 3 - 搜尋效能下降
問題發問
Q1: 已經用Prometheus了 為什麼還要用Grafana的alert
A:沒特別去測Prometheus怎麼使用,Grafana可以用就直接用
Q2: 在未來做更多搜尋方式,例如曲風 音頻特徵?
A:曲風搜尋有計畫要做,規劃中
音頻算是多維資料在做搜尋會有些問題
Q3: 台灣比較少有找原廠諮詢的行為 請問有沒有打算找ES原廠協助
A: 反正OpenSource,喜歡自幹,挑戰自我
挑戰自我
Q4: 找繁體中文也會出現簡體中文內容
A: 只有索引做了簡轉繁 不影響曲目資料庫的資料
Q5: 版本轉換 1.x ~5.x,遇到搜尋語法改變的問題? 如filter不能用之類的
A:
階段性進行
1.6 to 2.4
1.6有filter,2.4希望全部轉query
2.4 to 5.6
scope語法大改
聊天區
是否要提供使用麥克風的錄音?(音樂播放完畢)
我發現項目符號有 * 派系和 - 派系呢
看起來是正常的就好 markdown設計就是那樣XD
context suggester 我沒有聽到原理,有人可以補充嗎

他也只說用FST而已
OK :)
為什麼有歌名有 emoji
because stuffs and reasons
建議一行不要打太長歐 別人也好幫你補充
一開始就用項目符號還蠻難補充東西進去的ORZ
給我翻譯翻譯 什麼是升級!
老闆說要升級 就有了升級
tags:
COSCUP2018
misc