Repository: open-telemetry/opentelemetry-java
File: sdk-extensions/autoconfigure/src/main/java/io/opentelemetry/sdk/autoconfigure/ResourceConfiguration.java (Java)

Code before:
    }
    String serviceName = config.getString(SERVICE_NAME_PROPERTY);
    if (serviceName != null) {
      resourceAttributes.put(SERVICE_NAME, serviceName);
    }

    return Resource.create(resourceAttributes.build());
  }

  static Resource configureResource(
      ConfigProperties config,
      SpiHelper spiHelper,
      BiFunction<? super Resource, ConfigProperties, ? extends Resource> resourceCustomizer) {
    Resource result = Resource.getDefault();

    Set<String> enabledProviders = new HashSet<>(config.getList(ENABLED_RESOURCE_PROVIDERS));
    if (enabledProviders.remove(OLD_ENVIRONMENT_DETECTOR_FQCN)) {
      logger.log(
          Level.WARNING,
          "Found reference to "
              + OLD_ENVIRONMENT_DETECTOR_FQCN
              + " in "
              + ENABLED_RESOURCE_PROVIDERS
              + ". Please update to "
              + NEW_ENVIRONMENT_DETECT_FQCN
              + ". Support for the old FQCN will be removed after 1.49.0.");
      enabledProviders.add(NEW_ENVIRONMENT_DETECT_FQCN);
    }

    Set<String> disabledProviders = new HashSet<>(config.getList(DISABLED_RESOURCE_PROVIDERS));
    if (disabledProviders.remove(OLD_ENVIRONMENT_DETECTOR_FQCN)) {
      logger.log(
          Level.WARNING,
          "Found reference to "
              + OLD_ENVIRONMENT_DETECTOR_FQCN
              + " in "
              + DISABLED_RESOURCE_PROVIDERS
              + ". Please update to "
              + NEW_ENVIRONMENT_DETECT_FQCN
              + ". Support for the old FQCN will be removed after 1.49.0.");
      disabledProviders.add(NEW_ENVIRONMENT_DETECT_FQCN);
    }

    for (ResourceProvider resourceProvider : spiHelper.loadOrdered(ResourceProvider.class)) {
      if (!enabledProviders.isEmpty()
          && !enabledProviders.contains(resourceProvider.getClass().getName())) {
        continue;
      }
      if (disabledProviders.contains(resourceProvider.getClass().getName())) {
        continue;
      }

Review comment (suggestion):
```suggestion
              + ". Support for the old provider name will be removed after 1.49.0.");
```

Code after:
    }
    String serviceName = config.getString(SERVICE_NAME_PROPERTY);
    if (serviceName != null) {
      resourceAttributes.put(SERVICE_NAME, serviceName);
    }

    return Resource.create(resourceAttributes.build());
  }

  static Resource configureResource(
      ConfigProperties config,
      SpiHelper spiHelper,
      BiFunction<? super Resource, ConfigProperties, ? extends Resource> resourceCustomizer) {
    Resource result = Resource.getDefault();

    Set<String> enabledProviders = new HashSet<>(config.getList(ENABLED_RESOURCE_PROVIDERS));
    if (enabledProviders.remove(OLD_ENVIRONMENT_DETECTOR_FQCN)) {
      logger.log(
          Level.WARNING,
          "Found reference to "
              + OLD_ENVIRONMENT_DETECTOR_FQCN
              + " in "
              + ENABLED_RESOURCE_PROVIDERS
              + ". Please update to "
              + NEW_ENVIRONMENT_DETECT_FQCN
              + ". Support for the old provider name will be removed after 1.49.0.");
      enabledProviders.add(NEW_ENVIRONMENT_DETECT_FQCN);
    }

    Set<String> disabledProviders = new HashSet<>(config.getList(DISABLED_RESOURCE_PROVIDERS));
    if (disabledProviders.remove(OLD_ENVIRONMENT_DETECTOR_FQCN)) {
      logger.log(
          Level.WARNING,
          "Found reference to "
              + OLD_ENVIRONMENT_DETECTOR_FQCN
              + " in "
              + DISABLED_RESOURCE_PROVIDERS
              + ". Please update to "
              + NEW_ENVIRONMENT_DETECT_FQCN
              + ". Support for the old provider name will be removed after 1.49.0.");
      disabledProviders.add(NEW_ENVIRONMENT_DETECT_FQCN);
    }

    for (ResourceProvider resourceProvider : spiHelper.loadOrdered(ResourceProvider.class)) {
      if (!enabledProviders.isEmpty()
          && !enabledProviders.contains(resourceProvider.getClass().getName())) {
        continue;
      }
      if (disabledProviders.contains(resourceProvider.getClass().getName())) {
        continue;
      }