V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX  ›  429463267  ›  全部回复第 2 页 / 共 13 页
回复总数  257
1  2  3  4  5  6  7  8  9  10 ... 13  
2021-09-24 09:44:14 +08:00
回复了 429463267 创建的主题 汽车 30W 以内的新能源 SUV 选途观 L 2022 插电混动款怎么样?
@aliensb 为什么呢?
> 公司稳定、双休不加班、不拖欠工资、团队和谐、可以提供转 Java 或者 go 的机会

这个标题秀出了你司的优越感吗?
2021-08-21 08:29:26 +08:00
回复了 xinyana 创建的主题 奇思妙想 谁能做一个 ditto 网络版?
ditto 本身自带内网传输功能,可以打开菜单看看,设置密码即可在局域网内装有 ditto 客户端机器同步剪贴板。
完全一样的情况,马上 30 了,相亲见过很多女生,基本都不是很热情,回复冷淡,而且大多没啥素质。
@Morriaty
下载源码看了一眼,有很多依赖都是来自一个 infini.sh 的站点,然鹅,这个站点已经无法访问了。所以二次开发受阻。
@Morriaty 谢谢老哥,我去围观下
https://www.cnblogs.com/zhoujie/p/kong2.html

看了 kong 的文档,发现他的 路由能力太弱了,无法解析请求体。
@plko345

这是我用 fiddler 抓到的包,详细记录了 spark 使用 ESHaghilevelClient 写入数据的 HTTP 报文:

```http

### spark ESOperator 写入
POST http://1.2.3.4:9200/_bulk?timeout=1m HTTP/1.1
Content-Length: 500
Content-Type: application/json
Host: 1.2.3.4:9200
Connection: Keep-Alive
User-Agent: Apache-HttpAsyncClient/4.1.4 (Java/1.8.0_181)
Authorization: Basic ***

{"index":{"_index":"index2","_id":"3"}}
{"content":"这是内容 3","doc_id":3,"headline":"标题 3"}
{"index":{"_index":"index2","_id":"4"}}
{"content":"这是内容 4","doc_id":4,"headline":"标题 4"}
{"index":{"_index":"index1","_id":"1"}}
{"content":"这是内容 1","doc_id":1,"headline":"标题 1"}
{"index":{"_index":"index1","_id":"2"}}
{"content":"这是内容 2","doc_id":2,"headline":"标题 2"}
{"index":{"_index":"index1","_id":"1"}}
{"content":"这是内容 5","doc_id":1,"headline":"标题 5"}

### 响应
HTTP/1.1 200 OK
content-type: application/json; charset=UTF-8
content-length: 928

{"took":1731,"errors":false,"items":[{"index":{"_index":"index2","_type":"_doc","_id":"3","_version":1,"result":"created","_shards":{"total":2,"successful":2,"failed":0},"_seq_no":0,"_primary_term":1,"status":201}},{"index":{"_index":"index2","_type":"_doc","_id":"4","_version":1,"result":"created","_shards":{"total":2,"successful":2,"failed":0},"_seq_no":1,"_primary_term":1,"status":201}},{"index":{"_index":"index1","_type":"_doc","_id":"1","_version":1,"result":"created","_shards":{"total":2,"successful":2,"failed":0},"_seq_no":0,"_primary_term":1,"status":201}},{"index":{"_index":"index1","_type":"_doc","_id":"2","_version":1,"result":"created","_shards":{"total":2,"successful":2,"failed":0},"_seq_no":1,"_primary_term":1,"status":201}},{"index":{"_index":"index1","_type":"_doc","_id":"1","_version":2,"result":"updated","_shards":{"total":2,"successful":2,"failed":0},"_seq_no":2,"_primary_term":1,"status":200}}]}
###

### ESClient 删除 index
DELETE http://12.3.4:9200/index1 HTTP/1.1
Content-Length: 0
Host: 1.2.3.4:9200
Connection: Keep-Alive
User-Agent: Apache-HttpAsyncClient/4.1.4 (Java/1.8.0_181)
Authorization: Basic ***

### 响应
HTTP/1.1 200 OK
content-type: application/json; charset=UTF-8
content-length: 21

{"acknowledged":true}
###
```

初步想法是解析 ReqBody,然后根据 index 名称拆分为多个 http 请求发到对应的 ES 集群上,最后响应全部结果给客户端。
但是响应的报文格式应该是无法兼容 ESHighLevelClient 。。。
@defunct9 https://sm.ms/image/Msbm1uINDnLAl5d

traefik 看上去略显弱势
@tanxnative 如果只有一个集群的话,可以通过分片算法来分发数据,
但是多个集群之间,目前没有现成方案。
@plko345 没在 k8s,在 AWS 服务器上
2021-07-22 07:55:00 +08:00
回复了 netwjx 创建的主题 问与答 编程工作适合用什么鼠标?
楼上那么多用触控板的,怎么精确点击,比如要定位到代码的某一行某一列时,难道要用触控板去滑动?左手键盘,右手鼠标,这才是效率最高的姿势吧?
既然 es JAVA 客户端使用 http 协议通信,那么在网关层,可以通过请求的 method 、host 、path 、query params 、reqbody 来动态映射目标 es 集群
背景图,喧宾夺主
2021-07-20 14:16:40 +08:00
回复了 aqtata 创建的主题 程序员 你们都有自己的 utils 吗?
2021-07-18 13:37:46 +08:00
回复了 aqtata 创建的主题 程序员 你们都有自己的 utils 吗?
Hutool 默秒全
1  2  3  4  5  6  7  8  9  10 ... 13  
关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   5984 人在线   最高记录 6543   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 39ms · UTC 06:13 · PVG 14:13 · LAX 23:13 · JFK 02:13
Developed with CodeLauncher
♥ Do have faith in what you're doing.