Skip to content

Commit

Permalink
Merge pull request psi-probe#2632 from hazendaz/deprecated
Browse files Browse the repository at this point in the history
Deprecate oracle pooling / Fixup deprecated spring property handling and drop system properties override mode
  • Loading branch information
hazendaz authored Jul 10, 2023
2 parents 302fd26 + da7a8f4 commit 16d30c8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
13 changes: 5 additions & 8 deletions psi-probe-core/src/main/java/psiprobe/ProbeConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@
import org.springframework.beans.factory.FactoryBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.config.PropertiesFactoryBean;
import org.springframework.beans.factory.config.PropertyPlaceholderConfigurer;
import org.springframework.context.MessageSource;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.support.PropertySourcesPlaceholderConfigurer;
import org.springframework.context.support.ReloadableResourceBundleMessageSource;
import org.springframework.core.io.ClassPathResource;
import org.springframework.web.servlet.HandlerMapping;
Expand Down Expand Up @@ -378,20 +378,17 @@ public LocaleChangeInterceptor getLocaleChangeInterceptor() {
*
* @return the property placeholder configurer
*/
@Bean(name = "propertyPlaceholderConfigurer")
public static PropertyPlaceholderConfigurer getPropertyPlaceholderConfigurer() {
logger.debug("Instantiated propertyPlaceholderConfigurer");
PropertyPlaceholderConfigurer configurer = new PropertyPlaceholderConfigurer();
@Bean(name = "propertySourcesPlaceholderConfigurer")
public static PropertySourcesPlaceholderConfigurer getPropertySourcesPlaceholderConfigurer() {
logger.debug("Instantiated propertySourcesPlaceholderConfigurer");
PropertySourcesPlaceholderConfigurer configurer = new PropertySourcesPlaceholderConfigurer();
configurer.setLocation(new ClassPathResource("stats.properties"));
configurer.setNullValue("NULL");

Properties properties = new Properties();
properties.put("psiprobe.tools.mail.to", "NULL");
properties.put("psiprobe.tools.mail.subjectPrefix", "[PSI Probe]");
configurer.setProperties(properties);

configurer.setSystemPropertiesModeName("SYSTEM_PROPERTIES_MODE_OVERRIDE");

return configurer;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,11 @@
* tedious job of verifying whether the datasource has a record in the cache manager or not. The
* pool information is subsequently retrieved from the relevant cache manager entry.
* </p>
*
* @deprecated As of 21c, this is deleted by oracle, therefore please transition to ucp which we
* support now.
*/
@Deprecated
public class OracleDatasourceAccessor implements DatasourceAccessor {

@Override
Expand Down

0 comments on commit 16d30c8

Please sign in to comment.