Skip to content

samarchowdhury/POC

 
 

Repository files navigation

My POC Build Status Codecov License

Introduction

This repo is for all POC which I does and learnings I learnt Below are the projects that I have completed POC

Filing Issues

If you encounter any bug, please file an issue here.

To suggest a new feature or changes that could be made, file an issue the same way you would for a bug.

Pull Requests

Pull requests are welcome. To open your own pull request, click here. When creating a pull request, make sure you are pointing to the fork and branch that your changes were made in.

How to setup Project

This project is using lombok so you need to prepare your IDE as described here. After Setup import project as a maven project.

Jacoco

Code coverage is a software metric used to measure how many lines of our code are executed during automated tests. JaCoCo reports help you visually analyze code coverage by using diamonds with colors for branches and background colors for lines:

  • Red diamond means that no branches have been exercised during the test phase.

  • Yellow diamond shows that the code is partially covered – some branches have not been exercised.

  • Green diamond means that all branches have been exercised during the test. The same color code applies to the background color, but for lines coverage.

JaCoCo mainly provides three important metrics:

  • Lines coverage reflects the amount of code that has been exercised based on the number of Java byte code instructions called by the tests.

  • Branches coverage shows the percent of exercised branches in the code – typically related to if/else and switch statements.

  • Cyclomatic complexity reflects the complexity of code by giving the number of paths needed to cover all the possible paths in a code through linear combination. To take a trivial example, if there is no if or switch statements in the code, the cyclomatic complexity will be 1, as we only need one execution path to cover the entire code.

Generally the cyclomatic complexity reflects the number of test cases we need to implement in order to cover the entire code.

How to apply spring-formatter

To assign spring-formatter issue command after adding plugin to pom.xml

mvnw io.spring.javaformat:spring-javaformat-maven-plugin:apply

How to release a multi module project to git

Release using maven and git flow

  • git checkout -b release master(create branch release from master)

  • mvn --batch-mode release:prepare release:perform -DscmCommentPrefix="bumping versions" -DreleaseVersion=0.0.1 -DdevelopmentVersion=0.0.2-SNAPSHOT(sets comments, release version and development version)

  • git checkout master(get lastest master in local)

  • git merge --no-ff -m "Release Merge release into master" release (merge master with release/0.0.1 branch) or use git merge branchname

  • git branch -D release(delete branch release)

  • git push --all && git push --tags(push master and tags to repository)

  • mvn release:clean(deleted backupfiles from local env)

Commands to ensure that dependencies are upgraded

  • mvn versions:display-plugin-updates

  • mvn versions:display-property-updates

About

My POC's against various concepts

Resources

License

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages

  • Java 100.0%