code: public <T extends RegisteredService> List<T> getDynamicServices(Class<T> serviceInterface) {
          List<T> dynServices = new ArrayList<>();
          if (dynamicServices.containsKey(serviceInterface.getName())) {
              Set<String> deregister = new HashSet<>();
              for (String serviceClassName : dynamicServices.get(serviceInterface.getName())) {
                  try {
                      Class<?> clazz = CompiledJavaCache.getClassFromAssetName(null, serviceClassName);
                      if (clazz != null)  {
                          RegisteredService rs = (RegisteredService)(clazz).newInstance();
                          dynServices.add(serviceInterface.cast(rs));
                      }
                  } catch (Exception ex) {
                      logger.severeException("Failed to get Dynamic Java service : " + serviceClassName + " (removing from registry)", ex);
                      deregister.add(serviceClassName);
                  }
              }
              // avoid repeated attempts to recompile until cache is refreshed
              dynamicServices.get(serviceInterface.getName()).removeAll(deregister);
          }
          return dynServices;
      }
docs: To get List of dynamic java registered services based on service interface
  Example: To get list of registered process Monitors
  @param serviceInterface
  @return