4 Replies Latest reply on Sep 27, 2013 9:51 AM by Nick Jones

    Compliance using Extended Object

      Hi all,


      Just starting to use extended objects for Compliance and am trying to set up a Compliance job for df of a filesystem.


      I have an Extended Object set for Remote Execution using csv file grammar, which runs command


      df -Pk /usr/WSApps/??TARGET._APP_PROPS_GuideWire._App_Logfile_Folder?? | grep -vE '^Filesystem' | awk '{ print $1 "," $2 "," $3 "," $4 }'


      This returns results such as


      EO results.JPG.jpg

      I have then created a component template with a compliance rule of


      "Extended Object Entry:Guidewire WSApps Space"."Value3 as Integer (All OS)" > 204,800


      I thought this should work, but on executing the Compliance job against a server where Value3 is greater than 204800 always results in a Non-compliant result. I have also tried amending the rule to be less than a figure and tried different values for each i.e. values bigger and smaller than Value3 in both less than and greater than rules.


      Am i making some basic error in how im trying to use this functionality?


      Edit: we're using version, and the EO is running against Redhat linux


      Thanks for any help

        • 1. Re: Compliance using Extended Object
          Jim Campbell

          I believe you need something like:


          Extended Object Entry:Guidewire WSApps Space//NAME_HERE"."Value3 as Integer (All OS)"


          I have had all kinds of problems though when the name of the value has a / in it as it appears to treat it as a separator rather than a literal string.  In the example above it looks like your name is a file path which would be difficult to handle.


          If you need to iterate through a list of names something like this works:


          foreach "Extended Object Entry:Guidewire WSApps SPace//*"

          "Value3 as Integer (ALL OS)" > 204800


          • 2. Re: Compliance using Extended Object

            Thanks for the info. I have used the foreach as suggested.


            Oddly though now the rule is always returning as Compliant, again regardless of whether i use less than or greater than and regardless of the integer value being used in the rule?


            Does the compliance rule execution get logged anywhere in more detail so i could see from the input figures why it always thinks its Compliant?



            • 3. Re: Compliance using Extended Object
              Jim Campbell

              It is likely not parsing the extended object properly.  It may very well be the / in the names - even when used as an iterator it seems to interpret these as separator tokens rather than as part of the value so instead of a value of '/dev/mapper/ukgcc_etc' of name 'Extended Object Entry://Guidewire WSApps Space' it is looking at it as a value of 'ukgcc_etc' of name Extended Object Entry://Guidewire WSApps Space/dev/mapper.  I have run into this issue with date fields and never been able to work around it save by changing the formatting of the output of the extended object by e.g. replacing / with some other character.


              You can test compliance rules to see what values it is pulling back by using the 'Test the rule' button on the compliance rule editor.  If you run the test the values it pulls back (if any) will be displayed.

              • 4. Re: Compliance using Extended Object

                Thank you, your suggestions have enabled me to get it working.


                I amended the output from the EO for the Name field to remove the /, and using the Test Rule could see nothing was being returned for Value3.


                I think it must have been the csv grammer format, as i amended the EO output to just return a Name = Value return and amended the grammar to the same. After doing that the rule now functions correctly.


                Many thanks for your help