I'm trying to insert my csv
report into elastisearch through logstash. But not able to insert successfully.
My csv
data look as given below.
1,1234556,30-12-2022,frank.van,SAMPLE_PRODUCT,"[Name] Frank Van Puffelen JAVA.
[Area/Pin] San Francisco, CA
[Region/Status/Identify] Android Plaltfrom
[Case#] Jira-01234
[Problem] Messaging app not booting.
[Staring Point] Google service for the notifications
[Evaluate] Cloud Messaging.
[Verification Mode] Local Device.
[Empname] Frank Van.
Domain:Cloud_S,Android:S_OS
***** Ticket Status : https://jenkins.company.com/job/889900112 *****
"
And my logstash conf file as follows.
input {
file {
path => "/home/user/logs/app.csv"
start_position => "beginning"
sincedb_path => "/dev/null"
}
}
filter {
csv {
separator => ","
columns => ["Sl.No", "Emp_ID", "Date", "Emp_Name", "Product_Name", "Item_Details"]
}
}
output {
elasticsearch {
hosts => "localhost:9200"
index => "java-app"
document_type => "Emp_ID"
}
stdout{}
}
Since in Item_Details
column i have Double quotes, Spaces in between words and special characters
i can't insert successfully into logstash.
csv {
separator => ","
quote_char => "\""
columns => ["Item_Details"]
}
mutate {
gsub => ["Item_Details", "\s+", ""]
}
Above filters couldn't sovle my case, So please let me know how do i insert my csv data As-it-is
into Elasticsearch?