Refactor Executors, QueryOperation and Extractors
GoogleCodeExporter opened this issue · comments
Analyzing current Executors i could see that there are too many dependencies
with several Extractors which in the end are not used by the Executor but only
passed as parameters to the QueryOperation object that uses them to generate
the query.
I could see here too much coupling and too many responsibilities assigned to
the QueryOperation class which creates a query and executes it.
I refactored the current code and i introduced a concept of QueryGenerator (i'm
happy to go for a different names if you like), which actually is the one that
requires Extractors as collaborators and generates a query.
With this change i've been able to remove code and depedencies from Executors
which now require a QueryGenerator object (automatically injected by Guice).
I believe that these changes will simplify future improvements. Please check
them out if you are interested and let me know :)
edo
Original issue reported on code.google.com by edoardo.tosca
on 10 Nov 2011 at 12:10
Here the patch for trunk (revision 278)
Original comment by edoardo.tosca
on 10 Nov 2011 at 12:11
Attachments:
Here the patch for trunk (revision 280)
Original comment by edoardo.tosca
on 10 Nov 2011 at 12:37
Attachments:
Thanks Edoardo, I'll take a look to this refactor.
Original comment by tflo...@gmail.com
on 14 Nov 2011 at 11:46
- Changed state: Accepted
any chance to look at the patch?
Original comment by edoardo.tosca
on 30 Nov 2011 at 10:37
This refactor looks very good, I just committed it to the trunk, revision 282
Original comment by tflo...@gmail.com
on 1 Dec 2011 at 12:36
Original comment by tflo...@gmail.com
on 1 Dec 2011 at 12:36
- Changed state: Resolved
great! Thank you!
Original comment by edoardo.tosca
on 1 Dec 2011 at 12:48