BUG: Solr FTS engine appends domain name to index records

G H uothrawn at yahoo.com
Tue Aug 12 13:35:48 UTC 2014


The Solr FTS engine appends domain names to the "user" and "id" fields inside Solr when indexing. However, when an IMAP search is performed, the domain name is not appended, resulting in 0 results, 100% of the time.


You can reproduce this by setting up dovecot to have user names like "admin", "james", etc (as opposed to admin at example.com). Then import some mail (ie: "dovecot-lda -d admin < /tmp/mymail.txt"). Now attempt to search for that mail and it will not be returned as a result. You can see in the Solr GUI (http://xxxx:8983/solr/) that record is indexed as:
      {
        "uid": 1,
        "box": "7dff0b0d4f84df53f25300003d823887",
        "user": "admin at example.com",
        "id": "1/7dff0b0d4f84df53f25300003d823887/admin at example.com",
        "_version_": 1475511406809841700
      }

However, the IMAP search is sent to Solr performed with user:"admin" instead of user:"admin at example.com".

Either the Solr FTS plugin needs to not append the domain name or the search does need to do so.


More information about the dovecot mailing list