code: protected void initResourceConfig(WebConfig webConfig)
          throws ServletException
      {
          try
          {
              Field field = ServletContainer.class.getDeclaredField("resourceConfig");
              field.setAccessible(true);
              field.set(this, createResourceConfig(webConfig));
          }
          catch (ReflectiveOperationException e)
          {
              throw new ServletException("Failed to createResourceConfig.", e);
          }
          catch (BeansException e)
          {
              throw new ServletException("Failed to create bean.", e);
          }
      }
docs: Inits the resource config.
  
  @param webConfig the web config
  @throws ServletException the servlet exception