You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@airavata.apache.org by "Lahiru Gunathilake (JIRA)" <ji...@apache.org> on 2011/09/12 23:21:10 UTC
[jira] [Resolved] (AIRAVATA-98) Sonar issues: Issues reported for
GFac-core
[ https://issues.apache.org/jira/browse/AIRAVATA-98?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Lahiru Gunathilake resolved AIRAVATA-98.
----------------------------------------
Resolution: Fixed
Patch verfied and applied ... ! Thanks Saminda for the patch.
> Sonar issues: Issues reported for GFac-core
> -------------------------------------------
>
> Key: AIRAVATA-98
> URL: https://issues.apache.org/jira/browse/AIRAVATA-98
> Project: Airavata
> Issue Type: Bug
> Reporter: Saminda Wijeratne
> Priority: Critical
> Attachments: AIRAVATA-98.patch
>
>
> org.apache.airavata.core.gfac.notification.impl.WorkflowTrackingNotification
> 1. Unread field: org.apache.airavata.core.gfac.notification.impl.WorkflowTrackingNotification.receiver
> 77 this.receiver = this.notifier.createEntity(receiverWorkflowID, receiverServiceID, receiverWorkflowNodeID,
> org.apache.airavata.core.gfac.context.security.impl.utils.MyProxyManager
> 1. Redundant nullcheck of proxyloc which is known to be null in org.apache.airavata.core.gfac.context.security.impl.utils.MyProxyManager.renewProxy()
> 84 if (proxyloc == null) {
> 2. org.apache.airavata.core.gfac.context.security.impl.utils.MyProxyManager.renewProxy() may fail to close stream on exception
> 101 FileOutputStream fout = new FileOutputStream(proxyfile);
> 3. A method/constructor shouldn't explicitly throw java.lang.Exception
> 73 public GSSCredential renewProxy() throws Exception {
> 4. Expression can be simplified.
> 91 if (proxyfile.exists() == false) {
> 94 if (dir.exists() == false) {
> 5. org.apache.airavata.core.gfac.context.security.impl.utils.MyProxyManager.renewProxy() ignores exceptional return value of java.io.File.mkdirs()
> 98 proxyfile.createNewFile();
> org.apache.airavata.core.gfac.provider.utils.JobSubmissionListener
> 1. Variable 'log' must be private and have accessor methods.
> 48 protected final Logger log = LoggerFactory.getLogger(JobSubmissionListener.class);
> 2. Avoid using if statements without curly braces
> 83 if (setStatus(job.getStatus(), job.getError()))
> 84 break;
> 3. Magic Number
> 67 if (proxyExpTime < 900) {
> 93 wait(60 * 1000l);
> org.apache.airavata.core.gfac.provider.SSHProvider
> 1. Dead store to host in org.apache.airavata.core.gfac.provider.SSHProvider.setupEnvironment(InvocationContext)
> 150 HostDescription host = context.getExecutionDescription().getHost();
> 2. 'command' hides a field.
> 114 StringBuilder command = new StringBuilder();
> 3. org.apache.airavata.core.gfac.provider.SSHProvider.retrieveOutput(InvocationContext) ignores exceptional return value of java.io.File.mkdir()
> 272 logDir.mkdir();
> 4. Redundant throws: 'SecurityException' is unchecked exception.
> 71 private void initSSHSecurity(InvocationContext context, SSHClient ssh) throws SecurityException, IOException {
> 5. Magic Number
> 128 cmd.join(5, TimeUnit.SECONDS);
> 220 cmd.join(5, TimeUnit.SECONDS);
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira