init method in jersey jax-rs web service
问题 I'm new with jax-rs and have build a web service with jersey and glassfish. What I need is a method, which is called once the service is started. In this method I want to load a custom config file, set some properties, write a log, and so on ... I tried to use the constructor of the servlet but the constructor is called every time a GET or POST method is called. what options I have to realize that? Please tell, if some dependencies are needed, give me an idea how to add it to the pom.xml (or