clearing Sonar Blockers (#1633)

* update gitignore

.checkstyle files are being tracked which should not be

* NOSONAR for statement

excluded from SONAR analysis as it is already dealt using functional approach

https://sonarcloud.io/project/issues?id=iluwatar_java-design-patterns&issues=AW8FwRBhm8eoEVQR-x0f&open=AW8FwRBhm8eoEVQR-x0f

* achieved thread safety with lazy initialization

https://sonarcloud.io/project/issues?fileUuids=AXb6t0PKusn4P8Tm-LmM&id=iluwatar_java-design-patterns&open=AXb6t19yusn4P8Tm-Lmo&resolved=false

* remove double checked locking and initialize before using

https://sonarcloud.io/project/issues?fileUuids=AXb6t0PKusn4P8Tm-LmK&id=iluwatar_java-design-patterns&open=AXb6t19qusn4P8Tm-Lmk&resolved=false

* NOSONAR for the line

https://sonarcloud.io/project/issues?id=iluwatar_java-design-patterns&issues=AXPd3iSe46HRSze7cz3D&open=AXPd3iSe46HRSze7cz3D

Co-authored-by: Ilkka Seppälä <iluwatar@users.noreply.github.com>
This commit is contained in:
Subhrodip Mohanta
2021-01-27 19:54:06 +05:30
committed by GitHub
parent 9abfd5777c
commit 462b581b34
4 changed files with 11 additions and 18 deletions

View File

@ -67,7 +67,7 @@ public class DbCustomerDao implements CustomerDao {
public Stream<Customer> getAll() throws Exception {
try {
var connection = getConnection();
var statement = connection.prepareStatement("SELECT * FROM CUSTOMERS");
var statement = connection.prepareStatement("SELECT * FROM CUSTOMERS"); // NOSONAR
var resultSet = statement.executeQuery(); // NOSONAR
return StreamSupport.stream(new Spliterators.AbstractSpliterator<Customer>(Long.MAX_VALUE,
Spliterator.ORDERED) {