Skip to content

Commit

Permalink
perf($Common): remove useless dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
johnnymillergh committed Dec 14, 2020
1 parent e8a86b1 commit 1df12c5
Show file tree
Hide file tree
Showing 19 changed files with 38 additions and 416 deletions.
14 changes: 3 additions & 11 deletions api-portal/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,6 @@
<!-- Scoped Dependencies Management -->
<dependencies>
<!-- Spring Frameworks -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
Expand All @@ -106,10 +102,6 @@
<artifactId>spring-integration-sftp</artifactId>
</dependency>

<dependency>
<groupId>com.jmsoftware.maf</groupId>
<artifactId>common</artifactId>
</dependency>
<dependency>
<groupId>com.jmsoftware.maf</groupId>
<artifactId>muscle-and-fitness-server-spring-boot-starter</artifactId>
Expand Down Expand Up @@ -147,18 +139,18 @@
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-api</artifactId>
<version>0.11.1</version>
<version>${jjwt.version}</version>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-impl</artifactId>
<version>0.11.1</version>
<version>${jjwt.version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-jackson</artifactId> <!-- or jjwt-gson if Gson is preferred -->
<version>0.11.1</version>
<version>${jjwt.version}</version>
<scope>runtime</scope>
</dependency>
</dependencies>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ public static void main(String[] args) {
log.info("⚙️ Environment: {}", projectProperty.getEnvironment());
log.info("⏳ Deployment duration: {} seconds ({} ms)", duration.getSeconds(), duration.toMillis());
log.info("⏰ App started at {} (timezone - {})", endInstant, TimeZone.getDefault().getDisplayName());
log.info("{} App running at{} - Local: http://localhost:{}{}/{} - Network: {}/{}",
log.info("{} App running at{} - Local: http://localhost:{}{}/{} - Network: http://{}/{}",
LINE_SEPARATOR, LINE_SEPARATOR, ipHelper.getServerPort(), projectProperty.getContextPath(),
LINE_SEPARATOR, ipHelper.getPublicIp(),projectProperty.getContextPath());
LINE_SEPARATOR, ipHelper.getPublicIp(), projectProperty.getContextPath());
}
}
10 changes: 3 additions & 7 deletions auth-center/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,6 @@
<artifactId>spring-integration-sftp</artifactId>
</dependency>

<dependency>
<groupId>com.jmsoftware.maf</groupId>
<artifactId>common</artifactId>
</dependency>
<dependency>
<groupId>com.jmsoftware.maf</groupId>
<artifactId>muscle-and-fitness-server-spring-boot-starter</artifactId>
Expand Down Expand Up @@ -139,18 +135,18 @@
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-api</artifactId>
<version>0.11.1</version>
<version>${jjwt.version}</version>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-impl</artifactId>
<version>0.11.1</version>
<version>${jjwt.version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-jackson</artifactId> <!-- or jjwt-gson if Gson is preferred -->
<version>0.11.1</version>
<version>${jjwt.version}</version>
<scope>runtime</scope>
</dependency>
</dependencies>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.jmsoftware.maf.authcenter;

import com.jmsoftware.maf.authcenter.universal.configuration.ProjectProperty;
import com.jmsoftware.maf.authcenter.universal.configuration.ServerConfiguration;
import com.jmsoftware.maf.muscleandfitnessserverspringbootstarter.helper.IpHelper;
import lombok.extern.slf4j.Slf4j;
import lombok.val;
import org.springframework.boot.SpringApplication;
Expand All @@ -28,11 +28,11 @@
public class AuthCenterApplication {
private static final String LINE_SEPARATOR = System.lineSeparator();
private static ProjectProperty projectProperty;
private static ServerConfiguration serverConfiguration;
private static IpHelper ipHelper;

public AuthCenterApplication(ProjectProperty projectProperty, ServerConfiguration serverConfiguration) {
public AuthCenterApplication(ProjectProperty projectProperty, IpHelper ipHelper) {
AuthCenterApplication.projectProperty = projectProperty;
AuthCenterApplication.serverConfiguration = serverConfiguration;
AuthCenterApplication.ipHelper = ipHelper;
}

public static void main(String[] args) {
Expand All @@ -45,8 +45,8 @@ public static void main(String[] args) {
log.info("⚙️ Environment: {}", projectProperty.getEnvironment());
log.info("⏳ Deployment duration: {} seconds ({} ms)", duration.getSeconds(), duration.toMillis());
log.info("⏰ App started at {} (timezone - {})", endInstant, TimeZone.getDefault().getDisplayName());
log.info("{} App running at{} - Local: http://localhost:{}{}/{} - Network: {}/",
LINE_SEPARATOR, LINE_SEPARATOR, serverConfiguration.getServerPort(), projectProperty.getContextPath(),
LINE_SEPARATOR, serverConfiguration.getBaseUrl());
log.info("{} App running at{} - Local: http://localhost:{}{}/{} - Network: http://{}/{}",
LINE_SEPARATOR, LINE_SEPARATOR, ipHelper.getServerPort(), projectProperty.getContextPath(),
LINE_SEPARATOR, ipHelper.getPublicIp(), projectProperty.getContextPath());
}
}

This file was deleted.

3 changes: 2 additions & 1 deletion common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@

<!-- Scoped Dependencies Management -->
<dependencies>
<!-- spring-boot-starter-web shouldn't be here, in `common`
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
</dependency>-->
</dependencies>
</project>
4 changes: 0 additions & 4 deletions exercise-mis/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -96,10 +96,6 @@
<artifactId>spring-integration-sftp</artifactId>
</dependency>

<dependency>
<groupId>com.jmsoftware.maf</groupId>
<artifactId>common</artifactId>
</dependency>
<dependency>
<groupId>com.jmsoftware.maf</groupId>
<artifactId>muscle-and-fitness-server-spring-boot-starter</artifactId>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.jmsoftware.maf.exercisemis;

import com.jmsoftware.maf.exercisemis.universal.configuration.ProjectProperty;
import com.jmsoftware.maf.exercisemis.universal.configuration.ServerConfiguration;
import com.jmsoftware.maf.muscleandfitnessserverspringbootstarter.helper.IpHelper;
import lombok.extern.slf4j.Slf4j;
import lombok.val;
import org.springframework.boot.SpringApplication;
Expand All @@ -28,11 +28,11 @@
public class ExerciseMisApplication {
private static final String LINE_SEPARATOR = System.lineSeparator();
private static ProjectProperty projectProperty;
private static ServerConfiguration serverConfiguration;
private static IpHelper ipHelper;

public ExerciseMisApplication(ProjectProperty projectProperty, ServerConfiguration serverConfiguration) {
public ExerciseMisApplication(ProjectProperty projectProperty, IpHelper ipHelper) {
ExerciseMisApplication.projectProperty = projectProperty;
ExerciseMisApplication.serverConfiguration = serverConfiguration;
ExerciseMisApplication.ipHelper = ipHelper;
}

public static void main(String[] args) {
Expand All @@ -45,8 +45,8 @@ public static void main(String[] args) {
log.info("⚙️ Environment: {}", projectProperty.getEnvironment());
log.info("⏳ Deployment duration: {} seconds ({} ms)", duration.getSeconds(), duration.toMillis());
log.info("⏰ App started at {} (timezone - {})", endInstant, TimeZone.getDefault().getDisplayName());
log.info("{} App running at{} - Local: http://localhost:{}{}/{} - Network: {}/",
LINE_SEPARATOR, LINE_SEPARATOR, serverConfiguration.getServerPort(), projectProperty.getContextPath(),
LINE_SEPARATOR, serverConfiguration.getBaseUrl());
log.info("{} App running at{} - Local: http://localhost:{}{}/{} - Network: http://{}/{}",
LINE_SEPARATOR, LINE_SEPARATOR, ipHelper.getServerPort(), projectProperty.getContextPath(),
LINE_SEPARATOR, ipHelper.getPublicIp(), projectProperty.getContextPath());
}
}
Loading

0 comments on commit 1df12c5

Please sign in to comment.