lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vineeth Dasaraju <>
Subject Custom Response Writer for JSON Objects
Date Wed, 22 Jul 2015 07:47:16 GMT

I have been using json objects of the form shown below to index into solr.
As you can see, there are nested JSON objects and JSON arrays.

    "RawEventMessage": "Lorem ipsum dolor sit amet, consectetur adipiscing
elit. Aliquam dolor orci, placerat ac pretium a, tincidunt consectetur
mauris. Etiam sollicitudin sapien id odio tempus, non sodales odio iaculis.
Donec fringilla diam at placerat interdum. Proin vitae arcu non augue
facilisis auctor id non neque. Integer non nibh sit amet justo facilisis
semper a vel ligula. Pellentesque commodo vulputate consequat. ",
    "EventUid": "1279706565",
    "TimeOfEvent": "2015-05-01-08-07-13",
    "TimeOfEventUTC": "2015-05-01-01-07-13",
    "EventCollector": "kafka",
    "EventMessageType": "kafka-@column",
    "User": {
        "User": "Lorem ipsum",
        "UserGroup": "Manager",
        "Location": "consectetur adipiscing",
        "Department": "Legal"
    "EventDescription": {
        "EventApplicationName": "",
        "Query": "SELECT * FROM MOVIES",
        "Information": [
                "domainName": "English",
                "columns": [
                        "movieName": "Casablanca",
                        "duration": "154",
                        "movieName": "Die Hard",
                        "duration": "127",
                "domainName": "Hindi",
                "columns": [
                        "movieName": "DDLJ",
                        "duration": "176",

For indexing this object, I am creating a parent JSON Object that contains
all the top level attributes and am creating child objects for all nested
JSON objects and linking the two of the. The problem arises that when I
query for a top level attribute, I get only 1 document that shows only the
top level attributes but does not contain any of the nested json objects.
How can I ensure that I get JSON objects similar to the way they are
originally indexed into Solr? Is there any custom response writer in Solr
that can achieve this functionality?


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message