implement async hooks for factory. Closes #1
Merge pull request #2 from logicalparadox/master

implement async hooks for factory. Closes #1