Bug 749702

Summary: skynet list -c to list all content specs on server
Product: [Community] PressGang CCMS Reporter: Joshua Wulf <jwulf>
Component: CSProcessorAssignee: Lee Newson <lnewson>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 1.xCC: jwulf, lcarlon
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 0.17.0 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-02-22 03:02:28 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 751253    

Description Joshua Wulf 2011-10-28 00:56:25 UTC
Implement a list -c command to return a list of Content Specs on the server in the following format:


ID    Title

Comment 1 Joshua Wulf 2011-10-28 13:54:00 UTC
It should return:

ID    Title      Product     Version



If there are more than 50 Content specs in the database, then it should return:

There are <COUNT> Content Specs on this server. You should probably use "skynet search -c" if you have an idea what you are looking for. Otherwise, rerun the list command, and this time use the --force

Comment 2 Lee Newson 2011-11-20 23:35:16 UTC
Added the list -c and search -c functionality.

The list -c will list all content specifications on the server unless there are more then 50. If there are more then 50 then you can use the --force command to list all of them. This isn't recommended however and if I have time I'll implement a pagination feature that will allow you to view so many at a time then then request the previous or next list of content specs.

The search -c command takes in one extra argument which is the search query. This query will be matched against the title, product or version fields inside of the database. The search query uses the SQL LIKE command with the % wildcards matched on both ends of the query. As such the query is case insensitive but won't be broken down into specific words.

Comment 3 Joshua Wulf 2012-02-22 03:02:28 UTC
[jwulf@radhe Content_Spec_Processor]$ csprocessor list -c
CSProcessor client version: 0.17.0
Loading configuration from /home/jwulf/.config/csprocessor.ini
Web Service at http://csprocessor.cloud.lab.eng.bne.redhat.com:8080/ version: 0.21.4

    ID                                          TITLE                                PRODUCT  VERSION  CREATED BY
  6177                      EDS Getting Started Guide                               Internal        5     dlesage
  6178  JBoss Enterprise Data Grid Beta Documentation             JBoss Enterprise Data Grid        6    mhusnain
  6179                            Writing with Topics                               Internal        5       jwulf
  6180                 Guide to Topic-based Authoring           Engineering Content Services        1       jwulf
  6181            Data Services Getting Started Guide         JBoss Enterprise Data Services      5.3    elestran
  6182              Red Hat Engineers Guide to Zanata                      Engineering Tools        1       jwulf
  6183             Data Services Administration Guide         JBoss Enterprise Data Services      5.3    elestran
  6192                   Content Spec Processor Guide           Engineering Content Services        1       jwulf
  6198                          CDI Development Guide  JBoss Enterprise Application Platform        1    mstanley
  6199                          CDI Development Guide  JBoss Enterprise Application Platform        1    mstanley
  6200                          CDI Development Guide  JBoss Enterprise Application Platform        1    mstanley
  6226                            Your Name Test Book                                Testing        1       jwulf