A Microservice to upload file.
mvn clean packagemvn package dockerfile:build- Run kafka in local(optional) localhost:9092 - default kafka
For additional kafka command details click here
- start the application
- through dockerImage itself.
- importing the project and running through ide.
- For Maven profile(pom.xml) change the DEVELOPMENT as active instead of TEST profile.
<activation>
<activeByDefault>true</activeByDefault>
</activation>- For more information related to application.
http://localhost:8080/app/service/actuator- h2 db embedded console can be found on below url.
http://localhost:8080/app/service/h2-console- File Uploader post upload url.
http://localhost:8080/app/service/filestore
body:
{
"charSet":"UTF-8",
"correlationId":"123",
"fileContent":"odia",
"fileName":"somesh.txt",
"fileTypeCode":"ABC",
"submitterEmail":"[email protected]",
"fieldSeparator":","
}- File Uploader get url.
localhost:8080/app/service/findbyId/<ref-id>-
After file successfully Uploaded we will see a Message on kafka topic fileUploaded-notify
-
File Status Consumer Message template on topic filestatus
{
"eventName":null,
"eventDate":"2020-11-13T07:32:46.869779Z",
"fileLocation":"88e437117577455a9d90049cab1d69a7",
"fileName":"somesh.txt",
"fileTypeCode":"ResultType",
"status":"PROCESSED",
"serviceName":"FileUploaderConsumer"
}
- Contributions guideline- Please read Contribution.md