Skip to content

Commit

Permalink
Handle _parent and _routing attributes in response
Browse files Browse the repository at this point in the history
  • Loading branch information
lebauce committed Oct 25, 2016
1 parent 34c4c4d commit 83f25dd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/coresearch.go
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,8 @@ type Hit struct {
Index string `json:"_index"`
Type string `json:"_type,omitempty"`
Id string `json:"_id"`
Parent string `json:"_parent,omitempty"` // for parent/child requests
Routing string `json:"_routing,omitempty"`
Score Float32Nullable `json:"_score,omitempty"` // Filters (no query) dont have score, so is null
Source *json.RawMessage `json:"_source"` // marshalling left to consumer
Fields *json.RawMessage `json:"fields"` // when a field arg is passed to ES, instead of _source it returns fields
Expand Down

0 comments on commit 83f25dd

Please sign in to comment.