[en] After setting up the triggers, you are only halfway done with the configuration. Before deploying the trigger, test it thoroughly for its intended operation upon incoming data and verify the execution of actions.
[en] Automation Builder enables you to test the configuration while you are still working on it. Some actions have built-in test capabilities so you can focus on the execution of individual action. You can also test every triggers with Run Preview command. However, the final test should always be done in the real environment, providing real data and using real triggers. This is how you monitor trigger execution using Automation Manager.
[en] Testing execution of individual actions
[en] Some of the actions include preview option. This allows you to change input parameters and to see the result of the action on-screen.
[en] Use Data Filter: The action provides live preview of the parsed data. The rules in the selected filter are applied to the selected input data file. The result is shown in the table. If you use sub- or assignment areas, you can see the preview for every level of filter definition.
[en] Execute SQL Statement: The action allows you to preview the execution of the defined SQL statement. You can monitor the data set resulting from the SELECT statement, and number of rows affected by the UPDATE, INSERT and DELETE statements. The preview execution is transaction-safe, which means that you can roll-back all changes. You can change the input query parameters and see how they affect the result.
[en] Web Service: The action allows you to preview the execution of a selected method (function) from Web Service. You can change the input parameters and see how they affect the result.
[en] Execute script: The action checks for syntax errors in the provided script, and also executes it. You can change the input parameters and see how they affect the script execution.
[en] Testing trigger execution and displaying label preview on-screen
[en] To test the trigger from the ground up, use the built-in Run Preview functionality. You can run preview for every trigger, no matter its type. The trigger won't fire upon changes of the monitored event. Only a trigger started in the Automation Manager can do it. Instead, the trigger is going to execute actions based on the data saved in a file. Make sure you have a file that contains sample data that the trigger is going to accept in real-time deployment.
[en] The trigger executes all defined actions (including data filtering) and displays label preview(s) on-screen. The preview simulates the printing process in every detail. The labels would print with the same composition and contents as shown in the preview. This includes the number of labels and their contents. You also learn about how many print jobs are produced, how many labels are in each job and see preview of each label. You can navigate from one label to the next in the selected print job.
[en] Log pane displays the same information as it would be displayed in the Automation Manager. Expand the log entries to see full detail.
[en] After you run the preview, all actions defined for the selected trigger are run, not just the Run Preview action. Be careful when using actions that modify the data, such as Execute SQL Statement or Web service, because their execution is irreversible.
[en] To preview the labels, do the following:
[en] Open the trigger configuration.
[en] Make sure the trigger configuration is saved.
[en] Click the button Run Preview in Preview group in the ribbon.
[en] Browse for the data file providing the typical contents that trigger will accept.
[en] See the result in a Preview tab.
[en] Testing deployment on pre-production server
[en] It is advisable to deploy the configuration to Automation Manager on pre-production server before deploying it on production server. Testing in pre-production environment might identify additional configuration issues that have not been detected during trigger testing in Automation Builder alone.
[en] Configuration performance can also be stress-tested by adding load to the trigger and monitoring how it performs. The testing provides important information about the available throughput and identifies weak points. Based on the conclusions, you can implement various system optimization techniques, such as optimizing label design to produce smaller print streams, and optimizing the overall flow of data from the existing application into NiceLabel Automation.
[en] Important differences between real trigger testing and previewing in Automation Builder
[en] While previewing the trigger on-screen in Automation Builder provides a quick method of trigger testing, you must not rely on it alone. There can be execution differences between previewing and running the trigger for real when you use 64-bit Windows.
[en] Even if you have your configuration working in Automation Builder, make sure to run in for real using the Service as well.
[en] When you run command Run Preview, the configuration executes in Automation Builder, which always runs as 32-bit application. Previewing your trigger in Automation Builder only tests execution on a 32-bit platform.
[en] When you run triggers for real, the configuration executes in Service, which runs as 32-bit application on 32-bit Windows, and runs as 64-bit application on 64-bit Windows. For more information see section Running in Service Mode.
[en] Issues might arise if trigger processing is affected by platform differences (32-bit vs 64-bit):
[en] Database access: 64-bit applications require 64-bit database drivers, and 32-bit applications require 32-bit drivers. To run configuration from Automation Builder and in the Service, you need 32-bit and 64-bit database drivers to access your database. For more information, see section Accessing Databases.
[en] UNC syntax for network files: The service account cannot access network shared files with mapped drive letter. You have to use UNC syntax for network files. For example, use
G:\files\label.nlbl, where G: is mapped to
\\server\share. For more information see section Access to Network Shared Resources.
[en] If your NiceLabel Automation Service runs under a different user account that you are using for Automation Builder, the accounts might not have the same security privileges. If you can open the label in Automation Builder, the user account for the Service might not be able to access it. To run Automation Builder under the same user account as the Service, see Using the same user account to configure and to run triggers.