// deserialize document into Product
LOG.info("Parsing Solr document: "+doc);
QueryResponse queryResponse = productSerializer.deserialize(doc);
int numFound = queryResponse.getNumFound();
if (numFound>1) {
throw new CatalogException("Product query returned "+numFound+" results instead of 1!");
} else if (numFound==0) {
return null; // no product found
} else {
return queryResponse.getCompleteProducts().get(0);
}