openedx-vlead / cc-pf-tests

Contains scripts for calculating performance of the college cloud server
0 stars 1 forks source link

Converting text files to json files in ELK stack #1

Open Karthik183 opened 7 years ago

Karthik183 commented 7 years ago

How to convert text files which contains logs of the system to Json format so that we can give json fies to elastic search directly

Karthik183 commented 7 years ago

wrote a python code which takes sample.txt as input and gives sample.json as output. it takes first row of files as available fields of the index and from second row it inserts values to the available fields till the last row.