code: private void cleanupEndpointActivationServiceInfo(EndpointActivationServiceInfo easInfo) {
          if (easInfo.serviceRef == null && easInfo.endpointFactories.isEmpty()) {
              endpointActivationServices.remove(easInfo.id);
          }
      }
docs: Remove the EndpointActivationServiceInfo from {@link #endpointActivationServices} if
  it is no longer needed.
  
  <p>Caller must hold a lock on this object.