Commit Graph

51 Commits

Author SHA1 Message Date
6a8297598e #1047 remove module infos 2020-08-01 15:19:09 +03:00
417f21ed3d Code cleanup (#1461)
* Code cleanup

* Fix flux tests

* Fix checkstyle errors

* Fix compile error
2020-07-30 20:28:47 +03:00
76fb9aff8b #590 add explanation for Dao 2020-07-18 10:22:43 +03:00
4e01ca39fd Organised below design patterns into modules: (#1182)
1. Converter
2. Dao
2020-03-07 11:22:55 +00:00
ea57934db6 Java 11 migrate c-d (remaining) (#1111)
* Moves converter pattern to Java 11

* Moves cqrs pattern to Java 11

* Moves dao pattern to Java 11

* Moves data-bus pattern to Java 11

* Moves data-locality pattern to Java 11

* Moves data-mapper pattern to Java 11

* Moves data-transfer-object pattern to Java 11

* Moves decorator pattern to Java 11

* Moves delegation pattern to Java 11

* Moves dependency-injection to Java 11

* Moves dirty-flag to Java 11

* Moves double-buffer to Java 11

* Moves double-checked-locking to Java 11

* Moves double-dispatch to Java 11

* Corrects with changes thats breaking test cases
2019-12-14 20:32:45 +02:00
01e489c77b Resolves checkstyle errors for dao data-bus data-locality data-mapper data-transfer-object decorator (#1067)
* Reduces checkstyle errors in dao

* Reduces checkstyle errors in data-bus

* Reduces checkstyle errors in data-locality

* Reduces checkstyle errors in data-mapper

* Reduces checkstyle errors in data-transfer-object

* Reduces checkstyle errors in decorator
2019-11-10 19:27:09 +02:00
6bb3438965 Add java 11 (#1049) 2019-10-27 22:08:09 +02:00
4904d7eea0 #1021: Fix checkstyle warnings by changing the license header template (#1027)
* Add custom license header style in order to comply with Google's Checkstyle format

* Update license headers to comply with Google's Checkstyle format
2019-10-22 08:15:35 +03:00
cfdfedbd2e #970 single logging framework should be enforced (#982)
* #496 Add pipeline module to parent pom 

* #496: Add main application class and test for pipeline

* #496: Checkstyle format and add log messages on pipeline stages 🎨

* #496: Fill readme sections of pipeline 

* #496: Javadocs and checkstyle formatting 🎨

* #496: Follow PMD checks and add more explanation as block comment on App.java

* #496: Apply requested PR changes by iluwatar 🎨

* #970: Replace log4j usage on commander pattern to Slf4j API 🎨

* #970: Replace log4j usage on dao pattern to Slf4j API 🎨

* #970: Replace log4j usage on data mapper pattern to Slf4j API 🎨

* #970: Remove log4j dependency on data transfer object pom 🔥

* #970: Replace log4j usage on module pattern to Slf4j API 🎨

* #970: Replace log4j usage on serverless pattern to Slf4j API 🎨

This also removes the aws log4j dependency

* #970: Remove unnecessary gitignore line for log4j.xml 🔥

* #970: Remove remaining remnants of log4j 🔥

* #970: Replace System.out logging with appropriate logging methods 🎨

* #970: Replace System.out method references to Logger::info 🎨
2019-10-13 23:41:11 +03:00
9ebbc421dd Update license headers 2019-10-12 20:05:54 +03:00
c6ecf58687 508 : sonar qube critical issue fixes (#852)
* 508 : sonar qube critical issue fixes

* 508 : Sunar Qube Fixes
Define a constant instead of duplicating this literal "user_accounts" 4 times.
Define a constant instead of duplicating this literal "userID" 5 times
Define a constant instead of duplicating this literal "additionalInfo" 4 times.
Define a constant instead of duplicating this literal "userName" 4 times.

* 508 : Sunar Qube Fixes
Define a constant instead of duplicating this literal "user_accounts" 4 times.

* 508 : Sonar Qube Fixes
Define a constant instead of duplicating this literal "eEvans" 4 times
Define a constant instead of duplicating this literal "jBloch" 6 times
Define a constant instead of duplicating this literal "mFowler" 3 times

* 508 : Sonar Qube FIxes
Define a constant instead of duplicating this literal "username" 3 times.

* 508: sonar qube issue fixes
Define a constant instead of duplicating this literal "customerDao.getAllCustomers(): " 4 times.

* 508 : sonar qube issue fixes
Define a constant instead of duplicating this literal "App.main(), student : " 4 times.

* 508 : sonar Qube issue fixes
Define a constant instead of duplicating this literal "{} hits {}. {} is damaged!" 3 times.
Define a constant instead of duplicating this literal "{} hits {}." 4 times.

* 508 : Define a constant instead of duplicating this literal "{} hits {}." 4 times.

* 508 : checkstyle fixes

* 508: checkstyle fixes

* 508: checkstyle fixes

* 508: checkstyle fixes

* 508: checkstyle fixes

* 508: checkstyle fixes

* 508: cqrs checkstyle fixes
2019-07-28 15:39:40 +03:00
2aa9e78ddd Minor refactorings and code style changes (#807)
* Made minor changes in some patterns such as removed throws clause where not needed, changed incorrect order of arguments in assertEquals

* Minor refactorings and code style changes. 1) Removed several use of raw types 2) Removed unnecessary throws clauses 3) Used lambda expressions wherever applicable 4) Used apt assertion methods for readability 5) Use of try with resources wherever applicable 6) Corrected incorrect order of assertXXX arguments

* Removed unused import from Promise

* Addressed review comments

* Addressed checkstyle issue
2018-10-23 13:45:41 +05:30
991ba320a6 Improve Javadoc 2018-02-19 22:01:14 +08:00
0306161380 Cleanup commented code 2018-01-02 09:24:18 +09:00
6694d742a3 Migrate to JUnit5 2017-12-31 16:29:48 +09:00
e9579633da #587 SonarQube reports bugs in dao module 2017-09-15 17:39:01 -04:00
a1a4088087 As getAll method returns a Stream, we cannot close the involved
resources (Connection, Statement and resultSet) until the stream is
closed by the consumer. So try-with-resources is not an option as per
sonarqube’s recommendation. But it is still recommended to close
statement and result set. When connection pool used, connection is not
closed when close() called. It is just returned to the pool.

Using //NOSONAR to avoid false blocker issue.
2017-08-13 10:19:48 -04:00
09585c3874 Removed AvoidStarImport Rule
Added JavaDocType Rule
2017-03-22 01:16:02 +08:00
6292690250 Changing constant interface pattern with a Noninstantiable class 2016-12-24 14:49:41 -07:00
faa29f8025 Update license headers 2016-11-27 14:34:20 +02:00
b72214da2f Fix H2 database path problem 2016-04-12 23:04:37 +03:00
ddbc61b140 Incorporated review changes - 1) Created sql file for central schema 2)
Changed getById return type to Optional
2016-03-28 11:55:22 +05:30
3f7ead5ca5 Work on #404, updated class diagram and javadoc. Passed checkstyle checks 2016-03-23 13:13:19 +05:30
fa077c8be9 Work on #404, javadocs and test cases for DB and in memory dao. 2016-03-21 17:55:29 +05:30
448d855809 implemented and added test cases for DB dao. Added dependency of Hierarchical junit runner in parent pom 2016-03-18 16:39:45 +05:30
f6a20c7693 Refactoring changes to DAO pattern. Renamed default dao implementation to InMemory and refined interface 2016-03-16 18:47:07 +05:30
bbd769b208 Merge pull request #386 from amitbhoraniya/master
Dao Pattern : Create object with reference to Interface
2016-02-20 18:34:47 +02:00
b70614efef Creating object with reference to Interface
In Dao pattern DaoImpl object is created with reference to dao interface.
2016-02-19 00:10:55 +05:30
f08af14555 Merge pull request #364 from DevFactory/release/The-diamond-operator-should-be-used-fix-1
squid:S2293 - The diamond operator should be used
2016-02-01 22:26:43 +02:00
59c32d3937 Add tests that run the examples 2016-01-31 12:09:09 +02:00
dc4f07eb81 Merge pull request #360 from mikulucky/MIT-Source
Pull Request for adding License Plugin and Generate #358
2016-01-30 15:10:42 +02:00
d24a12a9b2 Merge pull request #359 from DevFactory/release/Local-Variables-should-not-be-declared-and-then-immediately-returned-or-thrown-fix-1
squid:S1488 - Local Variables should not be declared and then immedia…
2016-01-30 14:42:05 +02:00
409ff027b8 squid:S2293 - The diamond operator should be used 2016-01-29 07:33:34 +02:00
3d95696078 #358 Added license to all files using plugin 2016-01-27 22:20:42 +00:00
4e40cc3888 squid:S1488 - Local Variables should not be declared and then immediately returned or thrown 2016-01-27 02:45:39 +02:00
d00bfae5ee pmd:ConsecutiveAppendsShouldReuse - Consecutive Appends Should Reuse 2016-01-26 19:58:45 +02:00
5f033be54f Fix PMD violations #327 2015-12-27 21:21:57 +02:00
cec9a99410 Adjust checkstyle rules. Make checkstyle fail the build when violations are found. Correct all current checkstyle violations. 2015-12-25 23:49:28 +02:00
043a610754 log4j.xml relocated due to visibility issues and excluded from generated
JAR. pom.xml formatted according to coding conventions
2015-11-13 18:34:10 +01:00
fe63c9cec4 Merge pull request #281 from ankurkaushal/master
Reformat according to google style guide
2015-11-02 21:39:17 +02:00
449340bd2b Reformat business-delegate, callback, chain, command, composite, dao, decorator & dependency-injection patterns. 2015-11-01 18:48:43 -05:00
25c1f87d46 Corrected Freddy's second name 2015-11-01 23:15:57 +01:00
339db2a0bf Merge branch 'master' of https://github.com/themoffster/java-design-patterns into themoffster-master
Conflicts:
	dao/pom.xml
2015-10-19 20:44:46 +03:00
621793ed2d Improved DAO Javadoc 2015-10-03 20:34:15 +03:00
d0af12b1ee Removed magic number. 2015-09-16 21:32:52 +01:00
51dca28fe7 Updated unit .equals() and .hashCode() methods
Formatted code using this formatter:
https://github.com/google/styleguide/blob/gh-pages/eclipse-java-google-style.xml
Removed argument final declaration on interface
Updated addCustomer logic for cases where the added customer already
exists
2015-09-14 21:22:33 +01:00
3da48d970c Inclusion of log4j dependency rather than relying on
System.out.println() statements.
Added unit tests for doa module.
2015-09-05 21:54:14 +01:00
3526d96e37 #107 Dao example JavaDoc 2015-08-18 22:08:18 +03:00
8524c75ba6 Changed package naming across all examples. 2015-05-31 11:55:18 +03:00
8055b9a414 Documentation change in DAO pattern
Issue: #53
Signed-off-by: Magesh Khanna Vadivelu <mvadivelu@turn.com>
2015-05-17 23:09:04 -07:00