Facet Performance

Hi

Now, I have two facet queries

Query 1:
curl -XGET 'http://localhost:9200/new_index/new_indext/_search' -d '{
"query": {
"filtered": {
"query": {
"bool": {
"should": [
{
"field": {
"MsgData": "google"
}
}
],
"minimum_number_should_match": 1
}
},
"filter": {
"range": {
"CreatedAt": {
"from": "2012-6-12T00:00:00",
"to": "2012-7-23T23:59:59"
}
}
}
}
},
"facets": {
"MsgData": {
"terms": {
"field": "MsgData",
"size": 100
}
}
}
}'

Query 2:

curl -XGET 'http://localhost:9200/new_index/new_indext/_search' -d
'{"query": {"bool": {"should": [
{
"field": {
"MsgData": "google"
}
}
],
"minimum_number_should_match": 1
}},
"facets": {
"MsgData": {
"terms": {
"field": "MsgData",
"size": 20
},
"facet_filter": {"range": {"CreatedAt": {"from":
"2012-6-12T00:00:00","to": "2012-7-23T23:59:59"}}}
}
}

}'

Are they differ in performance and memory usage? Which one would be
fast and using less heap space?

Thanks,
Pulkit Agrawal