Skip to content

Commit

Permalink
Merge pull request #1508 from LoganathanSekar7627/MOSIP-31617-java-21…
Browse files Browse the repository at this point in the history
…-migration

Mosip 31617 java 21 migration
  • Loading branch information
vishwa-vyom authored May 6, 2024
2 parents 19cf4a8 + 61a7f5d commit 760557e
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 7 deletions.
2 changes: 1 addition & 1 deletion kernel/kernel-idgenerator-service/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@
</executions>
<configuration>
<generateGitPropertiesFile>true</generateGitPropertiesFile>
<generateGitPropertiesFilename>${project.build.outputDirectory}/git.properties</generateGitPropertiesFilename>
<generateGitPropertiesFilename>${project.build.outputDirectory}/service-git.properties</generateGitPropertiesFilename>
<includeOnlyProperties>
<includeOnlyProperty>^git.build.(time|version)$</includeOnlyProperty>
<includeOnlyProperty>^git.commit.id.(abbrev|full)$</includeOnlyProperty>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import java.util.HashMap;
import java.util.Map;

import jakarta.persistence.EntityManagerFactory;
import javax.sql.DataSource;

import org.slf4j.Logger;
Expand All @@ -12,10 +11,13 @@
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.context.EnvironmentAware;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.ComponentScan.Filter;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.FilterType;
import org.springframework.context.annotation.PropertySource;
import org.springframework.core.env.Environment;
import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
Expand All @@ -29,6 +31,7 @@
import com.zaxxer.hikari.HikariDataSource;

import io.mosip.kernel.vidgenerator.constant.HibernatePersistenceConstant;
import jakarta.persistence.EntityManagerFactory;

/**
* Configuration class for IDGenerator
Expand All @@ -43,8 +46,10 @@
@PropertySource({ "classpath:bootstrap.properties" })
@PropertySource(value = "classpath:application-${spring.profiles.active}.properties", ignoreResourceNotFound = true)
@EnableJpaRepositories(basePackages = { "io.mosip.kernel.vidgenerator.repository", "io.mosip.kernel.uingenerator.repository"})
@EnableAutoConfiguration
@ComponentScan(basePackages = { "io.mosip.kernel.vidgenerator.*","io.mosip.kernel.uingenerator.*", "io.mosip.kernel.idgenerator.vid.*",
"io.mosip.kernel.crypto.*", "${mosip.auth.adapter.impl.basepackage}","io.mosip.kernel.cryptosignature.*","io.mosip.kernel.idgenerator.*","io.mosip.kernel.keygenerator.bouncycastle"})
"io.mosip.kernel.crypto.*", "${mosip.auth.adapter.impl.basepackage}.*","io.mosip.kernel.cryptosignature.*","io.mosip.kernel.idgenerator.*","io.mosip.kernel.keygenerator.bouncycastle"},
excludeFilters = @Filter(type=FilterType.REGEX,pattern="io\\.mosip\\.kernel\\.idgenerator\\.test\\..*"))
@EnableTransactionManagement
public class HibernateDaoConfig implements EnvironmentAware {

Expand Down
2 changes: 1 addition & 1 deletion kernel/kernel-notification-service/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@
</executions>
<configuration>
<generateGitPropertiesFile>true</generateGitPropertiesFile>
<generateGitPropertiesFilename>${project.build.outputDirectory}/git.properties</generateGitPropertiesFilename>
<generateGitPropertiesFilename>${project.build.outputDirectory}/service-git.properties</generateGitPropertiesFilename>
<includeOnlyProperties>
<includeOnlyProperty>^git.build.(time|version)$</includeOnlyProperty>
<includeOnlyProperty>^git.commit.id.(abbrev|full)$</includeOnlyProperty>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
* @since 1.0.0
*/
@RestControllerAdvice
public class ApiExceptionHandler {
public class EmailNotificationApiExceptionHandler {

/**
* Autowired reference for {@link ObjectMapper}.
Expand Down
2 changes: 1 addition & 1 deletion kernel/kernel-pridgenerator-service/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@
</executions>
<configuration>
<generateGitPropertiesFile>true</generateGitPropertiesFile>
<generateGitPropertiesFilename>${project.build.outputDirectory}/git.properties</generateGitPropertiesFilename>
<generateGitPropertiesFilename>${project.build.outputDirectory}/service-git.properties</generateGitPropertiesFilename>
<includeOnlyProperties>
<includeOnlyProperty>^git.build.(time|version)$</includeOnlyProperty>
<includeOnlyProperty>^git.commit.id.(abbrev|full)$</includeOnlyProperty>
Expand Down
2 changes: 1 addition & 1 deletion kernel/kernel-ridgenerator-service/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@
</executions>
<configuration>
<generateGitPropertiesFile>true</generateGitPropertiesFile>
<generateGitPropertiesFilename>${project.build.outputDirectory}/git.properties</generateGitPropertiesFilename>
<generateGitPropertiesFilename>${project.build.outputDirectory}/service-git.properties</generateGitPropertiesFilename>
<includeOnlyProperties>
<includeOnlyProperty>^git.build.(time|version)$</includeOnlyProperty>
<includeOnlyProperty>^git.commit.id.(abbrev|full)$</includeOnlyProperty>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Import;

import io.mosip.kernel.dataaccess.hibernate.config.HibernateDaoConfig;

/**
* Main class for RID generator.
Expand All @@ -11,6 +14,7 @@
*/
@SpringBootApplication(scanBasePackages = { "io.mosip.kernel.ridgenerator.*", "${mosip.auth.adapter.impl.basepackage}",
"io.mosip.kernel.core.logger.config"})
@Import(value = {HibernateDaoConfig.class})
public class RidGeneratorBootApplication {

/**
Expand Down

0 comments on commit 760557e

Please sign in to comment.