0
votes

I am trying to find x-sw-client-id value i.e. self-service-automation from below log. key is always same but value will be different based on the client. could you suggest me a regex or query to find the number of clients hitting my service?

POST : http://selfservice.host.io/service
36677 > host: billing-host.io
36677 > user-agent: unirest-java/1.2.11 32322 > x-key: self-service 
36677 > x-app-name: Self_Service_Consumer
36677 > x-sw-client-id: self-service-automation
36677 > x-forwarded-for: 111.111.110.134, 120.24.519.232, 110.423.232.432 
36677 > x-forwarded-host: api-qa-self-service.host.io 
36677 > x-forwarded-port: 443
1

1 Answers

0
votes

Try this. Your new field name will be "ClientID"

... | rex x\-sw\-client\-id\:\s(?<ClientID>\S+)