Troubleshooting a streams flow

When you have a problem with a streams flow, use this guide to find answers to get it up and running again.

Notification errors in canvas

Your streams flow is validated as you edit. If errors exist in the streams flow, the Notifications icon Notifications icon is displayed in the upper-right corner of the canvas.

What’s happening

When the Notifications icon is displayed, the icon indicates validation errors in the streams flow operators or their links.

Why it’s happening

The streams flow has validation errors that might include the following issues:

How to fix it

Perform the following steps:

  1. Click the Notifications icon OK to display general error messages. For example, the error in a Sample Data operator might be Sample Data - Required parameters are missing.

  2. A red circle red circle is shown in the operator that has the error. Hover your mouse pointer over the red dot to see specific errors.

  3. Click the operator that has errors to open its Properties pane. A red circle is shown next to the problematic properties. Correct the problem. If there are no errors, no red circle is shown in the Notifications icon OK.

Here is a screen capture that shows the three areas where error messages are shown in the canvas:

All errors in an operator

Notification errors in Metrics page

If errors exist in the streams flow, the Notifications icon Notifications icon in the upper-right corner of the Metrics page is displayed with a red dot. This icon can indicate different types of errors: validation, compilation, or runtime.

What’s happening

The Notifications icon in the upper-right corner of the Metrics page is displayed with a red dot indicating that there are errors.

Why it’s happening

How to fix it

  1. In the Metrics page, click the Notifications icon to open the Notification pane. You can download log files and code files to help you identify your streams flow problem.

    Download logs in Notification icon

    Click any of the following icons:

    • Download user log icon Download user log icon to download the user log file. The user log contains logging messages that you put into the Code operator and the Python Model operator.

    • Download logs icon Download logs icon to download system log files. The log files are saved to your local disk in a compressed format. These logs are needed if you contact Support.

    • Download code archive icon Download code icon to download the code that generates the streams flow. The code can help you to identify the cause of runtime and compilation errors.

  2. In the Notifications pane, click an error to expand it and get details.

  3. In the Metrics page, click the Edit icon Edit icon to open the canvas.

  4. Follow the steps in the following table to correct problems. After you make your corrections, save the streams flow, and then rerun it.

Error type Error message How to fix it
Validation The streams flow is not configured properly 1. In the canvas, click the Notifications icon Notifications icon to locate the operator with errors.
2. Click the operator to open its Properties pane, and then fix the errors.
Compilation Incorrect Python library was imported in the Code operator See Python libraries.
In the Code operator, use only Python libraries that are supported.
Compilation Schema path is not valid 1. Click the operator with the invalid schema to open its Properties pane, and then click Edit Output Schema.
2. Correct the path.
Compilation Invalid filter expression 1. Click the Filter operator with the error to open its Properties pane.
2. Check that all expression operators are schema attributes. Use Python syntax.
Learn more about the Filter operator.
Compilation, Runtime Error accessing Streaming Analytics service instance. 1. In the Metrics page, click the Download icon Download icon to save the streams flow in STP format to disk. You will import this file in step 6.
3. Go to the Project page where the streams flow is located.
4. In the Assets tab, go to the Streams Flow section, and then delete the streams flow.
5. Click New streams flow.
6. In the Create Streams Flow page, click the From File tab, and then drag the downloaded streams flow to the Drop area. The name and description of the original streams flow are used.
7. Select the new Streaming Analytics Service.
8. Click Create.
9. In the Metrics page, click the Run icon Run icon.
Runtime Events are not flowing Check that all source instances are running.
Runtime Data type mismatch 1. Click the operator with the data type mismatch to open its Properties pane, and then click Edit Output Schema.
2. Check that the data type of each attribute is correctly set.
3. Check that the date is in a format that the streams flow supports. See Date formats.
Runtime Python runtime exceptions Click the Code operator with the error to open its Properties pane, and then correct the code. Also, check that all attributes that you are returning as output are listed in the schema.
Learn more about the Code operator.
     
Runtime Credentials are not valid or have expired Click the operator whose credentials are not valid or have expired, and then correct the credentials.
     
Runtime Unable to send email Some email servers block attempts to send email from third-party apps. In this case, log into the email account, open the email, and follow any instructions given by the server.

Other streams flow problems

What’s happening

A streams flow is stopped.

Why it’s happening

How to fix it

Restart the stream flows.

What’s happening

Some problems cannot be fixed by the user, or they might require investigation to determine the cause.

Why it’s happening

The following error messages require further intervention:

How to fix it

If the streams flow cannot start due to error, perform the following steps:

  1. In the Metrics page, perform the following steps:

    a. Click the Download icon Download icon to save the streams flow to a file in STP format on your local disk.

    b. Note the URL of the Metrics page.

  2. Contact support with the downloaded information.

What’s happening

No data is flowing in the streams flow.

Why it’s happening

Some causes might be runtime errors, incorrect connection information, or the data source instance is missing or stopped.

How to fix it

Perform the following steps:

  1. In the Metrics page of the streams flow, check for any runtime errors. If errors exist, click the Notification icon, and then click the Download logs icon Download logs icon and the Download user logs icon Download user logs icon to save the logs to your local disk. Check the logs for errors.

  2. In the Metrics page, click the Edit icon Edit icon to open the canvas. In the canvas, click the problematic operator. In the Properties pane, check that the connection information is correct.

  3. Check the health of the data sources in your IBM Cloud Dashboard:

    • Does an instance of the data source exist? If it was deleted, you must create a new instance.
    • Is the instance stopped? If so, restart it.
    • Can you browse assets in the instance? Click the name of the instance to open the instance. For example, check for topics in an Event Streams instance, or for buckets in a Cloud Object Storage instance.

What’s happening

A streams flow can consume large volumes of data, but if an operator cannot handle the large volume, the flow will back up to the operators feeding into it.

Why it’s happening

Congestion occurs when tuples are being delivered to an operator faster than they can be processed and sent to the next operator.

How to fix it

You can take several measures to reduce operator congestion.

What’s happening

You can’t run a streams flow.

Why it’s happening

Permissions on project level are different from permissions on streams instance level. If you’re an editor or even admin on a project, you still need at least ‘user’ permission on the streams instance to run the flow.

How to fix it

Ask for ‘user’ permission on the streams instance.

Display problems in the canvas or in the Metrics page

What’s happening

The operators and their links do not show up properly in the canvas or in the Metrics page.

Why it’s happening

Your web browser is not the latest version of Google Chrome, Mozilla Firefox, Microsoft Internet Explorer, or Apple Safari.

How to fix it

Update your web browser with the latest version.

Unsupported operators error in the canvas

What’s happening

If you’re trying to run or edit old flows with the SPSS model operator or the Python model operator, you receive an error message.

Why it’s happening

The SPSS model operator and the Python model operator are not supported anymore, they have been replaced by a new WML Deployment operator.

How to fix it

Create a new flow using the new WML Deployment operator

Learn more