Better handling for number of returned results.

Added configuration parameters :default-max-search-results and :allowed-max-search-results.