You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by sh...@apache.org on 2016/03/18 18:28:36 UTC
[1/2] airavata git commit: Added monitoring module
Repository: airavata
Updated Branches:
refs/heads/master 63d742bdc -> c11667b71
Added monitoring module
Project: http://git-wip-us.apache.org/repos/asf/airavata/repo
Commit: http://git-wip-us.apache.org/repos/asf/airavata/commit/49e962d8
Tree: http://git-wip-us.apache.org/repos/asf/airavata/tree/49e962d8
Diff: http://git-wip-us.apache.org/repos/asf/airavata/diff/49e962d8
Branch: refs/heads/master
Commit: 49e962d8f9fe7ebfe7777d629409430835cf9a65
Parents: 63d742b
Author: Shameera Rathnayaka <sh...@gmail.com>
Authored: Thu Mar 17 16:33:39 2016 -0400
Committer: Shameera Rathnayaka <sh...@gmail.com>
Committed: Thu Mar 17 16:33:39 2016 -0400
----------------------------------------------------------------------
modules/monitoring/pom.xml | 19 ++++++++++++++++
.../org/apache/airavata/monitoring/Main.java | 24 ++++++++++++++++++++
pom.xml | 1 +
3 files changed, 44 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/airavata/blob/49e962d8/modules/monitoring/pom.xml
----------------------------------------------------------------------
diff --git a/modules/monitoring/pom.xml b/modules/monitoring/pom.xml
new file mode 100644
index 0000000..c37e0a8
--- /dev/null
+++ b/modules/monitoring/pom.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+ <parent>
+ <groupId>org.apache.airavata</groupId>
+ <artifactId>airavata</artifactId>
+ <version>0.16-SNAPSHOT</version>
+ <relativePath>../../pom.xml</relativePath>
+ </parent>
+
+ <modelVersion>4.0.0</modelVersion>
+ <artifactId>airavata-monitoring</artifactId>
+ <packaging>jar</packaging>
+ <name>Airavata Monitoring</name>
+ <url>http://airavata.apache.org/</url>
+
+</project>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/airavata/blob/49e962d8/modules/monitoring/src/main/java/org/apache/airavata/monitoring/Main.java
----------------------------------------------------------------------
diff --git a/modules/monitoring/src/main/java/org/apache/airavata/monitoring/Main.java b/modules/monitoring/src/main/java/org/apache/airavata/monitoring/Main.java
new file mode 100644
index 0000000..355bb43
--- /dev/null
+++ b/modules/monitoring/src/main/java/org/apache/airavata/monitoring/Main.java
@@ -0,0 +1,24 @@
+/*
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+ */
+package org.apache.airavata.monitoring;
+
+public class Main {
+}
http://git-wip-us.apache.org/repos/asf/airavata/blob/49e962d8/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index e41e3f1..2a44091 100644
--- a/pom.xml
+++ b/pom.xml
@@ -556,6 +556,7 @@
<module>modules/security</module>
<module>modules/credential-store</module>
<module>modules/orchestrator</module>
+ <module>modules/monitoring</module>
<module>modules/server</module>
<module>modules/workflow</module>
<module>modules/test-suite</module>
[2/2] airavata git commit: Create new session if previous connection
is closed
Posted by sh...@apache.org.
Create new session if previous connection is closed
Project: http://git-wip-us.apache.org/repos/asf/airavata/repo
Commit: http://git-wip-us.apache.org/repos/asf/airavata/commit/c11667b7
Tree: http://git-wip-us.apache.org/repos/asf/airavata/tree/c11667b7
Diff: http://git-wip-us.apache.org/repos/asf/airavata/diff/c11667b7
Branch: refs/heads/master
Commit: c11667b716ebef85c2153cd3f3113f30d91d4b22
Parents: 49e962d
Author: Shameera Rathnayaka <sh...@gmail.com>
Authored: Fri Mar 18 11:23:36 2016 -0400
Committer: Shameera Rathnayaka <sh...@gmail.com>
Committed: Fri Mar 18 11:23:36 2016 -0400
----------------------------------------------------------------------
.../src/main/java/org/apache/airavata/gfac/impl/Factory.java | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/airavata/blob/c11667b7/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/Factory.java
----------------------------------------------------------------------
diff --git a/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/Factory.java b/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/Factory.java
index 7b01ffe..c04de11 100644
--- a/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/Factory.java
+++ b/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/Factory.java
@@ -422,7 +422,8 @@ public abstract class Factory {
public static Session getSSHSession(AuthenticationInfo authenticationInfo, ServerInfo serverInfo) throws AiravataException {
SSHKeyAuthentication authentication = null;
String key = serverInfo.getUserName() + "_" + serverInfo.getHost() + "_" + serverInfo.getPort();
- if (sessionMap.get(key) == null) {
+ Session session = sessionMap.get(key);
+ if (session == null || !session.isConnected()) {
try {
if (authenticationInfo instanceof SSHKeyAuthentication) {
authentication = (SSHKeyAuthentication) authenticationInfo;
@@ -432,7 +433,7 @@ public abstract class Factory {
JSch jSch = new JSch();
jSch.addIdentity(UUID.randomUUID().toString(), authentication.getPrivateKey(), authentication.getPublicKey(),
authentication.getPassphrase().getBytes());
- Session session = jSch.getSession(serverInfo.getUserName(), serverInfo.getHost(),
+ session = jSch.getSession(serverInfo.getUserName(), serverInfo.getHost(),
serverInfo.getPort());
session.setUserInfo(new DefaultUserInfo(serverInfo.getUserName(), null, authentication.getPassphrase()));
if (authentication.getStrictHostKeyChecking().equals("yes")) {