Koji Sekiguchi wrote:
Usually, you do not need to set facet.method because Solr
automatically uses most appropriate facet method for
each field type:
boolean: TermEnum
multiValued/tokenized: UnInvertedField
other than those above: FieldCache
As I understand it, in Solr 1.4, (and I may NOT understand it, it is
confusing), it would be more clear to say that Solr will by default use
facet.method=enum for boolean, and facet.method=fc for everything else.
facet.method=fc is a strategy that will use one of several different
actual methods depending on field qualities. Looking at the code it
appears to be _more_ than two branches to me of choices, not sure there
are only two methods and it only depends on whether the field is
multiValued/tokenized. But if Koji knows and is sure, maybe he knows
more than me.
It has been suggested on the list and in the wiki, that in Solr 1.4+, if
you have a facet field with "few" unique values (I have not seen better
guidance for exactly what qualifies as 'few', with regard to total
number of documents), it may be profitable to use facet.method=enum.
In Solr 1.4, facet.method=enum DOES work on multi-valued fields, I'm
pretty certain. I think Koji is wrong about that, if I understand Koji
right to say that you can't use facet.method=enum with multi-valued
fields, this is not in fact true.
I think it is somewhat more complicated in 1.4+ than Koji suggests,
although I don't understand it well enough to explain it completely. I
think Koji's explanation is based on before Solr 1.4 made improvements
to the faceting algorithms.