Last update: 15 March 2023

Introduction

To use external logging, first a Logging service has to be created. This service logging is used in this how-to to enable logging on equipment. At least 1 logging service having 1 method is a prerequisite for this how-to.

Create Logging on Equipment

Select the equipment of choice which produces a file with the measurement results, or a logging with process parameters. In this how-to, we will set up raman logging using a raman spectrometer. The spectrometer is connected to a computer and the computer generates a text file with the measurement results. The text file is generated by the spectrometer software and can be uploaded to the specific step in the run in SoloDB. SoloDB will use the external logging service to analyze the file, where the result will be saved in the run.

To set up the logging, open the equipment in SoloDB and open the Logging tab via Runs and Operations > Logging. Create the new logging via the Create new logging button and complete the form. In this example, no file is needed and the external logging service should be selected. The choice for a logging file separator can be omitted, as this is handled by the logging service.

Form to create new service logging on an equipment

If the form is submitted, the logging is shown and methods can be created.

Add Logging Method

To add logging, at least 1 pre-processing method has to be created in which a file can be uploaded. It is important that this method has been created in the logging service (see Service logging methods). In this how-to, we choose to create a pre-processing method based on the processing of the raman file.

Form to create new service logging method

If the method is created, the next step is to add the necessary parameters. Here, you can configure which parameters defined in the logging service have to be sent to the logging service. In this example, the logging service is expecting a file and a measurement type. The measurement type will be taken from the API call preprocessing/types, and the file is the file which is uploaded.

Form to add a new parameter logging method

In the SoloDB demo, a function demo is available which can be used for testing.

Selecting Results to be Logged

Once the pre-processing has been defined, the next step is to define the logging of the results. This can be done by uploading a test file using the Preview feature on the logging service page and checking the results.

When the file is uploaded, the results can be fetched from the result JSON by specifying the correct keys and assigning them to the correct result fields. Each result field requires an entry in the result fields. In this how-to, we obtain a metadata key which holds an array with the results, and we save the generated unique UUID, as shown below.

Using the file preview, the to-be-obtained results can be retrieved