docs: @Override
    public Resource fetchResourceById(String type, String uri) {
      synchronized (lock) {
        String[] parts = uri.split("\\/");
        if (!Utilities.noString(type) && parts.length == 1)
          return allResourcesById.get(type).get(parts[0]);
        if (parts.length >= 2) {
          if (!Utilities.noString(type))
            if (!type.equals(parts[parts.length-2])) 
              throw new Error("Resource type mismatch for "+type+" / "+uri);
          return allResourcesById.get(parts[parts.length-2]).get(parts[parts.length-1]);
        } else
          throw new Error("Unable to process request for resource for "+type+" / "+uri);
      }
    }