code: public static SolrItemHandler getInstance(String collection) throws Exception {
          SolrItemHandler INSTANCE = INSTANCES.get(collection);
          if (INSTANCE == null) {
              INSTANCE = new SolrItemHandler(collection);
  
              INSTANCES.put(collection, INSTANCE);
          }
          return INSTANCE;
      }
docs: implementing Singleton pattern