团队研发文档

开发规范、技术文档等


点击热力图指标存储方案

<h3>热力图点击日志示例 (已urlcode解码)</h3> <p>【et=3】<a href="http://dataapi.cn.miaozhen.com/monitor/e.gif?cc=1&ck=1&cl=32-bit&ds=375x667&ep=[{"x":-115,"y":695,"w":375,"h":667,"t":"b"},{"x":84,"y":620,"w":375,"h":667,"t":"b"},{"x":204,"y":606,"w":375,"h":667,"t":"b"}]&et=3&ja=0&ln=zh-CN&lt=1547641937&nv=0&rnd=1446004181&si=mzzgp6eo&st=4&v=1.0.0&lv=3&tt=秒针水表&u=http%3A%2F%2Fmatrix.cn.miaozhen.com%2Fkol%2Findex.htm&wxr=omsP2w7bLINlqYgmDZZKm2DOUDNY&wxp=omsP2w7bLINlqYgmDZZKm2DOUDNY&wxo=omsP2w7bLINlqYgmDZZKm2DOUDNY&wxn=0&uc=1&vc=63&net=3g+&openid=omsP2w7bLINlqYgmDZZKm2DOUDNY&ua=Mozilla%2F5.0%20(iPhone%3B%20CPU%20iPhone%20OS%2012_1%20like%20Mac%20OS%20X)%20AppleWebKit%2F605.1.15%20(KHTML%2C%20like%20Gecko)%20Mobile%2F16B92%20MicroMessenger%2F6.7.3(0x16070321)%20NetType%2F4G%20Language%2Fzh_CN&cid=20190116222051d568c0867f9&rqn=3">http://dataapi.cn.miaozhen.com/monitor/e.gif?cc=1&ck=1&cl=32-bit&ds=375x667&ep=[{"x":-115,"y":695,"w":375,"h":667,"t":"b"},{"x":84,"y":620,"w":375,"h":667,"t":"b"},{"x":204,"y":606,"w":375,"h":667,"t":"b"}]&et=3&ja=0&ln=zh-CN&lt=1547641937&nv=0&rnd=1446004181&si=mzzgp6eo&st=4&v=1.0.0&lv=3&tt=秒针水表&u=http%3A%2F%2Fmatrix.cn.miaozhen.com%2Fkol%2Findex.htm&wxr=omsP2w7bLINlqYgmDZZKm2DOUDNY&wxp=omsP2w7bLINlqYgmDZZKm2DOUDNY&wxo=omsP2w7bLINlqYgmDZZKm2DOUDNY&wxn=0&uc=1&vc=63&net=3g+&openid=omsP2w7bLINlqYgmDZZKm2DOUDNY&ua=Mozilla%2F5.0%20(iPhone%3B%20CPU%20iPhone%20OS%2012_1%20like%20Mac%20OS%20X)%20AppleWebKit%2F605.1.15%20(KHTML%2C%20like%20Gecko)%20Mobile%2F16B92%20MicroMessenger%2F6.7.3(0x16070321)%20NetType%2F4G%20Language%2Fzh_CN&cid=20190116222051d568c0867f9&rqn=3</a> </div></p> <h3>存储指标说明</h3> <table> <thead> <tr> <th>指标</th> <th>日志字段</th> <th>存储逻辑</th> <th>说明</th> </tr> </thead> <tbody> <tr> <td>屏幕尺寸</td> <td>ds = a * b</td> <td>a为宽度,b为高度存储,业务能够区分出「宽a」和「高b」</td> <td>每个用户的使用的屏幕尺寸不一样</td> </tr> <tr> <td>点击座标</td> <td>ep=[{&quot;x&quot;:84,&quot;y&quot;:620,&quot;w&quot;:375,&quot;h&quot;:667,&quot;t&quot;:&quot;b&quot;}]</td> <td>x、y分别为横纵坐标,w和h为屏幕宽高。需要<span style="color:red"><strong>分别存储相对位置信息</strong></span>,即『x/a』和『y/b』。便于不同尺寸画图时选取位置逻辑一致。同时需要存储<span style="color:red"><strong>一个辅助变量(由相对位置生成的唯一值)</strong></span>,业务根据此唯一值聚合同一位置的点击信息</td> <td>屏幕尺寸不一样,相同x和y的两个位置不是等价的,相对位置十等价的</td> </tr> <tr> </tr> <tr> <td>活动id</td> <td>si</td> </tr> <tr> <td>会话id</td> <td>cid</td> </tr> <tr> <td>会话序号</td> <td>rqn</td> </tr> <tr> <td>用户id</td> <td>openid</td> </tr> <tr> <td>页面URL</td> <td>u</td> </tr> <tr> <td>时间</td> </tr> <tr> <td>地域</td> </tr> <tr> <td>渠道</td> </tr> <tr> <td>客户端</td> </tr> </tbody> </table> <ol> <li>每个用户使用的设备不一样,获取到的屏幕信息也不一样</li> </ol>

页面列表

ITEM_HTML