<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Alexpandiyan Chokkan</title>
    <description>The latest articles on DEV Community by Alexpandiyan Chokkan (@pandiyan90).</description>
    <link>https://dev.to/pandiyan90</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F193478%2F57f0a05c-0242-47a1-b0bf-ae7e25fb9c26.jpg</url>
      <title>DEV Community: Alexpandiyan Chokkan</title>
      <link>https://dev.to/pandiyan90</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/pandiyan90"/>
    <language>en</language>
    <item>
      <title>Part-1: Spring &amp; Gradle - Multi Module Project</title>
      <dc:creator>Alexpandiyan Chokkan</dc:creator>
      <pubDate>Fri, 16 Aug 2019 00:23:13 +0000</pubDate>
      <link>https://dev.to/pandiyan90/part-1-spring-gradle-multi-module-project-1j8a</link>
      <guid>https://dev.to/pandiyan90/part-1-spring-gradle-multi-module-project-1j8a</guid>
      <description>&lt;p&gt;Overview:&lt;/p&gt;

&lt;p&gt;In this article, we’ll implement a spring boot multi module application. We’ll use gradle build system. The goal is here to create a microservices application which will be covered in the upcoming articles.&lt;/p&gt;

&lt;p&gt;Layout:&lt;/p&gt;

&lt;p&gt;Here we are going to use flat layout to keep the application directories as siblings of the root project directory (Pic-1). The advantage of flat layout is we can have the distinct git repository for every application. In your root project’s settings.gradle file, we need to use the includeFlat with the subproject.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F0bw7f9rk9tox61s848cd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F0bw7f9rk9tox61s848cd.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;br&gt;
Pic-1. Directory Structure&lt;/p&gt;

&lt;p&gt;Project: root&lt;/p&gt;

&lt;p&gt;This project having only the project configuration files such as build.gradle and settings.gradle.&lt;/p&gt;

&lt;p&gt;settings.gradle:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;rootProject.name = 'root'

includeFlat 'utilities', 'exception-handler’, 'discovery-server'
includeFlat 'enquiry', 'api-gateway', 'registration'
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;build.gradle:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;buildscript {

 ext {
  springBootVersion = '2.1.6.RELEASE' 
 }

repositories {
 mavenCentral()
}

dependencies {
 classpath("org.springframework.boot:spring-boot-gradle- plugin:${springBootVersion}")
 }
}

subprojects {

 apply plugin: 'java'
 apply plugin: 'org.springframework.boot'
 apply plugin: 'io.spring.dependency-management'

 group = 'com.apandiyan'
 version = '0.0.1'
 sourceCompatibility = '1.8'
 repositories {
  mavenCentral()
 }

 ext {
  set('springCloudVersion', "Greenwich.SR1")
 }

 dependencies {
  implementation 'org.springframework.boot:spring-boot-starter-web'
  testImplementation 'org.springframework.boot:spring-boot-starter-test'
 }

 dependencyManagement {
  imports {
   mavenBom "org.springframework.cloud:spring-cloud- dependencies:${springCloudVersion}"
  }
 }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Source: &lt;a href="https://github.com/pandiyan90/microservice-blog/tree/master/root" rel="noopener noreferrer"&gt;https://github.com/pandiyan90/microservice-blog/tree/master/root&lt;/a&gt;&lt;/p&gt;

</description>
      <category>java</category>
      <category>spring</category>
    </item>
  </channel>
</rss>
