
co.verisoft.fw.config.EnvConfig Maven / Gradle / Ivy
/*
* (C) Copyright 2022 VeriSoft (http://www.verisoft.co)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* See the NOTICE file distributed with this work for additional
* information regarding copyright ownership.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package co.verisoft.fw.config;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.springframework.context.annotation.*;
import org.springframework.context.support.PropertySourcesPlaceholderConfigurer;
/**
* This is a configuratio class for all the properties files.
*
* @author Nir Gallner, VeriSoft
* @since 0.1.3 (May, 2023)
*/
@Configuration
@PropertySources({
@PropertySource("classpath:application.properties"),
@PropertySource("root.config.properties"),
})
@ComponentScan("co.verisoft")
public class EnvConfig {
@Bean
public static PropertySourcesPlaceholderConfigurer propertySourcesPlaceholderConfigurer() {
return new PropertySourcesPlaceholderConfigurer();
}
@Bean
public ObjectMapper objectMapper() {
return new ObjectMapper();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy