commit b9639dcefd21026c2c3661d50d5109e5bcba970e Author: sampath kumar Date: Tue Oct 1 11:17:34 2024 +0530 initial commit diff --git a/.classpath b/.classpath new file mode 100644 index 0000000..83a3b6f --- /dev/null +++ b/.classpath @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..26d3352 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,3 @@ +# Default ignored files +/shelf/ +/workspace.xml diff --git a/.idea/compiler.xml b/.idea/compiler.xml new file mode 100644 index 0000000..172657b --- /dev/null +++ b/.idea/compiler.xml @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/encodings.xml b/.idea/encodings.xml new file mode 100644 index 0000000..63e9001 --- /dev/null +++ b/.idea/encodings.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml new file mode 100644 index 0000000..712ab9d --- /dev/null +++ b/.idea/jarRepositories.xml @@ -0,0 +1,20 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..5686ceb --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,13 @@ + + + + + + + + \ No newline at end of file diff --git a/.project b/.project new file mode 100644 index 0000000..c75352b --- /dev/null +++ b/.project @@ -0,0 +1,29 @@ + + + kafka + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.babel.editor.rbeBuilder + + + + + org.eclipse.m2e.core.maven2Builder + + + + + + org.eclipse.jdt.core.javanature + org.eclipse.m2e.core.maven2Nature + com.jaspersoft.studio.babel.editor.rbeNature + + diff --git a/HELP.md b/HELP.md new file mode 100644 index 0000000..6035ef0 --- /dev/null +++ b/HELP.md @@ -0,0 +1,18 @@ +# Getting Started + +### Reference Documentation +For further reference, please consider the following sections: + +* [Official Apache Maven documentation](https://maven.apache.org/guides/index.html) +* [Spring Boot Maven Plugin Reference Guide](https://docs.spring.io/spring-boot/docs/3.3.0/maven-plugin/reference/html/) +* [Create an OCI image](https://docs.spring.io/spring-boot/docs/3.3.0/maven-plugin/reference/html/#build-image) +* [Spring for Apache Kafka](https://docs.spring.io/spring-boot/docs/3.3.0/reference/htmlsingle/index.html#messaging.kafka) +* [Spring Web](https://docs.spring.io/spring-boot/docs/3.3.0/reference/htmlsingle/index.html#web) + +### Guides +The following guides illustrate how to use some features concretely: + +* [Building a RESTful Web Service](https://spring.io/guides/gs/rest-service/) +* [Serving Web Content with Spring MVC](https://spring.io/guides/gs/serving-web-content/) +* [Building REST services with Spring](https://spring.io/guides/tutorials/rest/) + diff --git a/mvnw b/mvnw new file mode 100644 index 0000000..ba9212a --- /dev/null +++ b/mvnw @@ -0,0 +1,250 @@ +#!/bin/sh +# ---------------------------------------------------------------------------- +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# https://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. +# ---------------------------------------------------------------------------- + +# ---------------------------------------------------------------------------- +# Apache Maven Wrapper startup batch script, version 3.3.1 +# +# Optional ENV vars +# ----------------- +# JAVA_HOME - location of a JDK home dir, required when download maven via java source +# MVNW_REPOURL - repo url base for downloading maven distribution +# MVNW_USERNAME/MVNW_PASSWORD - user and password for downloading maven +# MVNW_VERBOSE - true: enable verbose log; debug: trace the mvnw script; others: silence the output +# ---------------------------------------------------------------------------- + +set -euf +[ "${MVNW_VERBOSE-}" != debug ] || set -x + +# OS specific support. +native_path() { printf %s\\n "$1"; } +case "$(uname)" in +CYGWIN* | MINGW*) + [ -z "${JAVA_HOME-}" ] || JAVA_HOME="$(cygpath --unix "$JAVA_HOME")" + native_path() { cygpath --path --windows "$1"; } + ;; +esac + +# set JAVACMD and JAVACCMD +set_java_home() { + # For Cygwin and MinGW, ensure paths are in Unix format before anything is touched + if [ -n "${JAVA_HOME-}" ]; then + if [ -x "$JAVA_HOME/jre/sh/java" ]; then + # IBM's JDK on AIX uses strange locations for the executables + JAVACMD="$JAVA_HOME/jre/sh/java" + JAVACCMD="$JAVA_HOME/jre/sh/javac" + else + JAVACMD="$JAVA_HOME/bin/java" + JAVACCMD="$JAVA_HOME/bin/javac" + + if [ ! -x "$JAVACMD" ] || [ ! -x "$JAVACCMD" ]; then + echo "The JAVA_HOME environment variable is not defined correctly, so mvnw cannot run." >&2 + echo "JAVA_HOME is set to \"$JAVA_HOME\", but \"\$JAVA_HOME/bin/java\" or \"\$JAVA_HOME/bin/javac\" does not exist." >&2 + return 1 + fi + fi + else + JAVACMD="$( + 'set' +e + 'unset' -f command 2>/dev/null + 'command' -v java + )" || : + JAVACCMD="$( + 'set' +e + 'unset' -f command 2>/dev/null + 'command' -v javac + )" || : + + if [ ! -x "${JAVACMD-}" ] || [ ! -x "${JAVACCMD-}" ]; then + echo "The java/javac command does not exist in PATH nor is JAVA_HOME set, so mvnw cannot run." >&2 + return 1 + fi + fi +} + +# hash string like Java String::hashCode +hash_string() { + str="${1:-}" h=0 + while [ -n "$str" ]; do + char="${str%"${str#?}"}" + h=$(((h * 31 + $(LC_CTYPE=C printf %d "'$char")) % 4294967296)) + str="${str#?}" + done + printf %x\\n $h +} + +verbose() { :; } +[ "${MVNW_VERBOSE-}" != true ] || verbose() { printf %s\\n "${1-}"; } + +die() { + printf %s\\n "$1" >&2 + exit 1 +} + +# parse distributionUrl and optional distributionSha256Sum, requires .mvn/wrapper/maven-wrapper.properties +while IFS="=" read -r key value; do + case "${key-}" in + distributionUrl) distributionUrl="${value-}" ;; + distributionSha256Sum) distributionSha256Sum="${value-}" ;; + esac +done <"${0%/*}/.mvn/wrapper/maven-wrapper.properties" +[ -n "${distributionUrl-}" ] || die "cannot read distributionUrl property in ${0%/*}/.mvn/wrapper/maven-wrapper.properties" + +case "${distributionUrl##*/}" in +maven-mvnd-*bin.*) + MVN_CMD=mvnd.sh _MVNW_REPO_PATTERN=/maven/mvnd/ + case "${PROCESSOR_ARCHITECTURE-}${PROCESSOR_ARCHITEW6432-}:$(uname -a)" in + *AMD64:CYGWIN* | *AMD64:MINGW*) distributionPlatform=windows-amd64 ;; + :Darwin*x86_64) distributionPlatform=darwin-amd64 ;; + :Darwin*arm64) distributionPlatform=darwin-aarch64 ;; + :Linux*x86_64*) distributionPlatform=linux-amd64 ;; + *) + echo "Cannot detect native platform for mvnd on $(uname)-$(uname -m), use pure java version" >&2 + distributionPlatform=linux-amd64 + ;; + esac + distributionUrl="${distributionUrl%-bin.*}-$distributionPlatform.zip" + ;; +maven-mvnd-*) MVN_CMD=mvnd.sh _MVNW_REPO_PATTERN=/maven/mvnd/ ;; +*) MVN_CMD="mvn${0##*/mvnw}" _MVNW_REPO_PATTERN=/org/apache/maven/ ;; +esac + +# apply MVNW_REPOURL and calculate MAVEN_HOME +# maven home pattern: ~/.m2/wrapper/dists/{apache-maven-,maven-mvnd--}/ +[ -z "${MVNW_REPOURL-}" ] || distributionUrl="$MVNW_REPOURL$_MVNW_REPO_PATTERN${distributionUrl#*"$_MVNW_REPO_PATTERN"}" +distributionUrlName="${distributionUrl##*/}" +distributionUrlNameMain="${distributionUrlName%.*}" +distributionUrlNameMain="${distributionUrlNameMain%-bin}" +MAVEN_HOME="$HOME/.m2/wrapper/dists/${distributionUrlNameMain-}/$(hash_string "$distributionUrl")" + +exec_maven() { + unset MVNW_VERBOSE MVNW_USERNAME MVNW_PASSWORD MVNW_REPOURL || : + exec "$MAVEN_HOME/bin/$MVN_CMD" "$@" || die "cannot exec $MAVEN_HOME/bin/$MVN_CMD" +} + +if [ -d "$MAVEN_HOME" ]; then + verbose "found existing MAVEN_HOME at $MAVEN_HOME" + exec_maven "$@" +fi + +case "${distributionUrl-}" in +*?-bin.zip | *?maven-mvnd-?*-?*.zip) ;; +*) die "distributionUrl is not valid, must match *-bin.zip or maven-mvnd-*.zip, but found '${distributionUrl-}'" ;; +esac + +# prepare tmp dir +if TMP_DOWNLOAD_DIR="$(mktemp -d)" && [ -d "$TMP_DOWNLOAD_DIR" ]; then + clean() { rm -rf -- "$TMP_DOWNLOAD_DIR"; } + trap clean HUP INT TERM EXIT +else + die "cannot create temp dir" +fi + +mkdir -p -- "${MAVEN_HOME%/*}" + +# Download and Install Apache Maven +verbose "Couldn't find MAVEN_HOME, downloading and installing it ..." +verbose "Downloading from: $distributionUrl" +verbose "Downloading to: $TMP_DOWNLOAD_DIR/$distributionUrlName" + +# select .zip or .tar.gz +if ! command -v unzip >/dev/null; then + distributionUrl="${distributionUrl%.zip}.tar.gz" + distributionUrlName="${distributionUrl##*/}" +fi + +# verbose opt +__MVNW_QUIET_WGET=--quiet __MVNW_QUIET_CURL=--silent __MVNW_QUIET_UNZIP=-q __MVNW_QUIET_TAR='' +[ "${MVNW_VERBOSE-}" != true ] || __MVNW_QUIET_WGET='' __MVNW_QUIET_CURL='' __MVNW_QUIET_UNZIP='' __MVNW_QUIET_TAR=v + +# normalize http auth +case "${MVNW_PASSWORD:+has-password}" in +'') MVNW_USERNAME='' MVNW_PASSWORD='' ;; +has-password) [ -n "${MVNW_USERNAME-}" ] || MVNW_USERNAME='' MVNW_PASSWORD='' ;; +esac + +if [ -z "${MVNW_USERNAME-}" ] && command -v wget >/dev/null; then + verbose "Found wget ... using wget" + wget ${__MVNW_QUIET_WGET:+"$__MVNW_QUIET_WGET"} "$distributionUrl" -O "$TMP_DOWNLOAD_DIR/$distributionUrlName" || die "wget: Failed to fetch $distributionUrl" +elif [ -z "${MVNW_USERNAME-}" ] && command -v curl >/dev/null; then + verbose "Found curl ... using curl" + curl ${__MVNW_QUIET_CURL:+"$__MVNW_QUIET_CURL"} -f -L -o "$TMP_DOWNLOAD_DIR/$distributionUrlName" "$distributionUrl" || die "curl: Failed to fetch $distributionUrl" +elif set_java_home; then + verbose "Falling back to use Java to download" + javaSource="$TMP_DOWNLOAD_DIR/Downloader.java" + targetZip="$TMP_DOWNLOAD_DIR/$distributionUrlName" + cat >"$javaSource" <<-END + public class Downloader extends java.net.Authenticator + { + protected java.net.PasswordAuthentication getPasswordAuthentication() + { + return new java.net.PasswordAuthentication( System.getenv( "MVNW_USERNAME" ), System.getenv( "MVNW_PASSWORD" ).toCharArray() ); + } + public static void main( String[] args ) throws Exception + { + setDefault( new Downloader() ); + java.nio.file.Files.copy( java.net.URI.create( args[0] ).toURL().openStream(), java.nio.file.Paths.get( args[1] ).toAbsolutePath().normalize() ); + } + } + END + # For Cygwin/MinGW, switch paths to Windows format before running javac and java + verbose " - Compiling Downloader.java ..." + "$(native_path "$JAVACCMD")" "$(native_path "$javaSource")" || die "Failed to compile Downloader.java" + verbose " - Running Downloader.java ..." + "$(native_path "$JAVACMD")" -cp "$(native_path "$TMP_DOWNLOAD_DIR")" Downloader "$distributionUrl" "$(native_path "$targetZip")" +fi + +# If specified, validate the SHA-256 sum of the Maven distribution zip file +if [ -n "${distributionSha256Sum-}" ]; then + distributionSha256Result=false + if [ "$MVN_CMD" = mvnd.sh ]; then + echo "Checksum validation is not supported for maven-mvnd." >&2 + echo "Please disable validation by removing 'distributionSha256Sum' from your maven-wrapper.properties." >&2 + exit 1 + elif command -v sha256sum >/dev/null; then + if echo "$distributionSha256Sum $TMP_DOWNLOAD_DIR/$distributionUrlName" | sha256sum -c >/dev/null 2>&1; then + distributionSha256Result=true + fi + elif command -v shasum >/dev/null; then + if echo "$distributionSha256Sum $TMP_DOWNLOAD_DIR/$distributionUrlName" | shasum -a 256 -c >/dev/null 2>&1; then + distributionSha256Result=true + fi + else + echo "Checksum validation was requested but neither 'sha256sum' or 'shasum' are available." >&2 + echo "Please install either command, or disable validation by removing 'distributionSha256Sum' from your maven-wrapper.properties." >&2 + exit 1 + fi + if [ $distributionSha256Result = false ]; then + echo "Error: Failed to validate Maven distribution SHA-256, your Maven distribution might be compromised." >&2 + echo "If you updated your Maven version, you need to update the specified distributionSha256Sum property." >&2 + exit 1 + fi +fi + +# unzip and move +if command -v unzip >/dev/null; then + unzip ${__MVNW_QUIET_UNZIP:+"$__MVNW_QUIET_UNZIP"} "$TMP_DOWNLOAD_DIR/$distributionUrlName" -d "$TMP_DOWNLOAD_DIR" || die "failed to unzip" +else + tar xzf${__MVNW_QUIET_TAR:+"$__MVNW_QUIET_TAR"} "$TMP_DOWNLOAD_DIR/$distributionUrlName" -C "$TMP_DOWNLOAD_DIR" || die "failed to untar" +fi +printf %s\\n "$distributionUrl" >"$TMP_DOWNLOAD_DIR/$distributionUrlNameMain/mvnw.url" +mv -- "$TMP_DOWNLOAD_DIR/$distributionUrlNameMain" "$MAVEN_HOME" || [ -d "$MAVEN_HOME" ] || die "fail to move MAVEN_HOME" + +clean || : +exec_maven "$@" diff --git a/mvnw.cmd b/mvnw.cmd new file mode 100644 index 0000000..406932d --- /dev/null +++ b/mvnw.cmd @@ -0,0 +1,146 @@ +<# : batch portion +@REM ---------------------------------------------------------------------------- +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM https://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. +@REM ---------------------------------------------------------------------------- + +@REM ---------------------------------------------------------------------------- +@REM Apache Maven Wrapper startup batch script, version 3.3.1 +@REM +@REM Optional ENV vars +@REM MVNW_REPOURL - repo url base for downloading maven distribution +@REM MVNW_USERNAME/MVNW_PASSWORD - user and password for downloading maven +@REM MVNW_VERBOSE - true: enable verbose log; others: silence the output +@REM ---------------------------------------------------------------------------- + +@IF "%__MVNW_ARG0_NAME__%"=="" (SET __MVNW_ARG0_NAME__=%~nx0) +@SET __MVNW_CMD__= +@SET __MVNW_ERROR__= +@SET __MVNW_PSMODULEP_SAVE=%PSModulePath% +@SET PSModulePath= +@FOR /F "usebackq tokens=1* delims==" %%A IN (`powershell -noprofile "& {$scriptDir='%~dp0'; $script='%__MVNW_ARG0_NAME__%'; icm -ScriptBlock ([Scriptblock]::Create((Get-Content -Raw '%~f0'))) -NoNewScope}"`) DO @( + IF "%%A"=="MVN_CMD" (set __MVNW_CMD__=%%B) ELSE IF "%%B"=="" (echo %%A) ELSE (echo %%A=%%B) +) +@SET PSModulePath=%__MVNW_PSMODULEP_SAVE% +@SET __MVNW_PSMODULEP_SAVE= +@SET __MVNW_ARG0_NAME__= +@SET MVNW_USERNAME= +@SET MVNW_PASSWORD= +@IF NOT "%__MVNW_CMD__%"=="" (%__MVNW_CMD__% %*) +@echo Cannot start maven from wrapper >&2 && exit /b 1 +@GOTO :EOF +: end batch / begin powershell #> + +$ErrorActionPreference = "Stop" +if ($env:MVNW_VERBOSE -eq "true") { + $VerbosePreference = "Continue" +} + +# calculate distributionUrl, requires .mvn/wrapper/maven-wrapper.properties +$distributionUrl = (Get-Content -Raw "$scriptDir/.mvn/wrapper/maven-wrapper.properties" | ConvertFrom-StringData).distributionUrl +if (!$distributionUrl) { + Write-Error "cannot read distributionUrl property in $scriptDir/.mvn/wrapper/maven-wrapper.properties" +} + +switch -wildcard -casesensitive ( $($distributionUrl -replace '^.*/','') ) { + "maven-mvnd-*" { + $USE_MVND = $true + $distributionUrl = $distributionUrl -replace '-bin\.[^.]*$',"-windows-amd64.zip" + $MVN_CMD = "mvnd.cmd" + break + } + default { + $USE_MVND = $false + $MVN_CMD = $script -replace '^mvnw','mvn' + break + } +} + +# apply MVNW_REPOURL and calculate MAVEN_HOME +# maven home pattern: ~/.m2/wrapper/dists/{apache-maven-,maven-mvnd--}/ +if ($env:MVNW_REPOURL) { + $MVNW_REPO_PATTERN = if ($USE_MVND) { "/org/apache/maven/" } else { "/maven/mvnd/" } + $distributionUrl = "$env:MVNW_REPOURL$MVNW_REPO_PATTERN$($distributionUrl -replace '^.*'+$MVNW_REPO_PATTERN,'')" +} +$distributionUrlName = $distributionUrl -replace '^.*/','' +$distributionUrlNameMain = $distributionUrlName -replace '\.[^.]*$','' -replace '-bin$','' +$MAVEN_HOME_PARENT = "$HOME/.m2/wrapper/dists/$distributionUrlNameMain" +$MAVEN_HOME_NAME = ([System.Security.Cryptography.MD5]::Create().ComputeHash([byte[]][char[]]$distributionUrl) | ForEach-Object {$_.ToString("x2")}) -join '' +$MAVEN_HOME = "$MAVEN_HOME_PARENT/$MAVEN_HOME_NAME" + +if (Test-Path -Path "$MAVEN_HOME" -PathType Container) { + Write-Verbose "found existing MAVEN_HOME at $MAVEN_HOME" + Write-Output "MVN_CMD=$MAVEN_HOME/bin/$MVN_CMD" + exit $? +} + +if (! $distributionUrlNameMain -or ($distributionUrlName -eq $distributionUrlNameMain)) { + Write-Error "distributionUrl is not valid, must end with *-bin.zip, but found $distributionUrl" +} + +# prepare tmp dir +$TMP_DOWNLOAD_DIR_HOLDER = New-TemporaryFile +$TMP_DOWNLOAD_DIR = New-Item -Itemtype Directory -Path "$TMP_DOWNLOAD_DIR_HOLDER.dir" +$TMP_DOWNLOAD_DIR_HOLDER.Delete() | Out-Null +trap { + if ($TMP_DOWNLOAD_DIR.Exists) { + try { Remove-Item $TMP_DOWNLOAD_DIR -Recurse -Force | Out-Null } + catch { Write-Warning "Cannot remove $TMP_DOWNLOAD_DIR" } + } +} + +New-Item -Itemtype Directory -Path "$MAVEN_HOME_PARENT" -Force | Out-Null + +# Download and Install Apache Maven +Write-Verbose "Couldn't find MAVEN_HOME, downloading and installing it ..." +Write-Verbose "Downloading from: $distributionUrl" +Write-Verbose "Downloading to: $TMP_DOWNLOAD_DIR/$distributionUrlName" + +$webclient = New-Object System.Net.WebClient +if ($env:MVNW_USERNAME -and $env:MVNW_PASSWORD) { + $webclient.Credentials = New-Object System.Net.NetworkCredential($env:MVNW_USERNAME, $env:MVNW_PASSWORD) +} +[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 +$webclient.DownloadFile($distributionUrl, "$TMP_DOWNLOAD_DIR/$distributionUrlName") | Out-Null + +# If specified, validate the SHA-256 sum of the Maven distribution zip file +$distributionSha256Sum = (Get-Content -Raw "$scriptDir/.mvn/wrapper/maven-wrapper.properties" | ConvertFrom-StringData).distributionSha256Sum +if ($distributionSha256Sum) { + if ($USE_MVND) { + Write-Error "Checksum validation is not supported for maven-mvnd. `nPlease disable validation by removing 'distributionSha256Sum' from your maven-wrapper.properties." + } + Import-Module $PSHOME\Modules\Microsoft.PowerShell.Utility -Function Get-FileHash + if ((Get-FileHash "$TMP_DOWNLOAD_DIR/$distributionUrlName" -Algorithm SHA256).Hash.ToLower() -ne $distributionSha256Sum) { + Write-Error "Error: Failed to validate Maven distribution SHA-256, your Maven distribution might be compromised. If you updated your Maven version, you need to update the specified distributionSha256Sum property." + } +} + +# unzip and move +Expand-Archive "$TMP_DOWNLOAD_DIR/$distributionUrlName" -DestinationPath "$TMP_DOWNLOAD_DIR" | Out-Null +Rename-Item -Path "$TMP_DOWNLOAD_DIR/$distributionUrlNameMain" -NewName $MAVEN_HOME_NAME | Out-Null +try { + Move-Item -Path "$TMP_DOWNLOAD_DIR/$MAVEN_HOME_NAME" -Destination $MAVEN_HOME_PARENT | Out-Null +} catch { + if (! (Test-Path -Path "$MAVEN_HOME" -PathType Container)) { + Write-Error "fail to move MAVEN_HOME" + } +} finally { + try { Remove-Item $TMP_DOWNLOAD_DIR -Recurse -Force | Out-Null } + catch { Write-Warning "Cannot remove $TMP_DOWNLOAD_DIR" } +} + +Write-Output "MVN_CMD=$MAVEN_HOME/bin/$MVN_CMD" diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..d468762 --- /dev/null +++ b/pom.xml @@ -0,0 +1,71 @@ + + + 4.0.0 + + org.springframework.boot + spring-boot-starter-parent + 3.3.0 + + + com.bonton + kafka + 0.0.1-SNAPSHOT + kafka + Demo project for Spring Boot + + 17 + 2023.0.3 + + + + org.springframework.boot + spring-boot-starter-web + + + org.springframework.cloud + spring-cloud-starter-netflix-eureka-client + + + org.springframework.kafka + spring-kafka + + + com.fasterxml.jackson.core + jackson-databind + + + + org.springframework.boot + spring-boot-starter-test + test + + + + org.springframework.kafka + spring-kafka-test + test + + + + + + org.springframework.cloud + spring-cloud-dependencies + ${spring-cloud.version} + pom + import + + + + + + + + org.springframework.boot + spring-boot-maven-plugin + + + + + diff --git a/src/main/java/com/bonton/kafka/DtoForBirth.java b/src/main/java/com/bonton/kafka/DtoForBirth.java new file mode 100644 index 0000000..ebc6683 --- /dev/null +++ b/src/main/java/com/bonton/kafka/DtoForBirth.java @@ -0,0 +1,57 @@ +package com.bonton.kafka; + + + +public class DtoForBirth { + + + private String eventType; + private String eventId; + private String userGuid; + private String vin; + private String originator; + public String getEventType() { + return eventType; + } + public void setEventType(String eventType) { + this.eventType = eventType; + } + public String getEventId() { + return eventId; + } + public void setEventId(String eventId) { + this.eventId = eventId; + } + public String getUserGuid() { + return userGuid; + } + public void setUserGuid(String userGuid) { + this.userGuid = userGuid; + } + public String getVin() { + return vin; + } + public void setVin(String vin) { + this.vin = vin; + } + public String getOriginator() { + return originator; + } + public void setOriginator(String originator) { + this.originator = originator; + } + public DtoForBirth(String eventType, String eventId, String userGuid, String vin, String originator) { + super(); + this.eventType = eventType; + this.eventId = eventId; + this.userGuid = userGuid; + this.vin = vin; + this.originator = originator; + } + public DtoForBirth() { + super(); + } + + + +} diff --git a/src/main/java/com/bonton/kafka/KafkaApplication.java b/src/main/java/com/bonton/kafka/KafkaApplication.java new file mode 100644 index 0000000..31a1b12 --- /dev/null +++ b/src/main/java/com/bonton/kafka/KafkaApplication.java @@ -0,0 +1,14 @@ +package com.bonton.kafka; + +import org.springframework.boot.SpringApplication; +import org.springframework.boot.autoconfigure.SpringBootApplication; + +@SpringBootApplication +public class KafkaApplication { + + public static void main(String[] args) { + System.out.println("hello"); + SpringApplication.run(KafkaApplication.class, args); + } + +} diff --git a/src/main/java/com/bonton/kafka/KafkaProducerService.java b/src/main/java/com/bonton/kafka/KafkaProducerService.java new file mode 100644 index 0000000..da93330 --- /dev/null +++ b/src/main/java/com/bonton/kafka/KafkaProducerService.java @@ -0,0 +1,56 @@ +package com.bonton.kafka; + + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.kafka.core.KafkaTemplate; +import org.springframework.kafka.support.SendResult; +import org.springframework.stereotype.Service; + +import java.util.concurrent.CompletableFuture; + +@Service +public class KafkaProducerService { + + private static final Logger log = LoggerFactory.getLogger(KafkaProducerService.class); + + private final KafkaTemplate kafkaTemplate; + + + + @Autowired + public KafkaProducerService(KafkaTemplate kafkaTemplate) { + this.kafkaTemplate = kafkaTemplate; + } + + + public void sendMessage(DtoForBirth message) { + log.info("Sending message to Kafka: {}", message); + CompletableFuture> send = kafkaTemplate.send("birth", message); + log.info("Message sent successfully"); +// send.whenComplete((sendResult, throwable) -> { +// if (throwable == null) { +// handleFailure(key, values, throwable); + +// } else { +// handleSuccess(key, values, sendResult); +// } +// } +// ); + } + + + + + private void handleSuccess(Integer key, String value, SendResult sendResult) { + log.info("Message Sent Successfully for the key : {} and the value : {} , partition is {} ", + key, value, sendResult.getRecordMetadata().partition()); + } + + private void handleFailure(Integer key, String value, Throwable ex) { + log.error("Error sending the message and the exception is {} ", ex.getMessage(), ex ); + } + + +} diff --git a/src/main/java/com/bonton/kafka/configuration/BirthServiceConfig.java b/src/main/java/com/bonton/kafka/configuration/BirthServiceConfig.java new file mode 100644 index 0000000..03c8fda --- /dev/null +++ b/src/main/java/com/bonton/kafka/configuration/BirthServiceConfig.java @@ -0,0 +1,38 @@ +package com.bonton.kafka.configuration; + +import com.bonton.kafka.dto.BirthDetailsDto; +import org.apache.kafka.clients.producer.ProducerConfig; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.Configuration; +import org.springframework.kafka.core.DefaultKafkaProducerFactory; +import org.springframework.kafka.core.KafkaTemplate; +import org.springframework.kafka.core.ProducerFactory; +import org.springframework.kafka.support.serializer.JsonSerializer; + +import java.util.HashMap; +import java.util.Map; + +@Configuration +public class BirthServiceConfig { + + @Bean + public ProducerFactory producerFactory1() { + return new DefaultKafkaProducerFactory<>(producerConfigs1()); + } + + @Bean//1 + public Map producerConfigs1(){ + Map props=new HashMap(); + props.put(ProducerConfig.BOOTSTRAP_SERVERS_CONFIG, "localhost:9092"); + props.put(ProducerConfig.KEY_SERIALIZER_CLASS_CONFIG, org.apache.kafka.common.serialization.StringSerializer.class); + props.put(ProducerConfig.VALUE_SERIALIZER_CLASS_CONFIG, JsonSerializer.class); + + return props; + + } + + @Bean + public KafkaTemplate kafkaTemplate1() { + return new KafkaTemplate<>(producerFactory1()); + } +} diff --git a/src/main/java/com/bonton/kafka/dto/BirthDetailsDto.java b/src/main/java/com/bonton/kafka/dto/BirthDetailsDto.java new file mode 100644 index 0000000..66bfc7b --- /dev/null +++ b/src/main/java/com/bonton/kafka/dto/BirthDetailsDto.java @@ -0,0 +1,1562 @@ +package com.bonton.kafka.dto; + +import com.fasterxml.jackson.annotation.JsonProperty; + +import org.springframework.stereotype.Component; + +import java.sql.Blob; +import java.util.Date; + +@Component +public class BirthDetailsDto { + @JsonProperty("Birth_id") + private int Birth_id; + @JsonProperty("Reporting_Date") + private String Reporting_Date; + @JsonProperty("PICME_No") + private String PICME_No; + @JsonProperty("Pre_Register_No") + private String Pre_Register_No; + + // -------------------PICME Pre - register: + @JsonProperty("PICME_Applicant_Name") + private String PICME_Applicant_Name; + @JsonProperty("PICME_Building_door_flat_no") + private String PICME_Building_door_flat_no; + @JsonProperty("PICME_Street") + private String PICME_Street; + @JsonProperty("PICME_Area") + private String PICME_Area; + @JsonProperty("PICME_District") + private String PICME_District; + @JsonProperty("PICME_Block") + private String PICME_Block; + @JsonProperty("PICME_Village") + private String PICME_Village; + @JsonProperty("PICME_Pincode") + private int PICME_Pincode; + @JsonProperty("PICME_Mobile_number") + private long PICME_Mobile_number; + + ////////////////////////////// + @JsonProperty("Child_Birth_Date") + private String Child_Birth_Date; + @JsonProperty("Gender") + private String Gender; + @JsonProperty("Child_Name_English") + private String Child_Name_English; + @JsonProperty("Child_Name_Tamil") + private String Child_Name_Tamil; + @JsonProperty("Aadhar_number") + private String Aadhar_number; + + //------------------------Birth Place Information: + //---------------Hospital + @JsonProperty("Hospital_name") + private String Hospital_name; + @JsonProperty("Hospital_Address_Line1_English") + private String Hospital_Address_Line1_English; + @JsonProperty("Hospital_Address_Line2_English") + private String Hospital_Address_Line2_English; + @JsonProperty("Hospital_Address_Line3_English") + private String Hospital_Address_Line3_English; + @JsonProperty("Hospital_Address_Line1_Tamil") + private String Hospital_Address_Line1_Tamil; + @JsonProperty("Hospital_Address_Line2_Tamil") + private String Hospital_Address_Line2_Tamil; + @JsonProperty("Hospital_Address_Line3_Tamil") + private String Hospital_Address_Line3_Tamil; + @JsonProperty("Hospital_pincode") + private int Hospital_pincode; + + //------------Home + @JsonProperty("Home_Address_Line1_English") + private String Home_Address_Line1_English; + @JsonProperty("Home_Address_Line2_English") + private String Home_Address_Line2_English; + @JsonProperty("Home_Address_Line3_English") + private String Home_Address_Line3_English; + @JsonProperty("Home_Address_Line1_Tamil") + private String Home_Address_Line1_Tamil; + @JsonProperty("Home_Address_Line2_Tamil") + private String Home_Address_Line2_Tamil; + @JsonProperty("Home_Address_Line3_Tamil") + private String Home_Address_Line3_Tamil; + @JsonProperty("Home_pincode") + private int Home_pincode; + + //----------------Other + @JsonProperty("Other_Option") + private String Other_Option; + @JsonProperty("Other_Address_Line1_English") + private String Other_Address_Line1_English; + @JsonProperty("Other_Address_Line2_English") + private String Other_Address_Line2_English; + @JsonProperty("Other_Address_Line3_English") + private String Other_Address_Line3_English; + @JsonProperty("Other_Address_Line1_Tamil") + private String Other_Address_Line1_Tamil; + @JsonProperty("Other_Address_Line2_Tamil") + private String Other_Address_Line2_Tamil; + @JsonProperty("Other_Address_Line3_Tamil") + private String Other_Address_Line3_Tamil; + @JsonProperty("Other_pincode") + private int Other_pincode; + + //------------------Informers Information: + @JsonProperty("Informer_name") + private String Informer_name; + @JsonProperty("Informer_Address_Line1_English") + private String Informer_Address_Line1_English; + @JsonProperty("Informer_Address_Line2_English") + private String Informer_Address_Line2_English; + @JsonProperty("Informer_Address_Line1_Tamil") + private String Informer_Address_Line1_Tamil; + @JsonProperty("Informer_Address_Line2_Tamil") + private String Informer_Address_Line2_Tamil; + @JsonProperty("Informer_pincode") + private int Informer_pincode; + + //-------------------Residence info of mother: + @JsonProperty("Mother_State") + private String Mother_State; + @JsonProperty("Mother_District") + private String Mother_District; + @JsonProperty("Mother_Sub_District") + private String Mother_Sub_District; + @JsonProperty("Mother_Town_Village") + private String Mother_Town_Village; + @JsonProperty("Mother_Name_of_Town_English") + private String Mother_Name_of_Town_English; + @JsonProperty("Mother_Name_of_Town_Tamil") + private String Mother_Name_of_Town_Tamil; + + //--------------------Reporting Form: + @JsonProperty("Upload_reporting_Form") + private String Upload_reporting_Form; + + //------------------------ Parents Information: + @JsonProperty("Parent_Father_name_English") + private String Parent_Father_name_English; + @JsonProperty("Parent_Mother_name_English") + private String Parent_Mother_name_English; + @JsonProperty("Parent_Father_name_Tamil") + private String Parent_Father_name_Tamil; + @JsonProperty("Parent_Mother_name_Tamil") + private String Parent_Mother_name_Tamil; + @JsonProperty("Parent_Father_Aadhar_number") + private String Parent_Father_Aadhar_number; + @JsonProperty("Parent_Mother_Aadhar_number") + private String Parent_Mother_Aadhar_number; + @JsonProperty("Parent_Father_Email_Id") + private String Parent_Father_Email_Id; + @JsonProperty("Parent_Mother_Email_Id") + private String Parent_Mother_Email_Id; + @JsonProperty("Parent_Father_Mobile_Number") + private String Parent_Father_Mobile_Number; + @JsonProperty("Parent_Mother_Mobile_Number") + private String Parent_Mother_Mobile_Number; + + //------------------------Parents Information: + @JsonProperty("Parent_Religion") + private String Parent_Religion; + @JsonProperty("Father_Level_of_Education") + private String Father_Level_of_Education; + @JsonProperty("Mother_Level_of_Education") + private String Mother_Level_of_Education; + @JsonProperty("Father_Occupation") + private String Father_Occupation; + @JsonProperty("Mother_Occupation") + private String Mother_Occupation; + @JsonProperty("Age_of_mother_at_time_of_marriage") + private int Age_of_mother_at_time_of_marriage; + @JsonProperty("Age_of_mother_at_time_of_birth") + private int Age_of_mother_at_time_of_birth; + @JsonProperty("Total_children_to_mother") + private int Total_children_to_mother; + @JsonProperty("Type_of_attention_delivery") + private String Type_of_attention_delivery; + @JsonProperty("Delivery_method") + private String Delivery_method; + @JsonProperty("Birth_Weight") + private float Birth_Weight; + @JsonProperty("Pregnancy_Duration") + private int Pregnancy_Duration; + + //--------------Parents Address at the time of birth of child: + // ------------In Tamil Nadu: + @JsonProperty("ITN_House_No") + private String ITN_House_No; + @JsonProperty("ITN_Street_Lane_Name_English") + private String ITN_Street_Lane_Name_English; + @JsonProperty("ITN_Locality_Post_Office_English") + private String ITN_Locality_Post_Office_English; + @JsonProperty("ITN_Village_Town_English") + private String ITN_Village_Town_English; + @JsonProperty("ITN_District") + private String ITN_District; + @JsonProperty("ITN_State") + private String ITN_State; + @JsonProperty("ITN_Sub_District") + private String ITN_Sub_District; + @JsonProperty("ITN_Pincode") + private int ITN_Pincode; + @JsonProperty("ITN_Street_Lane_Name_Tamil") + private String ITN_Street_Lane_Name_Tamil; + @JsonProperty("ITN_Locality_Post_Office_Tamil") + private String ITN_Locality_Post_Office_Tamil; + @JsonProperty("ITN_Village_Town_Tamil") + private String ITN_Village_Town_Tamil; + + //------------------------Outside Tamilnadu: + @JsonProperty("OTN_House_No") + private String OTN_House_No; + @JsonProperty("OTN_Street_Lane_Name_English") + private String OTN_Street_Lane_Name_English; + @JsonProperty("OTN_Locality_Post_Office_English") + private String OTN_Locality_Post_Office_English; + @JsonProperty("OTN_Village_Town_English") + private String OTN_Village_Town_English; + @JsonProperty("OTN_District") + private String OTN_District; + @JsonProperty("OTN_State") + private String OTN_State; + @JsonProperty("OTN_Sub_District") + private String OTN_Sub_District; + @JsonProperty("OTN_Pincode") + private int OTN_Pincode; + @JsonProperty("OTN_Street_Lane_Name_Tamil") + private String OTN_Street_Lane_Name_Tamil; + @JsonProperty("OTN_Locality_Post_Office_Tamil") + private String OTN_Locality_Post_Office_Tamil; + @JsonProperty("OTN_Village_Town_Tamil") + private String OTN_Village_Town_Tamil; + + //-------------------Outside India: + @JsonProperty("OI_Country") + private String OI_Country; + @JsonProperty("OI_Father_passport_no") + private String OI_Father_passport_no; + @JsonProperty("OI_Mother_passport_no") + private String OI_Mother_passport_no; + @JsonProperty("OI_Address_Line1") + private String OI_Address_Line1; + @JsonProperty("OI_Address_Line2") + private String OI_Address_Line2; + @JsonProperty("OI_Address_Line3") + private String OI_Address_Line3; + @JsonProperty("OI_Pincode") + private int OI_Pincode; + + //----------------------------Parents Permanent address: + //--------------In Tamil Nadu: + @JsonProperty("PPA_ITN_House_No") + private String PPA_ITN_House_No; + @JsonProperty("PPA_ITN_Street_Lane_Name_English") + private String PPA_ITN_Street_Lane_Name_English; + @JsonProperty("PPA_ITN_Locality_Post_Office_English") + private String PPA_ITN_Locality_Post_Office_English; + @JsonProperty("PPA_ITN_Village_Town_English") + private String PPA_ITN_Village_Town_English; + @JsonProperty("PPA_ITN_District") + private String PPA_ITN_District; + @JsonProperty("PPA_ITN_State") + private String PPA_ITN_State; + @JsonProperty("PPA_ITN_Sub_District") + private String PPA_ITN_Sub_District; + @JsonProperty("PPA_ITN_Pincode") + private int PPA_ITN_Pincode; + @JsonProperty("PPA_ITN_Street_Lane_Name_Tamil") + private String PPA_ITN_Street_Lane_Name_Tamil; + @JsonProperty("PPA_ITN_Locality_Post_Office_Tamil") + private String PPA_ITN_Locality_Post_Office_Tamil; + @JsonProperty("PPA_ITN_Village_Town_Tamil") + private String PPA_ITN_Village_Town_Tamil; + + //-----------------------Outside Tamil Nadu + @JsonProperty("PPA_OTN_House_No") + private String PPA_OTN_House_No; + @JsonProperty("PPA_OTN_Street_Lane_Name_English") + private String PPA_OTN_Street_Lane_Name_English; + @JsonProperty("PPA_OTN_Locality_Post_Office_English") + private String PPA_OTN_Locality_Post_Office_English; + @JsonProperty("PPA_OTN_Village_Town_English") + private String PPA_OTN_Village_Town_English; + @JsonProperty("PPA_OTN_District") + private String PPA_OTN_District; + @JsonProperty("PPA_OTN_State") + private String PPA_OTN_State; + @JsonProperty("PPA_OTN_Sub_District") + private String PPA_OTN_Sub_District; + @JsonProperty("PPA_OTN_Pincode") + private int PPA_OTN_Pincode; + @JsonProperty("PPA_OTN_Street_Lane_Name_Tamil") + private String PPA_OTN_Street_Lane_Name_Tamil; + @JsonProperty("PPA_OTN_Locality_Post_Office_Tamil") + private String PPA_OTN_Locality_Post_Office_Tamil; + @JsonProperty("PPA_OTN_Village_Town_Tamil") + private String PPA_OTN_Village_Town_Tamil; + + //-------------------Outside India: + @JsonProperty("PPA_OI_Country") + private String PPA_OI_Country; + @JsonProperty("PPA_OI_Father_passport_no") + private String PPA_OI_Father_passport_no; + @JsonProperty("PPA_OI_Mother_passport_no") + private String PPA_OI_Mother_passport_no; + @JsonProperty("PPA_OI_Address_Line1") + private String PPA_OI_Address_Line1; + @JsonProperty("PPA_OI_Address_Line2") + private String PPA_OI_Address_Line2; + @JsonProperty("PPA_OI_Address_Line3") + private String PPA_OI_Address_Line3; + @JsonProperty("PPA_OI_Pincode") + private int PPA_OI_Pincode; + @JsonProperty("status") + private String status; + + @JsonProperty("uuid") + private String uuid; + + @JsonProperty("fileUpload") + private byte[] fileUpload; + + public int getBirth_id() { + return Birth_id; + } + + public void setBirth_id(int birth_id) { + Birth_id = birth_id; + } + + public String getReporting_Date() { + return Reporting_Date; + } + + public void setReporting_Date(String reporting_Date) { + Reporting_Date = reporting_Date; + } + + public String getPICME_No() { + return PICME_No; + } + + public void setPICME_No(String PICME_No) { + this.PICME_No = PICME_No; + } + + public String getPre_Register_No() { + return Pre_Register_No; + } + + public void setPre_Register_No(String pre_Register_No) { + Pre_Register_No = pre_Register_No; + } + + public String getPICME_Applicant_Name() { + return PICME_Applicant_Name; + } + + public void setPICME_Applicant_Name(String PICME_Applicant_Name) { + this.PICME_Applicant_Name = PICME_Applicant_Name; + } + + public String getPICME_Building_door_flat_no() { + return PICME_Building_door_flat_no; + } + + public void setPICME_Building_door_flat_no(String PICME_Building_door_flat_no) { + this.PICME_Building_door_flat_no = PICME_Building_door_flat_no; + } + + public String getPICME_Street() { + return PICME_Street; + } + + public void setPICME_Street(String PICME_Street) { + this.PICME_Street = PICME_Street; + } + + public String getPICME_Area() { + return PICME_Area; + } + + public void setPICME_Area(String PICME_Area) { + this.PICME_Area = PICME_Area; + } + + public String getPICME_District() { + return PICME_District; + } + + public void setPICME_District(String PICME_District) { + this.PICME_District = PICME_District; + } + + public String getPICME_Block() { + return PICME_Block; + } + + public void setPICME_Block(String PICME_Block) { + this.PICME_Block = PICME_Block; + } + + public String getPICME_Village() { + return PICME_Village; + } + + public void setPICME_Village(String PICME_Village) { + this.PICME_Village = PICME_Village; + } + + public int getPICME_Pincode() { + return PICME_Pincode; + } + + public void setPICME_Pincode(int PICME_Pincode) { + this.PICME_Pincode = PICME_Pincode; + } + + public long getPICME_Mobile_number() { + return PICME_Mobile_number; + } + + public void setPICME_Mobile_number(long PICME_Mobile_number) { + this.PICME_Mobile_number = PICME_Mobile_number; + } + + public String getChild_Birth_Date() { + return Child_Birth_Date; + } + + public void setChild_Birth_Date(String child_Birth_Date) { + Child_Birth_Date = child_Birth_Date; + } + + public String getGender() { + return Gender; + } + + public void setGender(String gender) { + Gender = gender; + } + + public String getChild_Name_English() { + return Child_Name_English; + } + + public void setChild_Name_English(String child_Name_English) { + Child_Name_English = child_Name_English; + } + + public String getChild_Name_Tamil() { + return Child_Name_Tamil; + } + + public void setChild_Name_Tamil(String child_Name_Tamil) { + Child_Name_Tamil = child_Name_Tamil; + } + + public String getAadhar_number() { + return Aadhar_number; + } + + public void setAadhar_number(String aadhar_number) { + Aadhar_number = aadhar_number; + } + + public String getHospital_name() { + return Hospital_name; + } + + public void setHospital_name(String hospital_name) { + Hospital_name = hospital_name; + } + + public String getHospital_Address_Line1_English() { + return Hospital_Address_Line1_English; + } + + public void setHospital_Address_Line1_English(String hospital_Address_Line1_English) { + Hospital_Address_Line1_English = hospital_Address_Line1_English; + } + + public String getHospital_Address_Line2_English() { + return Hospital_Address_Line2_English; + } + + public void setHospital_Address_Line2_English(String hospital_Address_Line2_English) { + Hospital_Address_Line2_English = hospital_Address_Line2_English; + } + + public String getHospital_Address_Line3_English() { + return Hospital_Address_Line3_English; + } + + public void setHospital_Address_Line3_English(String hospital_Address_Line3_English) { + Hospital_Address_Line3_English = hospital_Address_Line3_English; + } + + public String getHospital_Address_Line1_Tamil() { + return Hospital_Address_Line1_Tamil; + } + + public void setHospital_Address_Line1_Tamil(String hospital_Address_Line1_Tamil) { + Hospital_Address_Line1_Tamil = hospital_Address_Line1_Tamil; + } + + public String getHospital_Address_Line2_Tamil() { + return Hospital_Address_Line2_Tamil; + } + + public void setHospital_Address_Line2_Tamil(String hospital_Address_Line2_Tamil) { + Hospital_Address_Line2_Tamil = hospital_Address_Line2_Tamil; + } + + public String getHospital_Address_Line3_Tamil() { + return Hospital_Address_Line3_Tamil; + } + + public void setHospital_Address_Line3_Tamil(String hospital_Address_Line3_Tamil) { + Hospital_Address_Line3_Tamil = hospital_Address_Line3_Tamil; + } + + public int getHospital_pincode() { + return Hospital_pincode; + } + + public void setHospital_pincode(int hospital_pincode) { + Hospital_pincode = hospital_pincode; + } + + public String getHome_Address_Line1_English() { + return Home_Address_Line1_English; + } + + public void setHome_Address_Line1_English(String home_Address_Line1_English) { + Home_Address_Line1_English = home_Address_Line1_English; + } + + public String getHome_Address_Line2_English() { + return Home_Address_Line2_English; + } + + public void setHome_Address_Line2_English(String home_Address_Line2_English) { + Home_Address_Line2_English = home_Address_Line2_English; + } + + public String getHome_Address_Line3_English() { + return Home_Address_Line3_English; + } + + public void setHome_Address_Line3_English(String home_Address_Line3_English) { + Home_Address_Line3_English = home_Address_Line3_English; + } + + public String getHome_Address_Line1_Tamil() { + return Home_Address_Line1_Tamil; + } + + public void setHome_Address_Line1_Tamil(String home_Address_Line1_Tamil) { + Home_Address_Line1_Tamil = home_Address_Line1_Tamil; + } + + public String getHome_Address_Line2_Tamil() { + return Home_Address_Line2_Tamil; + } + + public void setHome_Address_Line2_Tamil(String home_Address_Line2_Tamil) { + Home_Address_Line2_Tamil = home_Address_Line2_Tamil; + } + + public String getHome_Address_Line3_Tamil() { + return Home_Address_Line3_Tamil; + } + + public void setHome_Address_Line3_Tamil(String home_Address_Line3_Tamil) { + Home_Address_Line3_Tamil = home_Address_Line3_Tamil; + } + + public int getHome_pincode() { + return Home_pincode; + } + + public void setHome_pincode(int home_pincode) { + Home_pincode = home_pincode; + } + + public String getOther_Option() { + return Other_Option; + } + + public void setOther_Option(String other_Option) { + Other_Option = other_Option; + } + + public String getOther_Address_Line1_English() { + return Other_Address_Line1_English; + } + + public void setOther_Address_Line1_English(String other_Address_Line1_English) { + Other_Address_Line1_English = other_Address_Line1_English; + } + + public String getOther_Address_Line2_English() { + return Other_Address_Line2_English; + } + + public void setOther_Address_Line2_English(String other_Address_Line2_English) { + Other_Address_Line2_English = other_Address_Line2_English; + } + + public String getOther_Address_Line3_English() { + return Other_Address_Line3_English; + } + + public void setOther_Address_Line3_English(String other_Address_Line3_English) { + Other_Address_Line3_English = other_Address_Line3_English; + } + + public String getOther_Address_Line1_Tamil() { + return Other_Address_Line1_Tamil; + } + + public void setOther_Address_Line1_Tamil(String other_Address_Line1_Tamil) { + Other_Address_Line1_Tamil = other_Address_Line1_Tamil; + } + + public String getOther_Address_Line2_Tamil() { + return Other_Address_Line2_Tamil; + } + + public void setOther_Address_Line2_Tamil(String other_Address_Line2_Tamil) { + Other_Address_Line2_Tamil = other_Address_Line2_Tamil; + } + + public String getOther_Address_Line3_Tamil() { + return Other_Address_Line3_Tamil; + } + + public void setOther_Address_Line3_Tamil(String other_Address_Line3_Tamil) { + Other_Address_Line3_Tamil = other_Address_Line3_Tamil; + } + + public int getOther_pincode() { + return Other_pincode; + } + + public void setOther_pincode(int other_pincode) { + Other_pincode = other_pincode; + } + + public String getInformer_name() { + return Informer_name; + } + + public void setInformer_name(String informer_name) { + Informer_name = informer_name; + } + + public String getInformer_Address_Line1_English() { + return Informer_Address_Line1_English; + } + + public void setInformer_Address_Line1_English(String informer_Address_Line1_English) { + Informer_Address_Line1_English = informer_Address_Line1_English; + } + + public String getInformer_Address_Line2_English() { + return Informer_Address_Line2_English; + } + + public void setInformer_Address_Line2_English(String informer_Address_Line2_English) { + Informer_Address_Line2_English = informer_Address_Line2_English; + } + + public String getInformer_Address_Line1_Tamil() { + return Informer_Address_Line1_Tamil; + } + + public void setInformer_Address_Line1_Tamil(String informer_Address_Line1_Tamil) { + Informer_Address_Line1_Tamil = informer_Address_Line1_Tamil; + } + + public String getInformer_Address_Line2_Tamil() { + return Informer_Address_Line2_Tamil; + } + + public void setInformer_Address_Line2_Tamil(String informer_Address_Line2_Tamil) { + Informer_Address_Line2_Tamil = informer_Address_Line2_Tamil; + } + + public int getInformer_pincode() { + return Informer_pincode; + } + + public void setInformer_pincode(int informer_pincode) { + Informer_pincode = informer_pincode; + } + + public String getMother_State() { + return Mother_State; + } + + public void setMother_State(String mother_State) { + Mother_State = mother_State; + } + + public String getMother_District() { + return Mother_District; + } + + public void setMother_District(String mother_District) { + Mother_District = mother_District; + } + + public String getMother_Sub_District() { + return Mother_Sub_District; + } + + public void setMother_Sub_District(String mother_Sub_District) { + Mother_Sub_District = mother_Sub_District; + } + + public String getMother_Town_Village() { + return Mother_Town_Village; + } + + public void setMother_Town_Village(String mother_Town_Village) { + Mother_Town_Village = mother_Town_Village; + } + + public String getMother_Name_of_Town_English() { + return Mother_Name_of_Town_English; + } + + public void setMother_Name_of_Town_English(String mother_Name_of_Town_English) { + Mother_Name_of_Town_English = mother_Name_of_Town_English; + } + + public String getMother_Name_of_Town_Tamil() { + return Mother_Name_of_Town_Tamil; + } + + public void setMother_Name_of_Town_Tamil(String mother_Name_of_Town_Tamil) { + Mother_Name_of_Town_Tamil = mother_Name_of_Town_Tamil; + } + + public String getUpload_reporting_Form() { + return Upload_reporting_Form; + } + + public void setUpload_reporting_Form(String upload_reporting_Form) { + Upload_reporting_Form = upload_reporting_Form; + } + + public String getParent_Father_name_English() { + return Parent_Father_name_English; + } + + public void setParent_Father_name_English(String parent_Father_name_English) { + Parent_Father_name_English = parent_Father_name_English; + } + + public String getParent_Mother_name_English() { + return Parent_Mother_name_English; + } + + public void setParent_Mother_name_English(String parent_Mother_name_English) { + Parent_Mother_name_English = parent_Mother_name_English; + } + + public String getParent_Father_name_Tamil() { + return Parent_Father_name_Tamil; + } + + public void setParent_Father_name_Tamil(String parent_Father_name_Tamil) { + Parent_Father_name_Tamil = parent_Father_name_Tamil; + } + + public String getParent_Mother_name_Tamil() { + return Parent_Mother_name_Tamil; + } + + public void setParent_Mother_name_Tamil(String parent_Mother_name_Tamil) { + Parent_Mother_name_Tamil = parent_Mother_name_Tamil; + } + + public String getParent_Father_Aadhar_number() { + return Parent_Father_Aadhar_number; + } + + public void setParent_Father_Aadhar_number(String parent_Father_Aadhar_number) { + Parent_Father_Aadhar_number = parent_Father_Aadhar_number; + } + + public String getParent_Mother_Aadhar_number() { + return Parent_Mother_Aadhar_number; + } + + public void setParent_Mother_Aadhar_number(String parent_Mother_Aadhar_number) { + Parent_Mother_Aadhar_number = parent_Mother_Aadhar_number; + } + + public String getParent_Father_Email_Id() { + return Parent_Father_Email_Id; + } + + public void setParent_Father_Email_Id(String parent_Father_Email_Id) { + Parent_Father_Email_Id = parent_Father_Email_Id; + } + + public String getParent_Mother_Email_Id() { + return Parent_Mother_Email_Id; + } + + public void setParent_Mother_Email_Id(String parent_Mother_Email_Id) { + Parent_Mother_Email_Id = parent_Mother_Email_Id; + } + + public String getParent_Father_Mobile_Number() { + return Parent_Father_Mobile_Number; + } + + public void setParent_Father_Mobile_Number(String parent_Father_Mobile_Number) { + Parent_Father_Mobile_Number = parent_Father_Mobile_Number; + } + + public String getParent_Mother_Mobile_Number() { + return Parent_Mother_Mobile_Number; + } + + public void setParent_Mother_Mobile_Number(String parent_Mother_Mobile_Number) { + Parent_Mother_Mobile_Number = parent_Mother_Mobile_Number; + } + + public String getParent_Religion() { + return Parent_Religion; + } + + public void setParent_Religion(String parent_Religion) { + Parent_Religion = parent_Religion; + } + + public String getFather_Level_of_Education() { + return Father_Level_of_Education; + } + + public void setFather_Level_of_Education(String father_Level_of_Education) { + Father_Level_of_Education = father_Level_of_Education; + } + + public String getMother_Level_of_Education() { + return Mother_Level_of_Education; + } + + public void setMother_Level_of_Education(String mother_Level_of_Education) { + Mother_Level_of_Education = mother_Level_of_Education; + } + + public String getFather_Occupation() { + return Father_Occupation; + } + + public void setFather_Occupation(String father_Occupation) { + Father_Occupation = father_Occupation; + } + + public String getMother_Occupation() { + return Mother_Occupation; + } + + public void setMother_Occupation(String mother_Occupation) { + Mother_Occupation = mother_Occupation; + } + + public int getAge_of_mother_at_time_of_marriage() { + return Age_of_mother_at_time_of_marriage; + } + + public void setAge_of_mother_at_time_of_marriage(int age_of_mother_at_time_of_marriage) { + Age_of_mother_at_time_of_marriage = age_of_mother_at_time_of_marriage; + } + + public int getAge_of_mother_at_time_of_birth() { + return Age_of_mother_at_time_of_birth; + } + + public void setAge_of_mother_at_time_of_birth(int age_of_mother_at_time_of_birth) { + Age_of_mother_at_time_of_birth = age_of_mother_at_time_of_birth; + } + + public int getTotal_children_to_mother() { + return Total_children_to_mother; + } + + public void setTotal_children_to_mother(int total_children_to_mother) { + Total_children_to_mother = total_children_to_mother; + } + + public String getType_of_attention_delivery() { + return Type_of_attention_delivery; + } + + public void setType_of_attention_delivery(String type_of_attention_delivery) { + Type_of_attention_delivery = type_of_attention_delivery; + } + + public String getDelivery_method() { + return Delivery_method; + } + + public void setDelivery_method(String delivery_method) { + Delivery_method = delivery_method; + } + + public float getBirth_Weight() { + return Birth_Weight; + } + + public void setBirth_Weight(float birth_Weight) { + Birth_Weight = birth_Weight; + } + + public int getPregnancy_Duration() { + return Pregnancy_Duration; + } + + public void setPregnancy_Duration(int pregnancy_Duration) { + Pregnancy_Duration = pregnancy_Duration; + } + + public String getITN_House_No() { + return ITN_House_No; + } + + public void setITN_House_No(String ITN_House_No) { + this.ITN_House_No = ITN_House_No; + } + + public String getITN_Street_Lane_Name_English() { + return ITN_Street_Lane_Name_English; + } + + public void setITN_Street_Lane_Name_English(String ITN_Street_Lane_Name_English) { + this.ITN_Street_Lane_Name_English = ITN_Street_Lane_Name_English; + } + + public String getITN_Locality_Post_Office_English() { + return ITN_Locality_Post_Office_English; + } + + public void setITN_Locality_Post_Office_English(String ITN_Locality_Post_Office_English) { + this.ITN_Locality_Post_Office_English = ITN_Locality_Post_Office_English; + } + + public String getITN_Village_Town_English() { + return ITN_Village_Town_English; + } + + public void setITN_Village_Town_English(String ITN_Village_Town_English) { + this.ITN_Village_Town_English = ITN_Village_Town_English; + } + + public String getITN_District() { + return ITN_District; + } + + public void setITN_District(String ITN_District) { + this.ITN_District = ITN_District; + } + + public String getITN_State() { + return ITN_State; + } + + public void setITN_State(String ITN_State) { + this.ITN_State = ITN_State; + } + + public String getITN_Sub_District() { + return ITN_Sub_District; + } + + public void setITN_Sub_District(String ITN_Sub_District) { + this.ITN_Sub_District = ITN_Sub_District; + } + + public int getITN_Pincode() { + return ITN_Pincode; + } + + public void setITN_Pincode(int ITN_Pincode) { + this.ITN_Pincode = ITN_Pincode; + } + + public String getITN_Street_Lane_Name_Tamil() { + return ITN_Street_Lane_Name_Tamil; + } + + public void setITN_Street_Lane_Name_Tamil(String ITN_Street_Lane_Name_Tamil) { + this.ITN_Street_Lane_Name_Tamil = ITN_Street_Lane_Name_Tamil; + } + + public String getITN_Locality_Post_Office_Tamil() { + return ITN_Locality_Post_Office_Tamil; + } + + public void setITN_Locality_Post_Office_Tamil(String ITN_Locality_Post_Office_Tamil) { + this.ITN_Locality_Post_Office_Tamil = ITN_Locality_Post_Office_Tamil; + } + + public String getITN_Village_Town_Tamil() { + return ITN_Village_Town_Tamil; + } + + public void setITN_Village_Town_Tamil(String ITN_Village_Town_Tamil) { + this.ITN_Village_Town_Tamil = ITN_Village_Town_Tamil; + } + + public String getOTN_House_No() { + return OTN_House_No; + } + + public void setOTN_House_No(String OTN_House_No) { + this.OTN_House_No = OTN_House_No; + } + + public String getOTN_Street_Lane_Name_English() { + return OTN_Street_Lane_Name_English; + } + + public void setOTN_Street_Lane_Name_English(String OTN_Street_Lane_Name_English) { + this.OTN_Street_Lane_Name_English = OTN_Street_Lane_Name_English; + } + + public String getOTN_Locality_Post_Office_English() { + return OTN_Locality_Post_Office_English; + } + + public void setOTN_Locality_Post_Office_English(String OTN_Locality_Post_Office_English) { + this.OTN_Locality_Post_Office_English = OTN_Locality_Post_Office_English; + } + + public String getOTN_Village_Town_English() { + return OTN_Village_Town_English; + } + + public void setOTN_Village_Town_English(String OTN_Village_Town_English) { + this.OTN_Village_Town_English = OTN_Village_Town_English; + } + + public String getOTN_District() { + return OTN_District; + } + + public void setOTN_District(String OTN_District) { + this.OTN_District = OTN_District; + } + + public String getOTN_State() { + return OTN_State; + } + + public void setOTN_State(String OTN_State) { + this.OTN_State = OTN_State; + } + + public String getOTN_Sub_District() { + return OTN_Sub_District; + } + + public void setOTN_Sub_District(String OTN_Sub_District) { + this.OTN_Sub_District = OTN_Sub_District; + } + + public int getOTN_Pincode() { + return OTN_Pincode; + } + + public void setOTN_Pincode(int OTN_Pincode) { + this.OTN_Pincode = OTN_Pincode; + } + + public String getOTN_Street_Lane_Name_Tamil() { + return OTN_Street_Lane_Name_Tamil; + } + + public void setOTN_Street_Lane_Name_Tamil(String OTN_Street_Lane_Name_Tamil) { + this.OTN_Street_Lane_Name_Tamil = OTN_Street_Lane_Name_Tamil; + } + + public String getOTN_Locality_Post_Office_Tamil() { + return OTN_Locality_Post_Office_Tamil; + } + + public void setOTN_Locality_Post_Office_Tamil(String OTN_Locality_Post_Office_Tamil) { + this.OTN_Locality_Post_Office_Tamil = OTN_Locality_Post_Office_Tamil; + } + + public String getOTN_Village_Town_Tamil() { + return OTN_Village_Town_Tamil; + } + + public void setOTN_Village_Town_Tamil(String OTN_Village_Town_Tamil) { + this.OTN_Village_Town_Tamil = OTN_Village_Town_Tamil; + } + + public String getOI_Country() { + return OI_Country; + } + + public void setOI_Country(String OI_Country) { + this.OI_Country = OI_Country; + } + + public String getOI_Father_passport_no() { + return OI_Father_passport_no; + } + + public void setOI_Father_passport_no(String OI_Father_passport_no) { + this.OI_Father_passport_no = OI_Father_passport_no; + } + + public String getOI_Mother_passport_no() { + return OI_Mother_passport_no; + } + + public void setOI_Mother_passport_no(String OI_Mother_passport_no) { + this.OI_Mother_passport_no = OI_Mother_passport_no; + } + + public String getOI_Address_Line1() { + return OI_Address_Line1; + } + + public void setOI_Address_Line1(String OI_Address_Line1) { + this.OI_Address_Line1 = OI_Address_Line1; + } + + public String getOI_Address_Line2() { + return OI_Address_Line2; + } + + public void setOI_Address_Line2(String OI_Address_Line2) { + this.OI_Address_Line2 = OI_Address_Line2; + } + + public String getOI_Address_Line3() { + return OI_Address_Line3; + } + + public void setOI_Address_Line3(String OI_Address_Line3) { + this.OI_Address_Line3 = OI_Address_Line3; + } + + public int getOI_Pincode() { + return OI_Pincode; + } + + public void setOI_Pincode(int OI_Pincode) { + this.OI_Pincode = OI_Pincode; + } + + public String getPPA_ITN_House_No() { + return PPA_ITN_House_No; + } + + public void setPPA_ITN_House_No(String PPA_ITN_House_No) { + this.PPA_ITN_House_No = PPA_ITN_House_No; + } + + public String getPPA_ITN_Street_Lane_Name_English() { + return PPA_ITN_Street_Lane_Name_English; + } + + public void setPPA_ITN_Street_Lane_Name_English(String PPA_ITN_Street_Lane_Name_English) { + this.PPA_ITN_Street_Lane_Name_English = PPA_ITN_Street_Lane_Name_English; + } + + public String getPPA_ITN_Locality_Post_Office_English() { + return PPA_ITN_Locality_Post_Office_English; + } + + public void setPPA_ITN_Locality_Post_Office_English(String PPA_ITN_Locality_Post_Office_English) { + this.PPA_ITN_Locality_Post_Office_English = PPA_ITN_Locality_Post_Office_English; + } + + public String getPPA_ITN_Village_Town_English() { + return PPA_ITN_Village_Town_English; + } + + public void setPPA_ITN_Village_Town_English(String PPA_ITN_Village_Town_English) { + this.PPA_ITN_Village_Town_English = PPA_ITN_Village_Town_English; + } + + public String getPPA_ITN_District() { + return PPA_ITN_District; + } + + public void setPPA_ITN_District(String PPA_ITN_District) { + this.PPA_ITN_District = PPA_ITN_District; + } + + public String getPPA_ITN_State() { + return PPA_ITN_State; + } + + public void setPPA_ITN_State(String PPA_ITN_State) { + this.PPA_ITN_State = PPA_ITN_State; + } + + public String getPPA_ITN_Sub_District() { + return PPA_ITN_Sub_District; + } + + public void setPPA_ITN_Sub_District(String PPA_ITN_Sub_District) { + this.PPA_ITN_Sub_District = PPA_ITN_Sub_District; + } + + public int getPPA_ITN_Pincode() { + return PPA_ITN_Pincode; + } + + public void setPPA_ITN_Pincode(int PPA_ITN_Pincode) { + this.PPA_ITN_Pincode = PPA_ITN_Pincode; + } + + public String getPPA_ITN_Street_Lane_Name_Tamil() { + return PPA_ITN_Street_Lane_Name_Tamil; + } + + public void setPPA_ITN_Street_Lane_Name_Tamil(String PPA_ITN_Street_Lane_Name_Tamil) { + this.PPA_ITN_Street_Lane_Name_Tamil = PPA_ITN_Street_Lane_Name_Tamil; + } + + public String getPPA_ITN_Locality_Post_Office_Tamil() { + return PPA_ITN_Locality_Post_Office_Tamil; + } + + public void setPPA_ITN_Locality_Post_Office_Tamil(String PPA_ITN_Locality_Post_Office_Tamil) { + this.PPA_ITN_Locality_Post_Office_Tamil = PPA_ITN_Locality_Post_Office_Tamil; + } + + public String getPPA_ITN_Village_Town_Tamil() { + return PPA_ITN_Village_Town_Tamil; + } + + public void setPPA_ITN_Village_Town_Tamil(String PPA_ITN_Village_Town_Tamil) { + this.PPA_ITN_Village_Town_Tamil = PPA_ITN_Village_Town_Tamil; + } + + public String getPPA_OTN_House_No() { + return PPA_OTN_House_No; + } + + public void setPPA_OTN_House_No(String PPA_OTN_House_No) { + this.PPA_OTN_House_No = PPA_OTN_House_No; + } + + public String getPPA_OTN_Street_Lane_Name_English() { + return PPA_OTN_Street_Lane_Name_English; + } + + public void setPPA_OTN_Street_Lane_Name_English(String PPA_OTN_Street_Lane_Name_English) { + this.PPA_OTN_Street_Lane_Name_English = PPA_OTN_Street_Lane_Name_English; + } + + public String getPPA_OTN_Locality_Post_Office_English() { + return PPA_OTN_Locality_Post_Office_English; + } + + public void setPPA_OTN_Locality_Post_Office_English(String PPA_OTN_Locality_Post_Office_English) { + this.PPA_OTN_Locality_Post_Office_English = PPA_OTN_Locality_Post_Office_English; + } + + public String getPPA_OTN_Village_Town_English() { + return PPA_OTN_Village_Town_English; + } + + public void setPPA_OTN_Village_Town_English(String PPA_OTN_Village_Town_English) { + this.PPA_OTN_Village_Town_English = PPA_OTN_Village_Town_English; + } + + public String getPPA_OTN_District() { + return PPA_OTN_District; + } + + public void setPPA_OTN_District(String PPA_OTN_District) { + this.PPA_OTN_District = PPA_OTN_District; + } + + public String getPPA_OTN_State() { + return PPA_OTN_State; + } + + public void setPPA_OTN_State(String PPA_OTN_State) { + this.PPA_OTN_State = PPA_OTN_State; + } + + public String getPPA_OTN_Sub_District() { + return PPA_OTN_Sub_District; + } + + public void setPPA_OTN_Sub_District(String PPA_OTN_Sub_District) { + this.PPA_OTN_Sub_District = PPA_OTN_Sub_District; + } + + public int getPPA_OTN_Pincode() { + return PPA_OTN_Pincode; + } + + public void setPPA_OTN_Pincode(int PPA_OTN_Pincode) { + this.PPA_OTN_Pincode = PPA_OTN_Pincode; + } + + public String getPPA_OTN_Street_Lane_Name_Tamil() { + return PPA_OTN_Street_Lane_Name_Tamil; + } + + public void setPPA_OTN_Street_Lane_Name_Tamil(String PPA_OTN_Street_Lane_Name_Tamil) { + this.PPA_OTN_Street_Lane_Name_Tamil = PPA_OTN_Street_Lane_Name_Tamil; + } + + public String getPPA_OTN_Locality_Post_Office_Tamil() { + return PPA_OTN_Locality_Post_Office_Tamil; + } + + public void setPPA_OTN_Locality_Post_Office_Tamil(String PPA_OTN_Locality_Post_Office_Tamil) { + this.PPA_OTN_Locality_Post_Office_Tamil = PPA_OTN_Locality_Post_Office_Tamil; + } + + public String getPPA_OTN_Village_Town_Tamil() { + return PPA_OTN_Village_Town_Tamil; + } + + public void setPPA_OTN_Village_Town_Tamil(String PPA_OTN_Village_Town_Tamil) { + this.PPA_OTN_Village_Town_Tamil = PPA_OTN_Village_Town_Tamil; + } + + public String getPPA_OI_Country() { + return PPA_OI_Country; + } + + public void setPPA_OI_Country(String PPA_OI_Country) { + this.PPA_OI_Country = PPA_OI_Country; + } + + public String getPPA_OI_Father_passport_no() { + return PPA_OI_Father_passport_no; + } + + public void setPPA_OI_Father_passport_no(String PPA_OI_Father_passport_no) { + this.PPA_OI_Father_passport_no = PPA_OI_Father_passport_no; + } + + public String getPPA_OI_Mother_passport_no() { + return PPA_OI_Mother_passport_no; + } + + public void setPPA_OI_Mother_passport_no(String PPA_OI_Mother_passport_no) { + this.PPA_OI_Mother_passport_no = PPA_OI_Mother_passport_no; + } + + public String getPPA_OI_Address_Line1() { + return PPA_OI_Address_Line1; + } + + public void setPPA_OI_Address_Line1(String PPA_OI_Address_Line1) { + this.PPA_OI_Address_Line1 = PPA_OI_Address_Line1; + } + + public String getPPA_OI_Address_Line2() { + return PPA_OI_Address_Line2; + } + + public void setPPA_OI_Address_Line2(String PPA_OI_Address_Line2) { + this.PPA_OI_Address_Line2 = PPA_OI_Address_Line2; + } + + public String getPPA_OI_Address_Line3() { + return PPA_OI_Address_Line3; + } + + public void setPPA_OI_Address_Line3(String PPA_OI_Address_Line3) { + this.PPA_OI_Address_Line3 = PPA_OI_Address_Line3; + } + + public int getPPA_OI_Pincode() { + return PPA_OI_Pincode; + } + + public void setPPA_OI_Pincode(int PPA_OI_Pincode) { + this.PPA_OI_Pincode = PPA_OI_Pincode; + } + + public String getStatus() { + return status; + } + + public void setStatus(String status) { + this.status = status; + } + + public String getUuid() { + return uuid; + } + + public void setUuid(String uuid) { + this.uuid = uuid; + } + + public byte[] getFileUpload() { + return fileUpload; + } + + public void setFileUpload(byte[] fileUpload) { + this.fileUpload = fileUpload; + } + + public BirthDetailsDto() { + } + + public BirthDetailsDto(int birth_id, String reporting_Date, String PICME_No, String pre_Register_No, String PICME_Applicant_Name, String PICME_Building_door_flat_no, String PICME_Street, String PICME_Area, String PICME_District, String PICME_Block, String PICME_Village, int PICME_Pincode, long PICME_Mobile_number, String child_Birth_Date, String gender, String child_Name_English, String child_Name_Tamil, String aadhar_number, String hospital_name, String hospital_Address_Line1_English, String hospital_Address_Line2_English, String hospital_Address_Line3_English, String hospital_Address_Line1_Tamil, String hospital_Address_Line2_Tamil, String hospital_Address_Line3_Tamil, int hospital_pincode, String home_Address_Line1_English, String home_Address_Line2_English, String home_Address_Line3_English, String home_Address_Line1_Tamil, String home_Address_Line2_Tamil, String home_Address_Line3_Tamil, int home_pincode, String other_Option, String other_Address_Line1_English, String other_Address_Line2_English, String other_Address_Line3_English, String other_Address_Line1_Tamil, String other_Address_Line2_Tamil, String other_Address_Line3_Tamil, int other_pincode, String informer_name, String informer_Address_Line1_English, String informer_Address_Line2_English, String informer_Address_Line1_Tamil, String informer_Address_Line2_Tamil, int informer_pincode, String mother_State, String mother_District, String mother_Sub_District, String mother_Town_Village, String mother_Name_of_Town_English, String mother_Name_of_Town_Tamil, String upload_reporting_Form, String parent_Father_name_English, String parent_Mother_name_English, String parent_Father_name_Tamil, String parent_Mother_name_Tamil, String parent_Father_Aadhar_number, String parent_Mother_Aadhar_number, String parent_Father_Email_Id, String parent_Mother_Email_Id, String parent_Father_Mobile_Number, String parent_Mother_Mobile_Number, String parent_Religion, String father_Level_of_Education, String mother_Level_of_Education, String father_Occupation, String mother_Occupation, int age_of_mother_at_time_of_marriage, int age_of_mother_at_time_of_birth, int total_children_to_mother, String type_of_attention_delivery, String delivery_method, float birth_Weight, int pregnancy_Duration, String ITN_House_No, String ITN_Street_Lane_Name_English, String ITN_Locality_Post_Office_English, String ITN_Village_Town_English, String ITN_District, String ITN_State, String ITN_Sub_District, int ITN_Pincode, String ITN_Street_Lane_Name_Tamil, String ITN_Locality_Post_Office_Tamil, String ITN_Village_Town_Tamil, String OTN_House_No, String OTN_Street_Lane_Name_English, String OTN_Locality_Post_Office_English, String OTN_Village_Town_English, String OTN_District, String OTN_State, String OTN_Sub_District, int OTN_Pincode, String OTN_Street_Lane_Name_Tamil, String OTN_Locality_Post_Office_Tamil, String OTN_Village_Town_Tamil, String OI_Country, String OI_Father_passport_no, String OI_Mother_passport_no, String OI_Address_Line1, String OI_Address_Line2, String OI_Address_Line3, int OI_Pincode, String PPA_ITN_House_No, String PPA_ITN_Street_Lane_Name_English, String PPA_ITN_Locality_Post_Office_English, String PPA_ITN_Village_Town_English, String PPA_ITN_District, String PPA_ITN_State, String PPA_ITN_Sub_District, int PPA_ITN_Pincode, String PPA_ITN_Street_Lane_Name_Tamil, String PPA_ITN_Locality_Post_Office_Tamil, String PPA_ITN_Village_Town_Tamil, String PPA_OTN_House_No, String PPA_OTN_Street_Lane_Name_English, String PPA_OTN_Locality_Post_Office_English, String PPA_OTN_Village_Town_English, String PPA_OTN_District, String PPA_OTN_State, String PPA_OTN_Sub_District, int PPA_OTN_Pincode, String PPA_OTN_Street_Lane_Name_Tamil, String PPA_OTN_Locality_Post_Office_Tamil, String PPA_OTN_Village_Town_Tamil, String PPA_OI_Country, String PPA_OI_Father_passport_no, String PPA_OI_Mother_passport_no, String PPA_OI_Address_Line1, String PPA_OI_Address_Line2, String PPA_OI_Address_Line3, int PPA_OI_Pincode, String status, String uuid, byte[] fileUpload) { + Birth_id = birth_id; + Reporting_Date = reporting_Date; + this.PICME_No = PICME_No; + Pre_Register_No = pre_Register_No; + this.PICME_Applicant_Name = PICME_Applicant_Name; + this.PICME_Building_door_flat_no = PICME_Building_door_flat_no; + this.PICME_Street = PICME_Street; + this.PICME_Area = PICME_Area; + this.PICME_District = PICME_District; + this.PICME_Block = PICME_Block; + this.PICME_Village = PICME_Village; + this.PICME_Pincode = PICME_Pincode; + this.PICME_Mobile_number = PICME_Mobile_number; + Child_Birth_Date = child_Birth_Date; + Gender = gender; + Child_Name_English = child_Name_English; + Child_Name_Tamil = child_Name_Tamil; + Aadhar_number = aadhar_number; + Hospital_name = hospital_name; + Hospital_Address_Line1_English = hospital_Address_Line1_English; + Hospital_Address_Line2_English = hospital_Address_Line2_English; + Hospital_Address_Line3_English = hospital_Address_Line3_English; + Hospital_Address_Line1_Tamil = hospital_Address_Line1_Tamil; + Hospital_Address_Line2_Tamil = hospital_Address_Line2_Tamil; + Hospital_Address_Line3_Tamil = hospital_Address_Line3_Tamil; + Hospital_pincode = hospital_pincode; + Home_Address_Line1_English = home_Address_Line1_English; + Home_Address_Line2_English = home_Address_Line2_English; + Home_Address_Line3_English = home_Address_Line3_English; + Home_Address_Line1_Tamil = home_Address_Line1_Tamil; + Home_Address_Line2_Tamil = home_Address_Line2_Tamil; + Home_Address_Line3_Tamil = home_Address_Line3_Tamil; + Home_pincode = home_pincode; + Other_Option = other_Option; + Other_Address_Line1_English = other_Address_Line1_English; + Other_Address_Line2_English = other_Address_Line2_English; + Other_Address_Line3_English = other_Address_Line3_English; + Other_Address_Line1_Tamil = other_Address_Line1_Tamil; + Other_Address_Line2_Tamil = other_Address_Line2_Tamil; + Other_Address_Line3_Tamil = other_Address_Line3_Tamil; + Other_pincode = other_pincode; + Informer_name = informer_name; + Informer_Address_Line1_English = informer_Address_Line1_English; + Informer_Address_Line2_English = informer_Address_Line2_English; + Informer_Address_Line1_Tamil = informer_Address_Line1_Tamil; + Informer_Address_Line2_Tamil = informer_Address_Line2_Tamil; + Informer_pincode = informer_pincode; + Mother_State = mother_State; + Mother_District = mother_District; + Mother_Sub_District = mother_Sub_District; + Mother_Town_Village = mother_Town_Village; + Mother_Name_of_Town_English = mother_Name_of_Town_English; + Mother_Name_of_Town_Tamil = mother_Name_of_Town_Tamil; + Upload_reporting_Form = upload_reporting_Form; + Parent_Father_name_English = parent_Father_name_English; + Parent_Mother_name_English = parent_Mother_name_English; + Parent_Father_name_Tamil = parent_Father_name_Tamil; + Parent_Mother_name_Tamil = parent_Mother_name_Tamil; + Parent_Father_Aadhar_number = parent_Father_Aadhar_number; + Parent_Mother_Aadhar_number = parent_Mother_Aadhar_number; + Parent_Father_Email_Id = parent_Father_Email_Id; + Parent_Mother_Email_Id = parent_Mother_Email_Id; + Parent_Father_Mobile_Number = parent_Father_Mobile_Number; + Parent_Mother_Mobile_Number = parent_Mother_Mobile_Number; + Parent_Religion = parent_Religion; + Father_Level_of_Education = father_Level_of_Education; + Mother_Level_of_Education = mother_Level_of_Education; + Father_Occupation = father_Occupation; + Mother_Occupation = mother_Occupation; + Age_of_mother_at_time_of_marriage = age_of_mother_at_time_of_marriage; + Age_of_mother_at_time_of_birth = age_of_mother_at_time_of_birth; + Total_children_to_mother = total_children_to_mother; + Type_of_attention_delivery = type_of_attention_delivery; + Delivery_method = delivery_method; + Birth_Weight = birth_Weight; + Pregnancy_Duration = pregnancy_Duration; + this.ITN_House_No = ITN_House_No; + this.ITN_Street_Lane_Name_English = ITN_Street_Lane_Name_English; + this.ITN_Locality_Post_Office_English = ITN_Locality_Post_Office_English; + this.ITN_Village_Town_English = ITN_Village_Town_English; + this.ITN_District = ITN_District; + this.ITN_State = ITN_State; + this.ITN_Sub_District = ITN_Sub_District; + this.ITN_Pincode = ITN_Pincode; + this.ITN_Street_Lane_Name_Tamil = ITN_Street_Lane_Name_Tamil; + this.ITN_Locality_Post_Office_Tamil = ITN_Locality_Post_Office_Tamil; + this.ITN_Village_Town_Tamil = ITN_Village_Town_Tamil; + this.OTN_House_No = OTN_House_No; + this.OTN_Street_Lane_Name_English = OTN_Street_Lane_Name_English; + this.OTN_Locality_Post_Office_English = OTN_Locality_Post_Office_English; + this.OTN_Village_Town_English = OTN_Village_Town_English; + this.OTN_District = OTN_District; + this.OTN_State = OTN_State; + this.OTN_Sub_District = OTN_Sub_District; + this.OTN_Pincode = OTN_Pincode; + this.OTN_Street_Lane_Name_Tamil = OTN_Street_Lane_Name_Tamil; + this.OTN_Locality_Post_Office_Tamil = OTN_Locality_Post_Office_Tamil; + this.OTN_Village_Town_Tamil = OTN_Village_Town_Tamil; + this.OI_Country = OI_Country; + this.OI_Father_passport_no = OI_Father_passport_no; + this.OI_Mother_passport_no = OI_Mother_passport_no; + this.OI_Address_Line1 = OI_Address_Line1; + this.OI_Address_Line2 = OI_Address_Line2; + this.OI_Address_Line3 = OI_Address_Line3; + this.OI_Pincode = OI_Pincode; + this.PPA_ITN_House_No = PPA_ITN_House_No; + this.PPA_ITN_Street_Lane_Name_English = PPA_ITN_Street_Lane_Name_English; + this.PPA_ITN_Locality_Post_Office_English = PPA_ITN_Locality_Post_Office_English; + this.PPA_ITN_Village_Town_English = PPA_ITN_Village_Town_English; + this.PPA_ITN_District = PPA_ITN_District; + this.PPA_ITN_State = PPA_ITN_State; + this.PPA_ITN_Sub_District = PPA_ITN_Sub_District; + this.PPA_ITN_Pincode = PPA_ITN_Pincode; + this.PPA_ITN_Street_Lane_Name_Tamil = PPA_ITN_Street_Lane_Name_Tamil; + this.PPA_ITN_Locality_Post_Office_Tamil = PPA_ITN_Locality_Post_Office_Tamil; + this.PPA_ITN_Village_Town_Tamil = PPA_ITN_Village_Town_Tamil; + this.PPA_OTN_House_No = PPA_OTN_House_No; + this.PPA_OTN_Street_Lane_Name_English = PPA_OTN_Street_Lane_Name_English; + this.PPA_OTN_Locality_Post_Office_English = PPA_OTN_Locality_Post_Office_English; + this.PPA_OTN_Village_Town_English = PPA_OTN_Village_Town_English; + this.PPA_OTN_District = PPA_OTN_District; + this.PPA_OTN_State = PPA_OTN_State; + this.PPA_OTN_Sub_District = PPA_OTN_Sub_District; + this.PPA_OTN_Pincode = PPA_OTN_Pincode; + this.PPA_OTN_Street_Lane_Name_Tamil = PPA_OTN_Street_Lane_Name_Tamil; + this.PPA_OTN_Locality_Post_Office_Tamil = PPA_OTN_Locality_Post_Office_Tamil; + this.PPA_OTN_Village_Town_Tamil = PPA_OTN_Village_Town_Tamil; + this.PPA_OI_Country = PPA_OI_Country; + this.PPA_OI_Father_passport_no = PPA_OI_Father_passport_no; + this.PPA_OI_Mother_passport_no = PPA_OI_Mother_passport_no; + this.PPA_OI_Address_Line1 = PPA_OI_Address_Line1; + this.PPA_OI_Address_Line2 = PPA_OI_Address_Line2; + this.PPA_OI_Address_Line3 = PPA_OI_Address_Line3; + this.PPA_OI_Pincode = PPA_OI_Pincode; + this.status = status; + this.uuid = uuid; + this.fileUpload = fileUpload; + } +} diff --git a/src/main/java/com/bonton/kafka/dto/BirthRegisterDto.java b/src/main/java/com/bonton/kafka/dto/BirthRegisterDto.java new file mode 100644 index 0000000..d77934d --- /dev/null +++ b/src/main/java/com/bonton/kafka/dto/BirthRegisterDto.java @@ -0,0 +1,33 @@ +//package com.bonton.kafka.dto; +// +//public class BirthRegisterDto { +// private BirthDetailsDto birthDetailsDto; +//// public enum status { +//// NEW, UPDATE +//// } +// private String status; +// +// public BirthDetailsDto getBirthDetailsDto() { +// return birthDetailsDto; +// } +// +// public void setBirthDetailsDto(BirthDetailsDto birthDetailsDto) { +// this.birthDetailsDto = birthDetailsDto; +// } +// +// public String getStatus() { +// return status; +// } +// +// public void setStatus(String status) { +// this.status = status; +// } +// +// public BirthRegisterDto() { +// } +// +// public BirthRegisterDto(BirthDetailsDto birthDetailsDto) { +// this.birthDetailsDto = birthDetailsDto; +// } +//} +// diff --git a/src/main/java/com/bonton/kafka/entering.java b/src/main/java/com/bonton/kafka/entering.java new file mode 100644 index 0000000..630ce07 --- /dev/null +++ b/src/main/java/com/bonton/kafka/entering.java @@ -0,0 +1,102 @@ +package com.bonton.kafka; + +import com.bonton.kafka.dto.BirthDetailsDto; + +import com.bonton.kafka.service.BirthService; +//import com.bonton.kafka.utility.FileService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.http.ResponseEntity; +import org.springframework.web.bind.annotation.*; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.springframework.web.multipart.MultipartFile; + +import javax.sql.rowset.serial.SerialBlob; +import java.sql.Blob; + +@RestController + +@RequestMapping("/producer") +public class entering { + + private static final Logger log = LoggerFactory.getLogger(entering.class); + + +// private KafkaTemplate kafkaTemplete; + + @Autowired + private KafkaProducerService Service; + + @Autowired + private BirthService birthService; + +// private final FileService fileService; +// +// public entering(FileService fileService) { +// this.fileService = fileService; +// } + +// @GetMapping("/send") +// public void publish(@RequestBody DtoForBirth message) { +// Service.sendMessage(message); +// } + +//@CrossOrigin(origins = "http://localhost:8088") +//@RequestMapping(value = "/savebirth", method = RequestMethod.POST) +// public void saveBirth(@RequestBody BirthDetailsDto aa){ +// System.out.println("#######################################################"); +// System.out.println(aa.getBirth_id()); +// System.out.println(aa.getStatus()); +// System.out.println(aa.getGender()); +// +//// birthService.sendBirthDetails(aa); +// birthService.sendBirthDetail(aa); +// } +//@CrossOrigin(origins = "http://localhost:8088") +@RequestMapping(value = "/savebirth", method = RequestMethod.POST) +public ResponseEntity saveBirth(@RequestBody BirthDetailsDto aa){ + + +// birthService.sendBirthDetails(aa); + birthService.sendBirthDetail(aa); + System.out.println("Returning success response"); + return ResponseEntity.ok("Birth data saved successfully"); +} + +@RequestMapping(value="/nameInclusion", method = RequestMethod.POST) + public ResponseEntity addName(@RequestParam String uuid,@RequestParam String childName, @RequestParam MultipartFile fileUpload, @RequestParam String status) throws Exception { + System.out.println("Check 1"); + BirthDetailsDto birthDetailsDto = new BirthDetailsDto(); + birthDetailsDto.setStatus(status); + birthDetailsDto.setUuid(uuid); + birthDetailsDto.setChild_Name_English(childName); + + System.out.println("Check 2"); + byte[] fileBytes = fileUpload.getBytes(); + birthDetailsDto.setFileUpload(fileBytes); + //birthDetailsDto.setFileUpload(convertMultipartFileToBlob(fileUpload)); + System.out.println("Check 4"); + birthService.sendBirthDetail(birthDetailsDto); + return ResponseEntity.ok("Name Inclusion"); +} + + public Blob convertMultipartFileToBlob(MultipartFile file) throws Exception { + System.out.println("Check 3"); + byte[] fileContent = file.getBytes(); + return new SerialBlob(fileContent); + //return fileContent; + } + + + +// @PostMapping("/savebirth") +// public ResponseEntity saveBirth(@RequestBody BirthDetailsDto aa) { +// try { +// birthService.sendBirthDetails(aa); +// return ResponseEntity.ok("Birth details saved successfully."); +// } catch (Exception e) { +// e.printStackTrace(); +// return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body("Failed to save birth details."); +// } +// } +} diff --git a/src/main/java/com/bonton/kafka/kafkaConfig.java b/src/main/java/com/bonton/kafka/kafkaConfig.java new file mode 100644 index 0000000..06a6c97 --- /dev/null +++ b/src/main/java/com/bonton/kafka/kafkaConfig.java @@ -0,0 +1,46 @@ +package com.bonton.kafka; + +import java.util.HashMap; +import java.util.Map; + +import org.apache.kafka.clients.producer.ProducerConfig; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.Configuration; +import org.springframework.kafka.core.DefaultKafkaProducerFactory; +import org.springframework.kafka.core.KafkaTemplate; +import org.springframework.kafka.core.ProducerFactory; +import org.springframework.kafka.support.serializer.JsonSerializer; + +import com.fasterxml.jackson.databind.JsonSerializable; + +import com.fasterxml.jackson.databind.ser.std.StringSerializer; + + + +@Configuration +public class kafkaConfig { + + @Bean//2 + public ProducerFactory producerFactory() { + return new DefaultKafkaProducerFactory<>(producerConfigs()); + } + + + @Bean//1 + public Map producerConfigs(){ + Map props=new HashMap(); + props.put(ProducerConfig.BOOTSTRAP_SERVERS_CONFIG, "localhost:9092"); + props.put(ProducerConfig.KEY_SERIALIZER_CLASS_CONFIG, org.apache.kafka.common.serialization.StringSerializer.class); + props.put(ProducerConfig.VALUE_SERIALIZER_CLASS_CONFIG, JsonSerializer.class); + + return props; + + } + + @Bean//3 + public KafkaTemplate kafkaTemplate() { + + return new KafkaTemplate<>(producerFactory()); + } + +} diff --git a/src/main/java/com/bonton/kafka/service/BirthService.java b/src/main/java/com/bonton/kafka/service/BirthService.java new file mode 100644 index 0000000..eadeb75 --- /dev/null +++ b/src/main/java/com/bonton/kafka/service/BirthService.java @@ -0,0 +1,91 @@ +package com.bonton.kafka.service; + + +import com.bonton.kafka.dto.BirthDetailsDto; +import org.slf4j.LoggerFactory; +import org.slf4j.Logger; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.kafka.core.KafkaTemplate; +import org.springframework.kafka.support.SendResult; +import org.springframework.stereotype.Service; + +import java.util.UUID; +import java.util.concurrent.CompletableFuture; + + +@Service +public class BirthService { + + private static final Logger log = LoggerFactory.getLogger(BirthService.class); + + private final KafkaTemplate kafkaTemplate; + + @Autowired + public BirthService(KafkaTemplate kafkaTemplate) { + this.kafkaTemplate = kafkaTemplate; + } + +// public void sendBirthDetail(BirthDetailsDto aa) { +// if (aa != null && aa.getStatus() != null) { +// if (aa.getStatus().equalsIgnoreCase("NEW")) { +// aa.setUuid(getUuid()); +// } else if (aa.getStatus().equalsIgnoreCase("UPDATE")) { +// aa.setUuid(aa.getUuid()); +// } +// } +// CompletableFuture> send = kafkaTemplate.send("birth1", aa); +// } +//public void sendBirthDetail(BirthDetailsDto aa) { +// if (aa != null && aa.getStatus() != null) { // Ensure aa and status are not null +// if (aa.getStatus().equalsIgnoreCase("NEW")) { +// aa.setUuid(getUuid()); // Generate UUID for NEW status +// } else if (aa.getStatus().equalsIgnoreCase("UPDATE")) { +// aa.setUuid("111"); // Set fixed UUID for UPDATE status +// } +// } +// +// CompletableFuture> send = kafkaTemplate.send("birth1", aa); +//} + + +// public void sendBirthDetail(BirthDetailsDto aa) { +// String status = aa.getStatus(); +// +// if ("NEW".equalsIgnoreCase(status)) { // Null-safe comparison +// aa.setUuid(getUuid()); +// } else if ("UPDATE".equalsIgnoreCase(status)) { // Null-safe comparison +// aa.setUuid("111"); +// } +// +// CompletableFuture> send = kafkaTemplate.send("birth1", aa); +// +// } + + +// public String getUuid(){ +// final String uuid = UUID.randomUUID().toString().replace("-",""); +// System.out.println("UUID : "+uuid); +// return uuid; +// } + + + public void sendBirthDetail(BirthDetailsDto aa) { + if (aa != null && aa.getStatus() != null) { + System.out.println("Check 5"); + if (aa.getStatus().equalsIgnoreCase("NEW")) { + aa.setUuid(getUuid()); + } +// } else if (aa.getStatus().equalsIgnoreCase("UPDATE")) { +// aa.setUuid(aa.getUuid()); +// } + } + CompletableFuture> send = kafkaTemplate.send("birth1", aa); + } + + public String getUuid(){ + final String uuid = UUID.randomUUID().toString().replace("-", ""); + System.out.println("UUID : " + uuid); + return uuid; + } + +} diff --git a/src/main/java/com/bonton/kafka/utility/FileService.java b/src/main/java/com/bonton/kafka/utility/FileService.java new file mode 100644 index 0000000..76347a7 --- /dev/null +++ b/src/main/java/com/bonton/kafka/utility/FileService.java @@ -0,0 +1,13 @@ +//package com.bonton.kafka.utility; +//import org.springframework.web.multipart.MultipartFile; +// +//import javax.sql.rowset.serial.SerialBlob; +//import java.sql.Blob; +// +//public class FileService { +// public Blob convertMultipartFileToBlob(MultipartFile file) throws Exception { +// System.out.println("Check 3"); +// byte[] fileContent = file.getBytes(); +// return new SerialBlob(fileContent); +// } +//} diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties new file mode 100644 index 0000000..0adec5c --- /dev/null +++ b/src/main/resources/application.properties @@ -0,0 +1,8 @@ +spring.application.name=kafka +server.port=9099 +eureka.client.register-with-eureka= true +eureka.client.fetch-registry= true +eureka.client.service-url.defaultZone= http://localhost:8761/eureka/ +eureka.client.service-url.instance.hostname = localhost + + diff --git a/src/test/java/com/bonton/kafka/KafkaApplicationTests.java b/src/test/java/com/bonton/kafka/KafkaApplicationTests.java new file mode 100644 index 0000000..0e9a0c3 --- /dev/null +++ b/src/test/java/com/bonton/kafka/KafkaApplicationTests.java @@ -0,0 +1,13 @@ +package com.bonton.kafka; + +import org.junit.jupiter.api.Test; +import org.springframework.boot.test.context.SpringBootTest; + +@SpringBootTest +class KafkaApplicationTests { + + @Test + void contextLoads() { + } + +} diff --git a/target/classes/application.properties b/target/classes/application.properties new file mode 100644 index 0000000..0adec5c --- /dev/null +++ b/target/classes/application.properties @@ -0,0 +1,8 @@ +spring.application.name=kafka +server.port=9099 +eureka.client.register-with-eureka= true +eureka.client.fetch-registry= true +eureka.client.service-url.defaultZone= http://localhost:8761/eureka/ +eureka.client.service-url.instance.hostname = localhost + + diff --git a/target/classes/com/bonton/kafka/DtoForBirth.class b/target/classes/com/bonton/kafka/DtoForBirth.class new file mode 100644 index 0000000..4e57b38 Binary files /dev/null and b/target/classes/com/bonton/kafka/DtoForBirth.class differ diff --git a/target/classes/com/bonton/kafka/KafkaApplication.class b/target/classes/com/bonton/kafka/KafkaApplication.class new file mode 100644 index 0000000..837900a Binary files /dev/null and b/target/classes/com/bonton/kafka/KafkaApplication.class differ diff --git a/target/classes/com/bonton/kafka/KafkaProducerService.class b/target/classes/com/bonton/kafka/KafkaProducerService.class new file mode 100644 index 0000000..fb52701 Binary files /dev/null and b/target/classes/com/bonton/kafka/KafkaProducerService.class differ diff --git a/target/classes/com/bonton/kafka/configuration/BirthServiceConfig.class b/target/classes/com/bonton/kafka/configuration/BirthServiceConfig.class new file mode 100644 index 0000000..8a0ef13 Binary files /dev/null and b/target/classes/com/bonton/kafka/configuration/BirthServiceConfig.class differ diff --git a/target/classes/com/bonton/kafka/dto/BirthDetailsDto.class b/target/classes/com/bonton/kafka/dto/BirthDetailsDto.class new file mode 100644 index 0000000..075bdc4 Binary files /dev/null and b/target/classes/com/bonton/kafka/dto/BirthDetailsDto.class differ diff --git a/target/classes/com/bonton/kafka/entering.class b/target/classes/com/bonton/kafka/entering.class new file mode 100644 index 0000000..784a76c Binary files /dev/null and b/target/classes/com/bonton/kafka/entering.class differ diff --git a/target/classes/com/bonton/kafka/kafkaConfig.class b/target/classes/com/bonton/kafka/kafkaConfig.class new file mode 100644 index 0000000..d89fe24 Binary files /dev/null and b/target/classes/com/bonton/kafka/kafkaConfig.class differ diff --git a/target/classes/com/bonton/kafka/service/BirthService.class b/target/classes/com/bonton/kafka/service/BirthService.class new file mode 100644 index 0000000..82d29da Binary files /dev/null and b/target/classes/com/bonton/kafka/service/BirthService.class differ