As the JDBC ElasticSearch (E.S.) river is causing lots of pain w/our OIT setup, I'm writing a new driver to push MySQL data to E.S. This differs from the JDBC E.S. river which pulls the data. If I do this right the frontend could also pull from ElasticSearch using a REST API and/or have a decent public API.
As the old driver didn't like complex JSON I'm thinking of changing the 'schema' to be:
Courses
"_index" = "course"
"_type" = "undergrad" (graduate)
"_id" = "courseID"
example documentURL = http://localhost:9200/course/MATH1502
example document:
{ "department" : "Math",
"number" : 1502,
"name" : "Calculus 2",
"description" : "This class will go over......etc",
"gpa" : 4.0,
"professors" : { "Morley, Tom" : { "GPA" : 4.0, "profid" : "MORLEYTOM" },
"Last, First" : { "GPA" : 2.1, "profid" : "LASTFIRST" },
}
}
Professor
"_index" = "professor"
"_type" = ...not sure what to put here yet....
"_id" = "profID"
example documentURL = http://localhost:9200/proffessor/BLOUGHDOUGLASM
example document:
{
"name" : "Douglas M, Blough",
"undergrad" : {
"gpa" : 3.8,
"courses" : {
"ECE 3020" : { "gpa" : 4.0, "courseid" : "ECE3020" } ,
"ECE 2030" : { "gpa" : 2.0, "courseid" : "ECE2030" }
}
},
"graduate" : {
"gpa" : 3.2,
"courses" : {
"ECE 4445" : { "gpa" : 4.0}
}
}
}