src/main/java/com/findupon/commons/searchparty/AbstractProductGatherer.java
/**
	 * Check to see if are on the right path (missing ids in range, finding enough identifiers & products)
	 * If not, abort and set the ds accordingly
	 */
Check to see if are on the right path (missing ids in range, finding enough identifiers & products)
If not, abort and set the ds accordingly
Check to see if are on the right path ( missing ids in range finding enough identifiers & products ) If not abort and set the ds accordingly
private void verifyValidCrawlState(long currentCrawlTimeMillis) {
		if(!abort.get()) {
			String error = null;
			int currentProductIds = insensitiveProductIds.size();
			int currentBuiltAutomobiles = builtProducts.intValue();
			if(identifierAbortThreshold.shouldAbort(currentProductIds, currentCrawlTimeMillis, TimeUnit.MILLISECONDS)) {
				error = String.format("Product identifiers %d less than allowed for current time %s",
						currentProductIds, TimeUtils.format(currentCrawlTimeMillis));
			} else if(productAbortThreshold.shouldAbort(currentBuiltAutomobiles, currentCrawlTimeMillis, TimeUnit.MILLISECONDS)) {
				error = String.format("Build products %d less than allowed for current time %s",
						currentBuiltAutomobiles, TimeUtils.format(currentCrawlTimeMillis));
			}
			if(error != null) {
				abort.set(true);
				setFailureStatus(DataSourceStatusReason.NO_PRODUCTS, error);
			}
		}
	}
private void verifyValidCrawlState ( long currentCrawlTimeMillis ) { if ( ! abort . get ( ) ) { String error = null ; int currentProductIds = insensitiveProductIds . size ( ) ; int currentBuiltAutomobiles = builtProducts . intValue ( ) ; if ( identifierAbortThreshold . shouldAbort ( currentProductIds , currentCrawlTimeMillis , TimeUnit . MILLISECONDS ) ) { error = String . format ( "Product identifiers %d less than allowed for current time %s" , currentProductIds , TimeUtils . format ( currentCrawlTimeMillis ) ) ; } else if ( productAbortThreshold . shouldAbort ( currentBuiltAutomobiles , currentCrawlTimeMillis , TimeUnit . MILLISECONDS ) ) { error = String . format ( "Build products %d less than allowed for current time %s" , currentBuiltAutomobiles , TimeUtils . format ( currentCrawlTimeMillis ) ) ; } if ( error != null ) { abort . set ( true ) ; setFailureStatus ( DataSourceStatusReason . NO_PRODUCTS , error ) ; } } }
Check to see if are on the right path (missing ids in range, finding enough identifiers & products)
 If not, abort and set the ds accordingly
Check to see if are on the right path ( missing ids in range finding enough identifiers & products ) If not abort and set the ds accordingly