[ 
https://issues.apache.org/jira/browse/DROIDS-56?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12995054#comment-12995054
 ] 

Eugen Paraschiv commented on DROIDS-56:
---------------------------------------

I don't see why not. A Filter or FilterValidator can surely have this 
responsibility, and it fits well with the concept of the chain (I introduced 
the ChainValidator for this very reason). For the purposes of this particular 
patch, the current logic is that the queue has a validator and each time a new 
task is added to it, it is first validated via that validator. With the patch, 
there is no SimpleTaskQueue to accept a validator, so this logic (whether it is 
Filter or Validator) should probably be added to CrawlingWorker, right before 
the addAll call (one option). This is to allow the client to inject a validator 
into the worker. 
Eugen. 

> Change the TaskQueue interface to java.util.Queue
> -------------------------------------------------
>
>                 Key: DROIDS-56
>                 URL: https://issues.apache.org/jira/browse/DROIDS-56
>             Project: Droids
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 0.0.1
>            Reporter: Mingfai Ma
>         Attachments: Queue.diff, droids-56-v2.diff, droids-56.diff, 
> taskQueue-to-queue.diff
>
>
> 1. any code that depends on the queue should depend on java.util.Queue<T> 
> rather than TaskQueue. 
> 2. either remove the TaskQueue or make it extends java.util.Queue
>  - it means SimpleTaskQueue should extends a Queue implementation (or 
> implement all method of a Queue)

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to