You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@oodt.apache.org by ma...@apache.org on 2015/10/16 00:51:20 UTC

[1/7] oodt git commit: [maven-release-plugin] copy for tag 0.10-rc2

Repository: oodt
Updated Branches:
  refs/heads/master 0ea124183 -> c101b01da


[maven-release-plugin] copy for tag 0.10-rc2

git-svn-id: https://svn.apache.org/repos/asf/oodt/tags/0.10-rc2@1701320 13f79535-47bb-0310-9956-ffa450edef68


Project: http://git-wip-us.apache.org/repos/asf/oodt/repo
Commit: http://git-wip-us.apache.org/repos/asf/oodt/commit/c0e9e7e0
Tree: http://git-wip-us.apache.org/repos/asf/oodt/tree/c0e9e7e0
Diff: http://git-wip-us.apache.org/repos/asf/oodt/diff/c0e9e7e0

Branch: refs/heads/master
Commit: c0e9e7e041c8d5d89a44da228b75dc4f14b860a5
Parents: c7378fc
Author: Chris Mattmann <ma...@apache.org>
Authored: Fri Sep 4 19:46:49 2015 +0000
Committer: Chris Mattmann <ma...@apache.org>
Committed: Fri Sep 4 19:46:49 2015 +0000

----------------------------------------------------------------------

----------------------------------------------------------------------



[2/7] oodt git commit: Release Apache OODT 0.10 from RC2.

Posted by ma...@apache.org.
Release Apache OODT 0.10 from RC2.

git-svn-id: https://svn.apache.org/repos/asf/oodt/tags/0.10@1702809 13f79535-47bb-0310-9956-ffa450edef68


Project: http://git-wip-us.apache.org/repos/asf/oodt/repo
Commit: http://git-wip-us.apache.org/repos/asf/oodt/commit/988e58db
Tree: http://git-wip-us.apache.org/repos/asf/oodt/tree/988e58db
Diff: http://git-wip-us.apache.org/repos/asf/oodt/diff/988e58db

Branch: refs/heads/master
Commit: 988e58dbc94a679f24aced5d2b72fa6e161aa492
Parents: c0e9e7e
Author: Chris Mattmann <ma...@apache.org>
Authored: Sun Sep 13 19:40:39 2015 +0000
Committer: Chris Mattmann <ma...@apache.org>
Committed: Sun Sep 13 19:40:39 2015 +0000

----------------------------------------------------------------------

----------------------------------------------------------------------



[5/7] oodt git commit: OODT-755 clean up commit

Posted by ma...@apache.org.
OODT-755 clean up commit


Project: http://git-wip-us.apache.org/repos/asf/oodt/repo
Commit: http://git-wip-us.apache.org/repos/asf/oodt/commit/dbe3e022
Tree: http://git-wip-us.apache.org/repos/asf/oodt/tree/dbe3e022
Diff: http://git-wip-us.apache.org/repos/asf/oodt/diff/dbe3e022

Branch: refs/heads/master
Commit: dbe3e02203480f3d26106cb0d61a876896d4aa5d
Parents: c8804a9
Author: Tom Barber <to...@analytical-labs.com>
Authored: Thu Oct 15 22:11:26 2015 +0100
Committer: Tom Barber <to...@analytical-labs.com>
Committed: Thu Oct 15 22:11:26 2015 +0100

----------------------------------------------------------------------
 .../cas/filemgr/system/XmlRpcFileManager.java   | 34 +++++++++++++++-----
 .../filemgr/system/XmlRpcFileManagerClient.java | 26 +++++++++++----
 2 files changed, 45 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/oodt/blob/dbe3e022/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
----------------------------------------------------------------------
diff --git a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
index f22ab6c..b7370c1 100644
--- a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
+++ b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
@@ -17,7 +17,6 @@
 
 package org.apache.oodt.cas.filemgr.system;
 
-//APACHE imports
 import com.google.common.collect.Lists;
 
 import org.apache.oodt.cas.filemgr.catalog.Catalog;
@@ -26,8 +25,20 @@ import org.apache.oodt.cas.filemgr.datatransfer.TransferStatusTracker;
 import org.apache.oodt.cas.filemgr.metadata.ProductMetKeys;
 import org.apache.oodt.cas.filemgr.metadata.extractors.FilemgrMetExtractor;
 import org.apache.oodt.cas.filemgr.repository.RepositoryManager;
-import org.apache.oodt.cas.filemgr.structs.*;
-import org.apache.oodt.cas.filemgr.structs.exceptions.*;
+import org.apache.oodt.cas.filemgr.structs.Element;
+import org.apache.oodt.cas.filemgr.structs.ExtractorSpec;
+import org.apache.oodt.cas.filemgr.structs.FileTransferStatus;
+import org.apache.oodt.cas.filemgr.structs.Product;
+import org.apache.oodt.cas.filemgr.structs.ProductPage;
+import org.apache.oodt.cas.filemgr.structs.ProductType;
+import org.apache.oodt.cas.filemgr.structs.Query;
+import org.apache.oodt.cas.filemgr.structs.Reference;
+import org.apache.oodt.cas.filemgr.structs.exceptions.CatalogException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.DataTransferException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.QueryFormulationException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.RepositoryManagerException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.ValidationLayerException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.VersioningException;
 import org.apache.oodt.cas.filemgr.structs.query.ComplexQuery;
 import org.apache.oodt.cas.filemgr.structs.query.QueryFilter;
 import org.apache.oodt.cas.filemgr.structs.query.QueryResult;
@@ -44,16 +55,23 @@ import org.apache.oodt.cas.metadata.exceptions.MetExtractionException;
 import org.apache.oodt.commons.date.DateUtils;
 import org.apache.xmlrpc.WebServer;
 
-import java.io.*;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.FileOutputStream;
+import java.io.IOException;
 import java.net.URI;
 import java.net.URISyntaxException;
 import java.net.URL;
-import java.util.*;
+import java.util.Arrays;
+import java.util.Hashtable;
+import java.util.Iterator;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Vector;
 import java.util.logging.Level;
 import java.util.logging.Logger;
 
-//OODT imports
-//JDK imports
 
 /**
  * @author mattmann
@@ -683,7 +701,7 @@ public class XmlRpcFileManager {
     public String ingestProduct(Hashtable<String, Object> productHash,
       Hashtable<String, String> metadata, boolean clientTransfer)
       throws VersioningException, RepositoryManagerException,
-      DataTransferException, CatalogException {
+        DataTransferException, CatalogException {
 
     Product p = XmlRpcStructFactory.getProductFromXmlRpc(productHash);
 

http://git-wip-us.apache.org/repos/asf/oodt/blob/dbe3e022/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java
----------------------------------------------------------------------
diff --git a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java
index c26eaec..832c4af 100644
--- a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java
+++ b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java
@@ -17,22 +17,37 @@
 
 package org.apache.oodt.cas.filemgr.system;
 
-//APACHE imports
 import org.apache.commons.httpclient.HttpClient;
 import org.apache.commons.httpclient.HttpMethod;
 import org.apache.commons.httpclient.HttpMethodRetryHandler;
 import org.apache.commons.httpclient.params.HttpMethodParams;
 import org.apache.oodt.cas.cli.CmdLineUtility;
 import org.apache.oodt.cas.filemgr.datatransfer.DataTransfer;
-import org.apache.oodt.cas.filemgr.structs.*;
-import org.apache.oodt.cas.filemgr.structs.exceptions.*;
+import org.apache.oodt.cas.filemgr.structs.Element;
+import org.apache.oodt.cas.filemgr.structs.FileTransferStatus;
+import org.apache.oodt.cas.filemgr.structs.Product;
+import org.apache.oodt.cas.filemgr.structs.ProductPage;
+import org.apache.oodt.cas.filemgr.structs.ProductType;
+import org.apache.oodt.cas.filemgr.structs.Query;
+import org.apache.oodt.cas.filemgr.structs.Reference;
+import org.apache.oodt.cas.filemgr.structs.exceptions.CatalogException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.ConnectionException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.DataTransferException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.RepositoryManagerException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.ValidationLayerException;
+import org.apache.oodt.cas.filemgr.structs.exceptions.VersioningException;
 import org.apache.oodt.cas.filemgr.structs.query.ComplexQuery;
 import org.apache.oodt.cas.filemgr.structs.query.QueryResult;
 import org.apache.oodt.cas.filemgr.util.GenericFileManagerObjectFactory;
 import org.apache.oodt.cas.filemgr.util.XmlRpcStructFactory;
 import org.apache.oodt.cas.filemgr.versioning.Versioner;
 import org.apache.oodt.cas.metadata.Metadata;
-import org.apache.xmlrpc.*;
+import org.apache.xmlrpc.CommonsXmlRpcTransport;
+import org.apache.xmlrpc.XmlRpcClient;
+import org.apache.xmlrpc.XmlRpcClientException;
+import org.apache.xmlrpc.XmlRpcException;
+import org.apache.xmlrpc.XmlRpcTransport;
+import org.apache.xmlrpc.XmlRpcTransportFactory;
 
 import java.io.File;
 import java.io.FileInputStream;
@@ -44,8 +59,6 @@ import java.util.Vector;
 import java.util.logging.Level;
 import java.util.logging.Logger;
 
-//JDK imports
-//OODT imports
 
 /**
  * @author mattmann (Chris Mattmann)
@@ -1287,7 +1300,6 @@ public class XmlRpcFileManagerClient {
           throw new Exception(e2);
         }
         catch (Exception e) {
-            //e.printStackTrace();
           LOG.log(Level.SEVERE, "Failed to ingest product [ id: " + product.getProductId() +
                                 "/ name:" +product.getProductName() + "] :" + e.getMessage() + " -- rolling back ingest");
             try {


[6/7] oodt git commit: OODT-755 fix merge

Posted by ma...@apache.org.
OODT-755 fix merge


Project: http://git-wip-us.apache.org/repos/asf/oodt/repo
Commit: http://git-wip-us.apache.org/repos/asf/oodt/commit/6567c85f
Tree: http://git-wip-us.apache.org/repos/asf/oodt/tree/6567c85f
Diff: http://git-wip-us.apache.org/repos/asf/oodt/diff/6567c85f

Branch: refs/heads/master
Commit: 6567c85fb74254d474b71723d5541b438a2cd399
Parents: 0ea1241 dbe3e02
Author: Tom Barber <to...@analytical-labs.com>
Authored: Thu Oct 15 23:49:23 2015 +0100
Committer: Tom Barber <to...@analytical-labs.com>
Committed: Thu Oct 15 23:49:23 2015 +0100

----------------------------------------------------------------------
 .../cas/filemgr/system/XmlRpcFileManager.java   | 43 ++++++++---
 .../filemgr/system/XmlRpcFileManagerClient.java | 78 +++++++++++---------
 2 files changed, 79 insertions(+), 42 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/oodt/blob/6567c85f/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
----------------------------------------------------------------------
diff --cc filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
index 9cdd3f9,b7370c1..0af87b0
--- a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
+++ b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
@@@ -17,7 -17,6 +17,7 @@@
  
  package org.apache.oodt.cas.filemgr.system;
  
- //APACHE imports
++
  import com.google.common.collect.Lists;
  
  import org.apache.oodt.cas.filemgr.catalog.Catalog;


[4/7] oodt git commit: OODT-755 fix exception

Posted by ma...@apache.org.
OODT-755 fix exception


Project: http://git-wip-us.apache.org/repos/asf/oodt/repo
Commit: http://git-wip-us.apache.org/repos/asf/oodt/commit/c8804a9b
Tree: http://git-wip-us.apache.org/repos/asf/oodt/tree/c8804a9b
Diff: http://git-wip-us.apache.org/repos/asf/oodt/diff/c8804a9b

Branch: refs/heads/master
Commit: c8804a9b15186704ed891e006b7b1155eb6f1904
Parents: 3ecdfb9
Author: Tom Barber <to...@analytical-labs.com>
Authored: Thu Oct 15 17:27:29 2015 +0100
Committer: Tom Barber <to...@analytical-labs.com>
Committed: Thu Oct 15 17:27:29 2015 +0100

----------------------------------------------------------------------
 .../org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java   | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/oodt/blob/c8804a9b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
----------------------------------------------------------------------
diff --git a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
index e3c4bcf..f22ab6c 100644
--- a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
+++ b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
@@ -1060,12 +1060,13 @@ public class XmlRpcFileManager {
         return metadata;
     }
 
-    private Metadata runExtractors(Product product, Metadata metadata) {
+    private Metadata runExtractors(Product product, Metadata metadata) throws CatalogException {
         // make sure that the product type definition is present
         if(product.getProductType() == null){
           LOG.log(Level.SEVERE, "Failed to run extractor for: "+product.getProductId()+":"+product
               .getProductName()+" product type cannot be null.");
-          return null;
+          throw new CatalogException("Failed to run extractor for: "+product.getProductId()+":"+product
+              .getProductName()+" product type cannot be null.");
         }
         try {
             product.setProductType(repositoryManager.getProductTypeById(product


[3/7] oodt git commit: OODT-775 fix error message

Posted by ma...@apache.org.
OODT-775 fix error message


Project: http://git-wip-us.apache.org/repos/asf/oodt/repo
Commit: http://git-wip-us.apache.org/repos/asf/oodt/commit/3ecdfb90
Tree: http://git-wip-us.apache.org/repos/asf/oodt/tree/3ecdfb90
Diff: http://git-wip-us.apache.org/repos/asf/oodt/diff/3ecdfb90

Branch: refs/heads/master
Commit: 3ecdfb90aaaf39c86349ec7e301ab3164c203d1e
Parents: 988e58d
Author: Tom Barber <to...@analytical-labs.com>
Authored: Thu Oct 15 17:14:45 2015 +0100
Committer: Tom Barber <to...@analytical-labs.com>
Committed: Thu Oct 15 17:14:45 2015 +0100

----------------------------------------------------------------------
 .../cas/filemgr/system/XmlRpcFileManager.java   | 61 ++++++----------
 .../filemgr/system/XmlRpcFileManagerClient.java | 76 ++++++++++----------
 2 files changed, 59 insertions(+), 78 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/oodt/blob/3ecdfb90/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
----------------------------------------------------------------------
diff --git a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
index 2338547..e3c4bcf 100644
--- a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
+++ b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManager.java
@@ -18,30 +18,16 @@
 package org.apache.oodt.cas.filemgr.system;
 
 //APACHE imports
-import org.apache.xmlrpc.WebServer;
+import com.google.common.collect.Lists;
 
-//OODT imports
-import org.apache.oodt.cas.metadata.Metadata;
-import org.apache.oodt.cas.metadata.exceptions.MetExtractionException;
-import org.apache.oodt.commons.date.DateUtils;
 import org.apache.oodt.cas.filemgr.catalog.Catalog;
+import org.apache.oodt.cas.filemgr.datatransfer.DataTransfer;
+import org.apache.oodt.cas.filemgr.datatransfer.TransferStatusTracker;
 import org.apache.oodt.cas.filemgr.metadata.ProductMetKeys;
 import org.apache.oodt.cas.filemgr.metadata.extractors.FilemgrMetExtractor;
 import org.apache.oodt.cas.filemgr.repository.RepositoryManager;
-import org.apache.oodt.cas.filemgr.structs.Element;
-import org.apache.oodt.cas.filemgr.structs.ExtractorSpec;
-import org.apache.oodt.cas.filemgr.structs.FileTransferStatus;
-import org.apache.oodt.cas.filemgr.structs.ProductPage;
-import org.apache.oodt.cas.filemgr.structs.ProductType;
-import org.apache.oodt.cas.filemgr.structs.Product;
-import org.apache.oodt.cas.filemgr.structs.Query;
-import org.apache.oodt.cas.filemgr.structs.Reference;
-import org.apache.oodt.cas.filemgr.structs.exceptions.CatalogException;
-import org.apache.oodt.cas.filemgr.structs.exceptions.QueryFormulationException;
-import org.apache.oodt.cas.filemgr.structs.exceptions.RepositoryManagerException;
-import org.apache.oodt.cas.filemgr.structs.exceptions.DataTransferException;
-import org.apache.oodt.cas.filemgr.structs.exceptions.ValidationLayerException;
-import org.apache.oodt.cas.filemgr.structs.exceptions.VersioningException;
+import org.apache.oodt.cas.filemgr.structs.*;
+import org.apache.oodt.cas.filemgr.structs.exceptions.*;
 import org.apache.oodt.cas.filemgr.structs.query.ComplexQuery;
 import org.apache.oodt.cas.filemgr.structs.query.QueryFilter;
 import org.apache.oodt.cas.filemgr.structs.query.QueryResult;
@@ -49,35 +35,25 @@ import org.apache.oodt.cas.filemgr.structs.query.QueryResultComparator;
 import org.apache.oodt.cas.filemgr.structs.query.filter.ObjectTimeEvent;
 import org.apache.oodt.cas.filemgr.structs.query.filter.TimeEvent;
 import org.apache.oodt.cas.filemgr.structs.type.TypeHandler;
-import org.apache.oodt.cas.filemgr.datatransfer.DataTransfer;
 import org.apache.oodt.cas.filemgr.util.GenericFileManagerObjectFactory;
 import org.apache.oodt.cas.filemgr.util.XmlRpcStructFactory;
 import org.apache.oodt.cas.filemgr.versioning.Versioner;
 import org.apache.oodt.cas.filemgr.versioning.VersioningUtils;
-import org.apache.oodt.cas.filemgr.datatransfer.TransferStatusTracker;
-
-import com.google.common.collect.Lists;
-
-
-
+import org.apache.oodt.cas.metadata.Metadata;
+import org.apache.oodt.cas.metadata.exceptions.MetExtractionException;
+import org.apache.oodt.commons.date.DateUtils;
+import org.apache.xmlrpc.WebServer;
 
-//JDK imports
-import java.util.logging.Level;
-import java.util.logging.Logger;
-import java.util.Arrays;
-import java.util.Hashtable;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.Vector;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.FileNotFoundException;
+import java.io.*;
 import java.net.URI;
 import java.net.URISyntaxException;
 import java.net.URL;
+import java.util.*;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+//OODT imports
+//JDK imports
 
 /**
  * @author mattmann
@@ -1086,6 +1062,11 @@ public class XmlRpcFileManager {
 
     private Metadata runExtractors(Product product, Metadata metadata) {
         // make sure that the product type definition is present
+        if(product.getProductType() == null){
+          LOG.log(Level.SEVERE, "Failed to run extractor for: "+product.getProductId()+":"+product
+              .getProductName()+" product type cannot be null.");
+          return null;
+        }
         try {
             product.setProductType(repositoryManager.getProductTypeById(product
                     .getProductType().getProductTypeId()));

http://git-wip-us.apache.org/repos/asf/oodt/blob/3ecdfb90/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java
----------------------------------------------------------------------
diff --git a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java
index 7ea3129..c26eaec 100644
--- a/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java
+++ b/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java
@@ -18,48 +18,34 @@
 package org.apache.oodt.cas.filemgr.system;
 
 //APACHE imports
-import org.apache.xmlrpc.CommonsXmlRpcTransport;
-import org.apache.xmlrpc.XmlRpcClient;
-import org.apache.xmlrpc.XmlRpcClientException;
-import org.apache.xmlrpc.XmlRpcException;
-import org.apache.xmlrpc.XmlRpcTransport;
-import org.apache.xmlrpc.XmlRpcTransportFactory;
-//JDK imports
-import java.net.URL;
-import java.util.Hashtable;
-import java.util.List;
-import java.util.Vector;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-import java.io.FileInputStream;
-import java.io.IOException;
-import java.io.File;
-//OODT imports
 import org.apache.commons.httpclient.HttpClient;
 import org.apache.commons.httpclient.HttpMethod;
 import org.apache.commons.httpclient.HttpMethodRetryHandler;
 import org.apache.commons.httpclient.params.HttpMethodParams;
-import org.apache.oodt.cas.metadata.Metadata;
 import org.apache.oodt.cas.cli.CmdLineUtility;
-import org.apache.oodt.cas.filemgr.structs.exceptions.CatalogException;
-import org.apache.oodt.cas.filemgr.structs.exceptions.RepositoryManagerException;
-import org.apache.oodt.cas.filemgr.structs.exceptions.ValidationLayerException;
-import org.apache.oodt.cas.filemgr.structs.Element;
-import org.apache.oodt.cas.filemgr.structs.FileTransferStatus;
-import org.apache.oodt.cas.filemgr.structs.ProductPage;
-import org.apache.oodt.cas.filemgr.structs.ProductType;
-import org.apache.oodt.cas.filemgr.structs.Product;
-import org.apache.oodt.cas.filemgr.structs.Query;
-import org.apache.oodt.cas.filemgr.structs.Reference;
-import org.apache.oodt.cas.filemgr.util.GenericFileManagerObjectFactory;
-import org.apache.oodt.cas.filemgr.util.XmlRpcStructFactory;
-import org.apache.oodt.cas.filemgr.versioning.Versioner;
-import org.apache.oodt.cas.filemgr.structs.exceptions.VersioningException;
 import org.apache.oodt.cas.filemgr.datatransfer.DataTransfer;
-import org.apache.oodt.cas.filemgr.structs.exceptions.DataTransferException;
-import org.apache.oodt.cas.filemgr.structs.exceptions.ConnectionException;
+import org.apache.oodt.cas.filemgr.structs.*;
+import org.apache.oodt.cas.filemgr.structs.exceptions.*;
 import org.apache.oodt.cas.filemgr.structs.query.ComplexQuery;
 import org.apache.oodt.cas.filemgr.structs.query.QueryResult;
+import org.apache.oodt.cas.filemgr.util.GenericFileManagerObjectFactory;
+import org.apache.oodt.cas.filemgr.util.XmlRpcStructFactory;
+import org.apache.oodt.cas.filemgr.versioning.Versioner;
+import org.apache.oodt.cas.metadata.Metadata;
+import org.apache.xmlrpc.*;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.net.URL;
+import java.util.Hashtable;
+import java.util.List;
+import java.util.Vector;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+//JDK imports
+//OODT imports
 
 /**
  * @author mattmann (Chris Mattmann)
@@ -1286,10 +1272,24 @@ public class XmlRpcFileManagerClient {
                         + product.getProductType().getVersioner()
                         + ": Message: " + e.getMessage());
             throw new VersioningException(e);
-        } catch (Exception e) {
-            e.printStackTrace();
-            LOG.log(Level.SEVERE, "Failed to ingest product [" + product
-                    + "] : " + e.getMessage() + " -- rolling back ingest");
+        } catch(XmlRpcException e2){
+          LOG.log(Level.SEVERE, "Failed to ingest product [ name:" +product.getProductName() + "] :" + e2.getMessage() + " -- rolling back ingest");
+          try {
+            Vector<Object> argList = new Vector<Object>();
+            Hashtable<String, Object> productHash = XmlRpcStructFactory
+                .getXmlRpcProduct(product);
+            argList.add(productHash);
+            client.execute("filemgr.removeProduct", argList);
+          } catch (Exception e1) {
+            LOG.log(Level.SEVERE, "Failed to rollback ingest of product ["
+                                  + product + "] : " + e2.getMessage());
+          }
+          throw new Exception(e2);
+        }
+        catch (Exception e) {
+            //e.printStackTrace();
+          LOG.log(Level.SEVERE, "Failed to ingest product [ id: " + product.getProductId() +
+                                "/ name:" +product.getProductName() + "] :" + e.getMessage() + " -- rolling back ingest");
             try {
                 Vector<Object> argList = new Vector<Object>();
                 Hashtable<String, Object> productHash = XmlRpcStructFactory


[7/7] oodt git commit: OODT-755 update changes this closes #34

Posted by ma...@apache.org.
OODT-755 update changes this closes #34


Project: http://git-wip-us.apache.org/repos/asf/oodt/repo
Commit: http://git-wip-us.apache.org/repos/asf/oodt/commit/c101b01d
Tree: http://git-wip-us.apache.org/repos/asf/oodt/tree/c101b01d
Diff: http://git-wip-us.apache.org/repos/asf/oodt/diff/c101b01d

Branch: refs/heads/master
Commit: c101b01da34d4427705aa03865839f424769a024
Parents: 6567c85
Author: Tom Barber <to...@analytical-labs.com>
Authored: Thu Oct 15 23:50:52 2015 +0100
Committer: Tom Barber <to...@analytical-labs.com>
Committed: Thu Oct 15 23:50:52 2015 +0100

----------------------------------------------------------------------
 CHANGES.txt | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/oodt/blob/c101b01d/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 16b3f49..8b3d86f 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -23,6 +23,8 @@ Release 0.11 - Current Development
 
 * OODT-892 Tidy up null assignments (magicaltrout)
 
+* OODT-755 Fix error message in FM client when ingestion fails 
+
 Release 0.10 - 08/30/2015
 
 * OODT-871 Issues with OODT 0.10 RC#1 (lewismc, mattmann)