com.sap.cds.feature.cloudfoundry.CloudFoundryEnvironmentConfiguration Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cds-feature-cloudfoundry Show documentation
Show all versions of cds-feature-cloudfoundry Show documentation
Cloud Foundry feature for CDS Services Java
/**************************************************************************
* (C) 2019-2024 SAP SE or an SAP affiliate company. All rights reserved. *
**************************************************************************/
package com.sap.cds.feature.cloudfoundry;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.sap.cds.services.runtime.CdsRuntimeConfiguration;
import com.sap.cds.services.runtime.CdsRuntimeConfigurer;
import com.sap.cds.services.utils.environment.VcapApplicationParser;
public class CloudFoundryEnvironmentConfiguration implements CdsRuntimeConfiguration {
private final static Logger logger = LoggerFactory.getLogger(CloudFoundryEnvironmentConfiguration.class);
@Override
public void environment(CdsRuntimeConfigurer configurer) {
if(System.getenv(VcapApplicationParser.VCAP_APPLICATION) != null) {
logger.info("Loaded feature 'Cloud Foundry Platform Environment'");
configurer.environment(new CloudFoundryApplicationInfoProvider());
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy