Skip to content

add identity field pattern #1978

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 7 commits into from
Closed

add identity field pattern #1978

wants to merge 7 commits into from

Conversation

lkpengcs
Copy link

@lkpengcs lkpengcs commented Apr 4, 2022

In this pull request,

  • Add the identity field pattern
  • This is related to this issue

Pull request description

  • Implement the identity field pattern according to the given link.

For detailed contributing instructions see https://github.com/iluwatar/java-design-patterns/wiki/01.-How-to-contribute

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 2 Code Smells

96.3% 96.3% Coverage
0.0% 0.0% Duplication

@ohbus ohbus self-assigned this Jun 3, 2022
Copy link
Contributor

@ohbus ohbus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you so much for your efforts!

Can you please check the 2 code smells reported by Sonar?

Would love to have a perfect submission with full coverage analysis as well.

@sonarqubecloud
Copy link

sonarqubecloud bot commented Jun 6, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

96.3% 96.3% Coverage
0.0% 0.0% Duplication

@lkpengcs
Copy link
Author

lkpengcs commented Jun 6, 2022

hi, I have removed the code smells. As for the coverage, I can have full coverage locally. Not sure about how Sonar checks this.

@@ -0,0 +1,64 @@
---
layout: pattern
title: Identity-Field
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
title: Identity-Field
title: Identity Field

<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.18.22</version>
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use the version from the parent pom.xml

Comment on lines +33 to +54
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<configuration>
<archive>
<manifest>
<mainClass>com.test.MainClassName</mainClass>
</manifest>
</archive>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
</configuration>
<executions>
<execution>
<id>make-assembly</id>
<phase>package</phase> <!-- packaging phase -->
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The configuration seems overly verbose. Can you check how maven-assembly-plugin has been configured in the other patterns?

Comment on lines +55 to +62
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>8</source>
<target>8</target>
</configuration>
</plugin>
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be left out. Use the Java version that's coming from the parent pom.xml (11)

@iluwatar iluwatar self-assigned this Sep 25, 2022
@stale
Copy link

stale bot commented Oct 30, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the status: stale issues and pull requests that have not had recent interaction label Oct 30, 2022
@iluwatar iluwatar added this to the 1.26.0 milestone Nov 8, 2022
@iluwatar
Copy link
Owner

iluwatar commented Nov 8, 2022

Closed due to inactivity

@iluwatar iluwatar closed this Nov 8, 2022
@stale stale bot removed status: stale issues and pull requests that have not had recent interaction labels Nov 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants