【发布时间】:2019-10-24 21:28:15
【问题描述】:
我正在尝试根据我拥有的不同端点聚合 API 日志。一共有4个端点:
1: /v1/vehicle_locations
2: /v1/vehicle_locations/id
3: /v1/driver_locations
4: /v1/driver_locations/id
我目前这样做的方式是:
_sourceCategory=production | keyvalue auto | where (path matches "/v1/driver_locations" OR path matches "/v1/driver_locations/*" or path matches "/v1/vehicle_locations" or path matches "/v1/vehicle_locations/*") | count by path
问题在于,虽然我得到了 /v1/vehicle_locations 和 /v1/driver_locations 的正确聚合,但我得到了 /v1/driver_locations/id 和 /v1/vehicle_locations/id 的单独结果,因为 id 是通配符。有没有办法也可以聚合这些通配符?
【问题讨论】: