oodt-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "brian Foster" <holen...@juno.com>
Subject Re: Review Request: Integrate CAS-CLI into CAS-Filemgr
Date Mon, 28 Nov 2011 08:43:27 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/2946/
-----------------------------------------------------------

(Updated 2011-11-28 08:43:27.585980)


Review request for oodt, Chris Mattmann and Paul Ramirez.


Summary (updated)
-------

Issue being tracked at: https://issues.apache.org/jira/browse/OODT-351

Added command-line options for filemgr:

$ ./filemgr-client -h
-----------------------------------------------------------------------------------------------------------------
| Short | Long                                             | Description
-----------------------------------------------------------------------------------------------------------------

 -op,    --operation                                        Declare that you wish to present
an operation
   SubOptions:
   > Required:
   > Optional:
      -addPT, --addProductType                              Triggers AddProductType Action
                                                              Requirement Rules: 
                                                               [AddProductType : REQUIRED]

      -dbyid, --deleteProductById                           Triggers DeleteProductById Action
                                                              Requirement Rules: 
                                                               [DeleteProductById : REQUIRED]

      -dbyn,  --deleteProductByName                         Triggers DeleteProductByName Action
                                                              Requirement Rules: 
                                                               [DeleteProductByName : REQUIRED]

      -ingest,--ingestProduct                               Triggers IngestProduct Action
                                                              Requirement Rules: 
                                                               [IngestProduct : REQUIRED]

      -product,--hasProduct                                  Triggers HasProduct Action
                                                              Requirement Rules: 
                                                               [HasProduct : REQUIRED] 
      -ptbyn, --getProductTypeByName                        Triggers GetProductTypeByName
Action
                                                              Requirement Rules: 
                                                               [GetProductTypeByName : REQUIRED]

      -num,   --getNumProducts                              Triggers GetNumProducts Action
                                                              Requirement Rules: 
                                                               [GetNumProducts : REQUIRED]

      -page1, --getFirstPage                                Triggers GetFirstPage Action
                                                              Requirement Rules: 
                                                               [GetFirstPage : REQUIRED] 
      -next,  --getNextPage                                 Triggers GetNextPage Action
                                                              Requirement Rules: 
                                                               [GetNextPage : REQUIRED] 
      -prev,  --getPrevPage                                 Triggers GetPrevPage Action
                                                              Requirement Rules: 
                                                               [GetPrevPage : REQUIRED] 
      -last,  --getLastPage                                 Triggers GetLastPage Action
                                                              Requirement Rules: 
                                                               [GetLastPage : REQUIRED] 
      -curTran,--getCurrentTransfer                          Triggers GetCurrentTransfer Action
                                                              Requirement Rules: 
                                                               [GetCurrentTransfer : REQUIRED]

      -curTrans,--getCurrentTransfers                         Triggers GetCurrentTransfers
Action
                                                              Requirement Rules: 
                                                               [GetCurrentTransfers : REQUIRED]

      -pbyid, --getProductById                              Triggers GetProductById Action
                                                              Requirement Rules: 
                                                               [GetProductById : REQUIRED]

      -pbyn,  --getProductByName                            Triggers GetProductByName Action
                                                              Requirement Rules: 
                                                               [GetProductByName : REQUIRED]

      -pctTrans,--getProductPctTransferred                    Triggers GetProductPercentTransferred
Action
                                                              Requirement Rules: 
                                                               [GetProductPercentTransferred
: REQUIRED] 
      -filePctTrans,--getFilePctTransferred                       Triggers GetFilePercentTransferred
Action
                                                              Requirement Rules: 
                                                               [GetFilePercentTransferred
: REQUIRED] 
      -sql,   --sqlQuery                                    Triggers SqlQuery Action
                                                              Requirement Rules: 
                                                               [SqlQuery : REQUIRED] 

 -u,     --url <url>                                        Workflow Manager URL
                                                              Handler: 
                                                               Sets the following Java Properties:

                                                               [org.apache.oodt.cas.workflow.url]


 -f,     --filter                                           Query filter
                                                              Requirement Rules: 
                                                               [SqlQuery : OPTIONAL] 

   SubOptions:
   > Required:
      -algor, --algor <classpath>                           FilterAlgor class
                                                              Requirement Rules: 
                                                               [SqlQuery : REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setAlgor' on action
selected, except 
                                                               for the following actions:
[] 
      -sdtMetKey,--startDateTimeMetKey <metadata-key>          Start date time metadata
key
                                                              Requirement Rules: 
                                                               [SqlQuery : REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setStartDateTimeMetKey'
on action 
                                                               selected, except for the following
actions: [] 
      -edtMetKey,--endDateTimeMetKey <metadata-key>            End date time metadata
key
                                                              Requirement Rules: 
                                                               [SqlQuery : REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setEndDateTimeMetKey'
on action 
                                                               selected, except for the following
actions: [] 
      -prMetKey,--priorityMetKey <metadata-key>               Priority metadata key
                                                              Requirement Rules: 
                                                               [SqlQuery : REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setPriorityMetKey'
on action 
                                                               selected, except for the following
actions: [] 
   > Optional:
      -conv,  --converter <classpath>                       VersionConverter class
                                                              Requirement Rules: 
                                                               [SqlQuery : OPTIONAL] 

                                                              Handler: 
                                                               Will invoke 'setConverter'
on action selected, 
                                                               except for the following actions:
[] 

 -pn,    --productName <product-name>                       Product name
                                                              Requirement Rules: 
                                                               [IngestProduct : REQUIRED,
HasProduct : REQUIRED, 
                                                               GetProductByName : REQUIRED,
DeleteProductByName : 
                                                               REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setProductName'
on action selected, 
                                                               except for the following actions:
[] 

 -vc,    --versionClass <classpath>                         ProductType versioner class
                                                              Requirement Rules: 
                                                               [AddProductType : REQUIRED]


                                                              Handler: 
                                                               Will invoke 'setVersionClass'
on action selected, 
                                                               except for the following actions:
[AddProductType 
                                                               : setVersioner] 

 -mf,    --metadataFile <file-path-or-url>                  Metadata XML file path or
URL
                                                              Requirement Rules: 
                                                               [IngestProduct : REQUIRED]


                                                              Handler: 
                                                               Will invoke 'setMetadataFile'
on action selected, 
                                                               except for the following actions:
[] 

 -curPage,--currentPageNum <page-number>                     Current Page Number
                                                              Requirement Rules: 
                                                               [GetNextPage : REQUIRED, GetPrevPage
: REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setCurrentPageNum'
on action 
                                                               selected, except for the following
actions: [] 

 -ps,    --productStructure <structure-type>                Hierarchical | Flat
                                                              Requirement Rules: 
                                                               [IngestProduct : REQUIRED]


                                                              Handler: 
                                                               Will invoke 'setProductStructure'
on action 
                                                               selected, except for the following
actions: 
                                                               [IngestProduct : setProductStructure]


 -ptn,   --productTypeName <product-type-name>              ProductType name
                                                              Requirement Rules: 
                                                               [IngestProduct : REQUIRED,
GetProductTypeByName : 
                                                               REQUIRED, GetNumProducts :
REQUIRED, GetFirstPage 
                                                               : REQUIRED, GetNextPage : REQUIRED,
GetPrevPage : 
                                                               REQUIRED, GetLastPage : REQUIRED,

                                                               GetProductPercentTransferred
: REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setProductTypeName'
on action 
                                                               selected, except for the following
actions: [] 

 -rs,    --refs <file-path-or-url>                          Data file path or URL
                                                              Requirement Rules: 
                                                               [IngestProduct : REQUIRED]


                                                              Handler: 
                                                               Will invoke 'setRefs' on action
selected, except 
                                                               for the following actions:
[IngestProduct : 
                                                               setReferences] 

 -repo,  --repository <file-path>                           ProductType repository
                                                              Requirement Rules: 
                                                               [AddProductType : REQUIRED]


                                                              Handler: 
                                                               Will invoke 'setRepository'
on action selected, 
                                                               except for the following actions:
[AddProductType 
                                                               : setFileRepositoryPath] 

 -sb,    --sortBy <metadata field>                          Metadata field to sort query
results by
                                                              Requirement Rules: 
                                                               [SqlQuery : OPTIONAL] 

                                                              Handler: 
                                                               Will invoke 'setSortBy' on
action selected, except 
                                                               for the following actions:
[] 

 -tn,    --typeName <product-type-name>                     ProductType name
                                                              Requirement Rules: 
                                                               [AddProductType : REQUIRED]


                                                              Handler: 
                                                               Will invoke 'setTypeName' on
action selected, 
                                                               except for the following actions:
[AddProductType 
                                                               : setProductTypeName] 

 -dlmtr, --delimiter <delimiter-string>                     String to use the separate
query results
                                                              Requirement Rules: 
                                                               [SqlQuery : OPTIONAL] 

                                                              Handler: 
                                                               Will invoke 'setDelimiter'
on action selected, 
                                                               except for the following actions:
[] 

 -pid,   --productId <product-id>                           Product ID
                                                              Requirement Rules: 
                                                               [GetProductPercentTransferred
: REQUIRED, 
                                                               GetProductById : REQUIRED,
DeleteProductById : 
                                                               REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setProductId'
on action selected, 
                                                               except for the following actions:
[] 

 -td,    --typeDesc <description>                           ProductType description
                                                              Requirement Rules: 
                                                               [AddProductType : REQUIRED]


                                                              Handler: 
                                                               Will invoke 'setTypeDesc' on
action selected, 
                                                               except for the following actions:
[AddProductType 
                                                               : setProductTypeDescription]


 -or,    --origRef <file-path-or-url>                       Original reference
                                                              Requirement Rules: 
                                                               [GetFilePercentTransferred
: REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setOrigRef' on
action selected, 
                                                               except for the following actions:
[] 

 -ct,    --clientTransfer                                   User client transferer
                                                              Requirement Rules: 
                                                               [IngestProduct : OPTIONAL]


   SubOptions:
   > Required:
      -dt,    --dataTransfer <classpath>                    DataTransferer factory class
                                                              Requirement Rules: 
                                                               [IngestProduct : REQUIRED]


                                                              Handler: 
                                                               Will invoke 'setDataTransfer'
on action selected, 
                                                               except for the following actions:
[IngestProduct : 
                                                               setDataTransferer] 
   > Optional:

 -q,     --query <query>                                    File Manager query
                                                              Requirement Rules: 
                                                               [SqlQuery : REQUIRED] 

                                                              Handler: 
                                                               Will invoke 'setQuery' on action
selected, except 
                                                               for the following actions:
[] 

 -of,    --outputFormat <output-format-string>              Output format string (i.e.
Filename = $Filename)
                                                              Requirement Rules: 
                                                               [SqlQuery : OPTIONAL] 

                                                              Handler: 
                                                               Will invoke 'setOutputFormat'
on action selected, 
                                                               except for the following actions:
[] 

 -h,     --help                                             Prints help menu
 -psa,   --printSupportedActions                            Print Supported Actions
-----------------------------------------------------------------------------------------------------------------


$ ./filemgr-client -psa

Actions:
  Action:
    Name: GetPrevPage
    Description: Gets prev page of Products of given ProductType

  Action:
    Name: DeleteProductByName
    Description: Delete Product by name

  Action:
    Name: GetFilePercentTransferred
    Description: Gets the percent amount transferred of given file

  Action:
    Name: GetProductById
    Description: Gets Product info by ID

  Action:
    Name: HasProduct
    Description: Checks if Product with given name has been ingested

  Action:
    Name: GetProductTypeByName
    Description: Gets a ProductType by its name

  Action:
    Name: GetCurrentTransfers
    Description: Gets the status of the current Product file transfers

  Action:
    Name: SqlQuery
    Description: Queries by parsing an SQL-like query into a FileManager Query

  Action:
    Name: GetProductPercentTransferred
    Description: Gets percent amount transferred of a Products data files

  Action:
    Name: DeleteProductById
    Description: Delete Product by ID

  Action:
    Name: GetNumProducts
    Description: Gets number of Products ingested for a given ProductType

  Action:
    Name: IngestProduct
    Description: Ingests a Product

  Action:
    Name: GetNextPage
    Description: Gets next page of Products of given ProductType

  Action:
    Name: AddProductType
    Description: Adds a ProductType to list of supported ProductTypes

  Action:
    Name: GetFirstPage
    Description: Gets first page of Products of given ProductType

  Action:
    Name: GetProductByName
    Description: Get Product info by name

  Action:
    Name: GetLastPage
    Description: Gets last page of Products of given ProductType

  Action:
    Name: GetCurrentTransfer
    Description: Gets the status of the current Product file transfer


$ ./filemgr-client -h IngestProduct

Action Help for 'IngestProduct'
 - Required:
    -u [--url] <url>
    -op [--operation]
      -ingest [--ingestProduct] (required)
    -pn [--productName] <product-name>
    -mf [--metadataFile] <file-path-or-url>
    -ptn [--productTypeName] <product-type-name>
    -ps [--productStructure] <structure-type>
    -rs [--refs] <file-path-or-url>
 - Optional:
    -ct [--clientTransfer]
      -dt [--dataTransfer] <classpath> (required)


Diffs
-----

  trunk/filemgr/pom.xml 1203939 
  trunk/filemgr/src/main/assembly/assembly.xml 1203939 
  trunk/filemgr/src/main/bin/filemgr-client 1203939 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/AbstractDeleteProductCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/AbstractGetProductCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/AddProductTypeCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/DeleteProductByIdCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/DeleteProductByNameCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/FileManagerCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetCurrentTransferCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetCurrentTransfersCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetFilePercentTransferredCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetFirstPageCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetLastPageCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetNextPageCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetNumProductsCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetPrevPageCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetProductByIdCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetProductByNameCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetProductPercentTransferredCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/GetProductTypeByNameCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/HasProductCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/IngestProductCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/cli/action/SqlQueryCliAction.java
PRE-CREATION 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/system/XmlRpcFileManagerClient.java
1203939 
  trunk/filemgr/src/main/java/org/apache/oodt/cas/filemgr/tools/DeleteProduct.java 1203939

  trunk/filemgr/src/main/resources/cmd-line-actions.xml PRE-CREATION 
  trunk/filemgr/src/main/resources/cmd-line-options.xml PRE-CREATION 
  trunk/filemgr/src/main/resources/logging.properties 1203939 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/TestFileManagerCli.java PRE-CREATION

  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/UseMockClientCmdLineActionStore.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestAddProductTypeCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestDeleteProductByIdCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestDeleteProductByNameCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetCurrentTransferCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetCurrentTransfersCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetFilePercentTransferredCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetFirstPageCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetLastPageCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetNextPageCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetNumProductsCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetPrevPageCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetProductByIdCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetProductByNameCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetProductPercentTransferredCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestGetProductTypeByNameCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestHasProductCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestIngestProductCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/cli/action/TestSqlQueryCliAction.java
PRE-CREATION 
  trunk/filemgr/src/test/org/apache/oodt/cas/filemgr/system/MockXmlRpcFileManagerClient.java
PRE-CREATION 

Diff: https://reviews.apache.org/r/2946/diff


Testing
-------

many unit-tests


Thanks,

brian


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message