rhtyd commented on a change in pull request #2739: Async jobs add endtime
URL: https://github.com/apache/cloudstack/pull/2739#discussion_r202321858
 
 

 ##########
 File path: 
framework/jobs/src/main/java/org/apache/cloudstack/framework/jobs/impl/AsyncJobManagerImpl.java
 ##########
 @@ -1049,8 +1054,8 @@ public void 
doInTransactionWithoutResult(TransactionStatus status) {
                             }
                         }
                     }
-                    List<SnapshotDetailsVO> snapshotList = 
_snapshotDetailsDao.findDetails(AsyncJob.Constants.MS_ID, Long.toString(msid), 
false);
-                    for (SnapshotDetailsVO snapshotDetailsVO : snapshotList) {
+                    final List<SnapshotDetailsVO> snapshotList = 
_snapshotDetailsDao.findDetails(AsyncJob.Constants.MS_ID, Long.toString(msid), 
false);
 
 Review comment:
   I think it's a good defensive programming style to keep assignment 
restrictions unless needed.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to