public static void main(String[] args) throws IOException {
// jersey must scan classpath for resources and providers
ResourceConfig rc = new ClasspathResourceConfig();
// instantiate singleton user repository for injection
final UserRepository userRepository = thaw();
Injector injector = createInjector(new AbstractModule() {
protected void configure() {
bind(UserRepository.class).toInstance(userRepository);
}
});