Hi!All
有个关于 flume HttpSource 的问题想请问一下大家。
上下文:我想用 flume 的 httpsource 收集来自前端页面中埋点的信息。前端是 react,用 axios 发送 POST 请求。服务器上的 flume 版本是 1.6.0-cdh5.7.0,默认用的是 JSONHandler。
出现的问题是,document 上说 httpsource 接受的数据需要是 One way to create an event in the format expected by this handler is to use JSONEvent provided in the Flume SDK and use Google Gson to create the JSON string using the Gson#fromJson(Object, Type) method.需要 Java 实体对象的意思?
那么是不是需要我先把埋点得到的数据发到服务器转换成实体类,再交给 flume 使用?我总觉得这样略尴尬,需要这一部分转换的话,我宁愿选择其他的 flume source,何必需要 httpsource ?
不知道是不是我的理解有问题,还是操作不对。恳请各位大佬给点指导,或者提供其他什么方案🙏🏻 谢谢!!