public void start ( BundleContext bc ) throws Exception { httpServiceRef = bc . getServiceReference ( HttpService . class ) ; if ( httpServiceRef != null ) { httpService = ( HttpService ) bc . getService ( httpServiceRef ) ; httpService . registerServlet ( "/status" , new StatusServlet ( ) , null , null ) ; httpService . registerServlet ( "/status-with-auth" , new StatusServlet ( ) , null , new AuthHttpContext ( ) ) ; } }
Called whenever the OSGi framework starts our bundle