Skip to content

Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance

another fix for unique field computation

Michael Peter Christena694b6a8fcb8
diff --git a/source/net/yacy/cora/federate/solr/SchemaConfiguration.java b/source/net/yacy/cora/federate/solr/SchemaConfiguration.java
index c61955004..7e2696088 100644
--- a/source/net/yacy/cora/federate/solr/SchemaConfiguration.java
+++ b/source/net/yacy/cora/federate/solr/SchemaConfiguration.java
@@ -190,7 +190,16 @@ public class SchemaConfiguration extends Configuration implements Serializable {
continue uniquecheck;
}
try {
- long doccount = segment.fulltext().getDefaultConnector().getCountByQuery("-" + CollectionSchema.id.getSolrFieldName() + ":\"" + urlhash + "\" AND " + CollectionSchema.host_id_s.getSolrFieldName() + ":\"" + hostid + "\" AND " + signaturefield.getSolrFieldName() + ":\"" + signature.toString() + "\"");
+ long doccount = segment.fulltext().getDefaultConnector().getCountByQuery(
+ CollectionSchema.host_id_s.getSolrFieldName() + ":\"" + hostid + "\" AND " +
+ "-" + CollectionSchema.robots_i.getSolrFieldName() + ":8 AND " + // bit 3
+ "-" + CollectionSchema.robots_i.getSolrFieldName() + ":24 AND " + // bit 3 + 4
+ "-" + CollectionSchema.robots_i.getSolrFieldName() + ":512 AND " + // bit 9
+ "-" + CollectionSchema.robots_i.getSolrFieldName() + ":1536 AND " + // bit 9 + 10
+ "(-" + CollectionSchema.canonical_equal_sku_b.getSolrFieldName() + ":[* TO *] OR " + CollectionSchema.canonical_equal_sku_b.getSolrFieldName() + ":true ) AND " +
+ CollectionSchema.httpstatus_i.getSolrFieldName() + ":200 AND " +
+ "-" + CollectionSchema.id.getSolrFieldName() + ":\"" + urlhash + "\" AND " +
+ signaturefield.getSolrFieldName() + ":\"" + signature.toString() + "\"");
sid.setField(uniquefield.getSolrFieldName(), doccount == 0);
} catch (final IOException e) {}
}