When FlowAssembly raises an alert

Each alert in deploy/monitoring/alerts.yaml links to its section here. Every section says what the alert means for the people using FlowAssembly, what to check, and what to do. The log events and metrics named here are listed in telemetry.md.

A log search for one case_id shows everything that happened to a case across every service. With tracing on (tracing.endpoint in the instance settings), its trace_id shows the same work in your tracing tool, including the calls FlowAssembly made to other systems.

FlowAssemblyServiceFailing

What it means. A background service (the connector worker, the script worker or the scheduler) has failed at least three passes in ten minutes. Calls to other systems, scripts or timers are not happening, so cases wait.

What to check.

  • Admin > Settings > System info: each service, when it was last heard from, and whether its last pass failed. A service that has stopped shows as quiet.

  • The service’s service.pass_failed log events: each carries the error and traceback.

  • Whether the database is reachable from the service’s pod (/readyz on its health port).

  • Recent changes: a new release, new instance settings, rotated secrets.

What to do. Fix the cause the error names. The service retries every pass by itself and recovers without a restart. If its pod is restarting, check kubectl describe pod for memory limits or failed probes.

FlowAssemblyWebErrors

What it means. More than one web request in twenty is ending in a server error. People are seeing error messages instead of their work.

What to check.

  • request.completed events with a 5xx status, grouped by route, to see which part of the application fails.

  • The web pods’ /readyz, and readiness.failed events, which usually mean the database cannot be reached.

  • Errors from django.request in the web logs; they carry the traceback.

What to do. If one route fails, look at its traceback. If everything fails, check the database and the web pods’ resources. Roll back a release (fa rollback) if the errors started with it.

FlowAssemblyWebSlow

What it means. One request in twenty takes longer than 1.6 seconds, so the application feels slow.

What to check.

  • fa_http_request_duration_seconds by route, to find the slow pages.

  • Database load and connections. Each web process uses up to its thread count plus two (docs/deploy/kubernetes.md, Sizing).

  • With tracing on, the slow requests’ traces show where the time went.

  • If a trace shows a slow case action but not why, add finer spans for a while (tracing.detail in the instance settings, picked up when the services restart):

    • database shows each query (db.query), each wait for another transaction’s lock (db.lock, usually two people changing one case), and each wait for a free connection (db.connection, meaning the pool is too small for the threads using it);

    • engine shows the workflow engine rebuilding the case (engine.restore), running its steps (engine.run), working out decision tables (engine.decide) and storing the case (engine.save); the stored state’s size is on the restore and save spans.

    Take them off again afterwards: they add to every trace.

What to do. Add web replicas if CPU is high. Look at the database if queries are slow. A single slow route is worth reporting as a defect.

FlowAssemblyStepsNeedASupervisor

What it means. Background steps (a call to another system, a script) have failed for good. Each one holds its case still until a supervisor retries it.

What to check.

  • The Supervision page lists each failed step with its last error, for its project’s supervisors. Admin > Settings > Queues lists them across every project.

  • job.dead_lettered events carry the same error, with the case id.

  • Whether the other system was down at the time (see FlowAssemblyConnectionFailing).

What to do. Fix the cause (the other system is back, a secret was corrected), then retry the steps from the Supervision page, or from Queues with platform.maintenance. A retry starts the step’s attempts afresh.

FlowAssemblyWorkWaitingLong

What it means. A task has waited more than three days for someone to do it.

What to check.

  • The Supervision page shows the oldest open tasks, who has them, and which role they wait for.

  • Whether the role has anyone in it (fa access show). A role with no members in the access policy leaves its tasks unclaimed.

  • fa_task_wait_seconds by task, to see whether one step is usually slow.

What to do. Reassign the task from the Supervision page, or add people to the role. If one step is always slow, raise it with the process owner.

FlowAssemblyFormConfusing

What it means. Many submissions of one form were refused by its rules in the last hour. People may find the form confusing. This is information for the form’s builder, not an emergency.

What to check.

  • task.refused events for the form: problem_fields lists which fields people got wrong. The values are never logged.

What to do. Share the fields with the form’s builder. Clearer labels, a pattern message such as “Enter a phone number of 7 to 20 digits”, or a looser rule usually helps.

FlowAssemblyMessagesGoingNowhere

What it means. A case sent a message for another process of its project, and it did not arrive: no case was waiting for it with the same reference, and no process starts with it, or the receiving case did not accept what it carried. The sending case carries on. The case that should have heard may now wait for ever.

What to check.

  • message.undelivered events: the message, whether it was unmatched or refused, and for a refusal, the reason. The sending case’s history shows a message.passed_on entry with the same outcome.

  • For unmatched: is the receiving case already past the step that waits, or not there yet? Does it hold the same reference (the message’s correlateBy field) as the sender?

  • For refused: the reason names the case data the receiver did not accept.

What to do. Tell the project’s builder which message and which outcome. Usually the two processes disagree about the order of events or the reference. A message that arrives before its case waits is not kept yet (B-005), so the fix is in the processes. The case that missed the message can be moved on by sending it again from another system, with the same fields.

FlowAssemblyFilesNotChecked

What it means. Files people add to cases are being refused at their virus check. Either the scanner (ClamAV) is not answering, and nobody can add a file until it does, or it found something harmful in a file someone tried to add.

What to check.

  • file.refused events: reason is scanner or virus, with the project and case.

  • For scanner: can the web server reach files.scanner on its port? Is ClamAV running, with its virus definitions loaded?

  • For virus: the case’s history names who tried to add the file and when. The file was not kept.

What to do. Bring the scanner back. A harmful file needs no clean-up in FlowAssembly, as it was never kept; tell your security team who tried to add it, in case their device is infected.

FlowAssemblyNoticeEmailsFailing

What it means. The scheduler cannot email people that a task came to them or was moved away from them. Nobody loses work: every notice is still listed under Notices in FlowAssembly. People who rely on the email will not know until they next look.

What to check.

  • Admin > Email > Delivery log, Failed: each notice email that did not go, to whom, and the mail server’s reply.

  • notice.email_failed events: the reason (an SMTP reply code, a connection error, or the directory) and how many attempts.

  • Can the scheduler reach notifications.email.host on its port? Does the mail server accept the user name and the password named in passwordSecret?

What to do. Fix the connection or the sign-in. Failures that may pass are tried again up to five times; notices older than a day are not emailed, so a long outage does not send a burst of old news afterwards.

FlowAssemblyConnectionFailing

What it means. More than one call in five to another system (a registry, a mail server) is failing. Cases that need that system are being retried and may end up waiting for a supervisor.

What to check.

  • connector.called events for the connection: outcome, status and duration_ms show whether it refuses, errors or times out.

  • With tracing on, the failing calls’ traces, which the other system’s team can follow too: each call sent its traceparent.

  • The connection’s address in the instance’s connection settings.

What to do. If the other system is down, tell its owners. FlowAssembly retries by itself. If it refuses our requests (4xx), check the connection’s settings and secret.

FlowAssemblyTokenServerRefusing

What it means. An OAuth token server refused a connection’s client id and secret. Every call through that connection will fail until they are fixed.

What to check.

  • oauth.token_requested events with outcome: refused. The step’s error gives the token server’s own reason, such as invalid_client.

  • Whether the client secret was rotated on the token server but not in the secrets file.

What to do. Put the right client_id:client_secret in the secrets file under the connection’s secretRef, then restart the connector worker so it reads it. Retry any steps that failed meanwhile from the Supervision page.

FlowAssemblyDirectoryUnavailable

What it means. People cannot sign in because the LDAP directory does not answer. Local accounts still work.

What to check.

  • signin.refused events with reason: unavailable.

  • Network access from the web pods to the directory servers, and the directory’s certificate if it changed.

What to do. Restore access to the directory. Nothing in FlowAssembly needs restarting. A failed directory sign-in never falls through to a local account, by design.

FlowAssemblySignInGuessing

What it means. More than fifty sign-ins were refused in ten minutes. Someone may be guessing passwords.

What to check.

  • signin.refused events by reason. The sign-in throttle blocks repeated tries from one address or for one account (throttled).

  • The audit trail’s login.failed and login.throttled entries, which record the account names and addresses.

What to do. Tell your security team. Block the addresses at your ingress if they are outside your organisation. Check whether a directory account is being locked out repeatedly.