Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Support `@UnitOfWork` outside of Jersey resources #1361
This PR provides the ability to use the
Now to use
SessionDao dao = new SessionDao(hibernateBundle.getSessionFactory()); ExampleAuthenticator exampleAuthenticator = new UnitOfWorkAwareProxyFactory(hibernateBundle) .create(ExampleAuthenticator.class, SessionDao.class, dao);
This PR is against the 0.9 branch, which still uses Java 7. Something like this should work, though.
git checkout -b arteam-generalize_unit_of_work release/0.9.x git pull https://github.com/arteam/dropwizard.git generalize_unit_of_work cd ./dropwizard-bom mvn install cd ../ mvn install -DskipTests=true -P dev
I tested this PR and it is working! Passed all my tests. My app at Github.