Examples: Rulerunner Service log files
The following vscan_rrs.log file entry shows execution of the SetSourceDirectory action in the VScan ruleset:
Example 1
[1] action SetSourceDirectory(bool=false,bool=true,str="@APPPATH(vscanimagedir)")
[2] 1 Smart Parameter element found
[3] Parsing Smart Parameter element {0} value: "@APPPATH(vscanimagedir)"
[4] @APPPATH key root value: 'vscanimagedir'
[5] @APPPATH looking for workflow key: '*/dco_TravelDocs/vscanimagedir'
[6] @APPPATH workflow key found: 'C:\Datacap\TravelDocs\images'
[7] Smart Parameter return value: 'C:\Datacap\TravelDocs\images'
[8] looking for:C:\Datacap\TravelDocs\images
[9] Action changes: Directory with source images: C:\Datacap\TravelDocs\images
[10] result 0[x0] = true
[11] action returned true
[12] execute statement On Action True
[13] executing code:
[14] Call OnActionEnd()
[15] /execute statement On Action True
[16] /action
[17] execute statement On Action Start
[18] executing code:
[19] Call OnActionStart()
[20] /execute statement On Action StartBy
looking through the Rulerunner Service log file, you can see
precisely how Rulerunner interprets and runs each action. In
the SetSourceDirectory example, Rulerunner completes the following tasks:- Identifies the @APPPATH(vscanimagedir) parameter as a smart parameter [line 2]
- Identifies the key value as vscanimagedir [line 4)]
- Looks up the specified key value in the application configuration [line 5]
- Retrieves the value C:\Datacap\TravelDocs\images [line 6]
- Sets the image source directory to the specified location [line 9]
Example 2
In the previous example, the action runs successfully and returns a value of true [line 11]. In
the next example, there is an invalid key name in the action
parameter:
SetSourceDir("@APPPATH(imagedir)") <--"imageddir" is not a valid key This
time the batch does not finish. If you run the task from the Datacap Studio, you see an error message.In this case, you can look at the end of the log file
to determine the cause of the error [line 6].
[1] action SetSourceDirectory (bool=false,bool=false,str="@APPPATH(imagedir)")
[2] 1 Smart Parameter element found
[3] Parsing Smart Parameter element {0} value: "@APPPATH(imagedir)"
[4] @APPPATH key root value: 'imagedir'
[5] @APPPATH looking for workflow key: '*/dco_TravelDocs/imagedir'
[6] @APPPATH workflow key not found. <--Key not found
[7] @APPPATH looking for appname key: '*/dco_TravelDocs/imagedir'
[8] @APPPATH appname key not found.
[9] @APPPATH looking for general key: '*/imagedir'
[10] @APPPATH general key not found.
[11]Smart Parameter return value: ''
[12] looking for:@APPPATH(imagedir)
[13] Error: Folder '@APPPATH(imagedir)' does not exist <--Folder does not exist
[14]Error (385875969=hex:17000001). In CIMainAlgorithm::execute4DCO: Aborting: Action [SetSourceDirectory]
requested abort [api source:]
[15]EXCEPTION: code="385875969" msg="Aborting: Action [SetSourceDirectory]
requested abort" loc="CIMainAlgorithm::execute4DCO" API=""
[16]execute statement On Process End
[17] executing code:
[18] Quit()