You are viewing limited content. For full access, please sign in.

Question

Question

email notification for suspended states.

asked on February 21, 2017

Is it possible to get an email notification when a Save to Repository task goes into a suspended state?  We don't work enough in Laserfiche Forms to be aware of when this occurs and it can sit in there for over a week before anyone notices.

6 0

Replies

replied on February 21, 2017

Forms 10.2 only add support for sending notification when instance get terminated. There is no email for suspended. We will consider add support for suspend instances.

7 0
replied on May 28, 2019

Hello,

Has this feature been added to Laserfiche Forms yet? It is very important to be able to receive email notifications on suspended steps so that we can immediately address the issue. 

2 0
replied on July 8, 2019

@████████ Any updates on this feature being added to Laserfiche?

0 0
replied on October 31, 2019 Show version history

@████████ Email notifications for suspended instances is also a feature that would be highly useful in Laserfiche Cloud. Is this something that might be possible with the new Forms in Process Automation? 

 

1 0
replied on November 4, 2019 Show version history

This feature is still not yet in on-premises Forms, but we are hoping to get to it soon.

Henry, yes, the notifications built in for Process Automation include a notification to process admins if any instances have been suspended. You can also configure a notification for an initial submitter if their instance has been suspended. 

1 0
replied on November 4, 2019

@████████Great, thank you. This is something to look forward to once Forms in Process Automation has feature parity with Legacy Forms and we are able to migrate. 

0 0
replied on April 12, 2018

I took the stored procedure above, pared it down a bit and put it into a Custom SQL Query inside a Workflow.  This workflow queries both the Forms db and the Workflow db, puts the results into a token and emails out daily.  For the Forms, it is only looking for suspended forms.  For Workflow it finds any WF that terminated within the last day.  Thus far it seems to be working and I haven't gotten any false positives.

Capture2.PNG
Capture.PNG
Capture3.PNG
Capture2.PNG (11.81 KB)
Capture.PNG (20.52 KB)
Capture3.PNG (11.42 KB)
3 0
replied on February 5, 2019

Has an option for email notifications on suspended forms been added yet?

3 0
replied on August 14, 2019

Hello,

 

What is the status of this feature request? Should I reach out to presales?

 

Regards,

3 0
replied on February 26, 2020

https://support.laserfiche.com/kb/1014114/list-of-changes-for-laserfiche-forms-10-4-3

List of Changes for Laserfiche Forms 10.4.3

Product: Laserfiche Forms

February 21, 2020 | KB: 1014114

  • Added the ability to send an email notification when a process is suspended.
3 0
replied on March 6, 2020

Where is this option found? I can't seem to find where we can set up email alerts on suspended tasks, only terminations.

0 0
replied on March 9, 2020

You can find it from Process Options dialog or Process Options page with Forms 10.4.3

1 0
replied on September 2, 2020

Hi Xiuhong,

 

Is this planned to be added to Cloud as well? The "Send email notification when this process terminates" option is there but not the suspended one.

 

Thanks,

0 0
replied on September 2, 2020

For business processes built in process automation in the cloud, you should already have notifications available for when an instance suspends. We are not actively updating legacy Forms in the cloud, all updates will be in business processes within process automation. 

0 0
replied on September 2, 2020

Thanks for the quick response. If I click the "gear" icon on the process diagram page, this is the only checkbox.

0 0
replied on September 2, 2020

Go to the business process manage page and open up the right pane. There is a tab for notifications. You can set up a notification for whenever the process is halted (cancelled, suspended, terminated). You can have them go through the web UI (bell notification) or have it send an email. You can also control whether the email is immediate or if it sends a daily digest each day. 

2 0
replied on March 10, 2021

Hello Jared,

Where is the business process manage page located in LF Cloud?

Thanks,

Jeff Curtis

0 0
replied on March 10, 2021

Hi Jeff,

No we have an on-prem Laserfiche server.

Thanks,

Jared

replied on March 10, 2021

Go to your process automation dashboard with all the applications and click on business processes. That will take you directly to the business process manage page. The right pane has two tabs and notifications is the second tab. 

0 0
replied on March 10, 2021

Thanks Jared R.

Jeff

0 0
replied on March 10, 2021

Jared R,

Follow up, when we go to Configure Email notifications and select individual emails, where do we enter the email, we see this message about disabled.  How do we configure the email notification to go to a specific user?

 

Thanks,
Jeff Curtis

1 0
replied on March 10, 2021

These notifications are not designed to be configured to go to a specific user. Any individual that wants to subscribe to the suspended notification must configure it for themselves. You can choose to get an email each time an instance suspends (individual emails) or you can get a daily digest of all the processes that halted once per day. 

0 0
replied on March 10, 2021

Hey Jared,

Thanks, so the will just need to login themselves and set that notification.

Makes sense.

Jeff Curtis

0 0
replied on August 31, 2021 Show version history

Does anyone know where you subscribe to get these email notifications?

Ah I see the image above showing how to subscribe for a specific process, how does the administrator subscribe for any process?

1 0
replied on October 25, 2021

Hi Chad, the image was captured from Cloud. Self-hosted Forms doesn't support subscribe.  

1 0
replied on February 22, 2017

I came up with the sql query below and incorporated it into our monitoring software .   It runs every half hour and notifies us if there is a terminated or suspended instance.   We had the same issue when a save to repository will occasionally suspended and go unnoticed for days at at time.

The query as written simply returns the number of suspended or terminated processes, 0 if all is well.  It has been working great.   Discuss it with your IT/monitoring team ( I wear the LF and monitoring hats here so it was easy).  They should be able to setup a monitor to trigger an email.

Andrew

 

with cte as
(
select 
count(distinct WORKER.bp_instance_id) as id
from 
[LFForms].[dbo].[cf_bp_worker_instances] WORKER 

join [LFForms].[dbo].[cf_bp_main_instances] MAIN on WORKER.bp_instance_id = MAIN.bp_instance_id 
where WORKER.[status] >= 9
and (MAIN.status = 4 or MAIN.status = 1)
GROUP BY WORKER.bp_instance_id

) select count(*) from cte

2 0
replied on February 23, 2017

For the issue that save to repository will occasionally suspended, Forms 10.2 has added the auto retry mechanism for service task that get suspended so randomly failure will be auto retried.

1 0
replied on June 12, 2017

Where is this option?

 

0 0
replied on June 13, 2017

The option is in the cf_options table in Forms database with optionname of "AutoRetry". It is by default turned on with optionvalue of "true".

0 0
replied on September 14, 2017 Show version history

Andrew, I used your query for creating a SQL stored procedure which runs every few hours from the SQL Agent.  The SP sends an email detailing the suspended jobs.  I thought I'd post it here in case it was useful for others.

 

CREATE PROC [dbo].[LFF_SuspendedTasksEmailAlert]

AS

SET NOCOUNT ON;

DECLARE @EmailTo VARCHAR(500) = 'email.address@domain.com'
DECLARE @DBMailProfile VARCHAR(50) = 'MailProfileName'

SELECT
	worker.bp_instance_id
	,worker.instance_id
	,main.bp_name
	,main.title
	,main.[start_date]
	,main.lastacted_date
INTO
	#Suspended
FROM 
	LaserficheForms.dbo.cf_bp_worker_instances AS worker
	JOIN LaserficheForms.dbo.cf_bp_main_instances AS main
		ON worker.bp_instance_id = main.bp_instance_id 
WHERE
    (worker.[status] >= 9 AND (main.[status] = 4 OR main.[status] = 1))
    OR (worker.[status] >= 7 AND main.[status] = 4)

IF @@ROWCOUNT > 0 --only send message if errors exist

	BEGIN

		--Delare variable to house xml and html
		DECLARE @xml NVARCHAR(MAX)
		DECLARE @body NVARCHAR(MAX)


		SET @xml = CAST(( 
			SELECT
				ISNULL([bp_instance_id],' ') AS 'td',''
				,[instance_id] AS 'td',''
				,[bp_name] AS 'td',''
				,[title] AS 'td',''
				,[start_date] AS 'td',''
				,[lastacted_date] AS 'td'
			FROM
				#Suspended
			FOR XML PATH('tr'), ELEMENTS ) AS NVARCHAR(MAX))
		
		
		SET @body ='
					<H3>Laserfiche Forms Suspended Tasks</H3>
					<table>
							<tr>
								<th>bp_instance_id</th>
								<th>instance_id</th>
								<th>bp_name</th>
								<th>title</th>
								<th>start_date</th>
								<th>lastacted_date</th>
							</tr>'   
		
		--Apply inlines styles (Gmail doesn't support <style> in the header)
		SET @body = REPLACE(@body,'<table>','<table style="font-size:1em;border-collapse:collapse;border: 1px solid #dcdcdc!important;">')
		SET @xml = REPLACE(@xml,'<td>','<td style="border: 1px solid #dcdcdc!important; padding: 7px 7px 7px 7px;">')
		SET @body = REPLACE(@body,'<th>','<th style="text-align: center; padding: 7px 7px 7px 7px; background-color: #006598; color: #ffffff;border: 1px solid #dcdcdc!important;">')

		SET @body = @body + @xml +'</html>'

		DECLARE @Subj VARCHAR(100) = 'Laserfiche Forms Suspended Tasks - ' +  CONVERT(VARCHAR,GETDATE())

		EXEC msdb.dbo.sp_send_dbmail
			@profile_name = @DBMailProfile
			,@from_address = 'Automated Report <noreply@domain.com>'
			,@recipients = @EmailTo
			,@subject = @Subj
			,@body = @body
			,@body_format ='HTML'
		
	END

/****Drop the temp tables ****/
IF OBJECT_ID('tempdb..#Suspended') IS NOT NULL
BEGIN DROP TABLE #Suspended END
GO

 

2 0
replied on September 14, 2017 Show version history

We missed a few events with my original query and I have tweaked it a bit.  It's been spot on since.

with cte as
(
select 
count(distinct WORKER.bp_instance_id) as id
from 
[LFForms].[dbo].[cf_bp_worker_instances] WORKER 

join [LFForms].[dbo].[cf_bp_main_instances] MAIN on WORKER.bp_instance_id = MAIN.bp_instance_id 
where (WORKER.[status] >= 9 and (MAIN.status = 4 or MAIN.status = 1))
or (  WORKER.[status] >= 7 and MAIN.status = 4)

GROUP BY WORKER.bp_instance_id

) select count(*) from cte

3 0
replied on March 29, 2018

Unfortunately, the stored procedure listed here gets a large number of false positives in my environment.

0 0
replied on April 6, 2018

Do you have a list of what the status codes mean?

0 0
replied on April 12, 2018

This is the list of status codes that I have:
 

Status code for main instance:

        running 1

       Complete 2

        Canceled 3

        Terminated by error 4

        Terminated by End Event 5

 

Status code for routing instance status (you can consider this as worker instance status)

        Ready 1

        Wait for trigger 2

        Running 3

        Step executed 4

        Sleep = 5

        Split = 6

        Merged 7

        Complete 8

        Terminate 9

        Interrupted 10

        Suspended due to error (resume-able) 11

        Suspended due to task error (not resume-able) 13

3 0
replied on May 23, 2019

Bump. Has this been added or planned to be added in a release this year?

2 0
replied on February 21, 2017

This feature was added in Forms 10.2 I believe

0 0
replied on October 19, 2018

Thanks for this workaround Donald Brewer. 

If it's a feature in 10.2 and above that would be great.  Anyone have a link to documentation if it is? 

Otherwise, I'll add my name to the list that this would be a great feature.

0 0
replied on October 10, 2019

I've recently turned on the option to be notified when a process terminates (as per above) but I am wondering if this means I'll get notified on terminated and cancelled processes. I don't even know how a process is cancelled or what the difference is between cancelled and terminated.

As a comment: I feel that the cancelled status is misleading, given that the status is just "Terminated" in the actual process, even though the process in the monitoring list says "Cancelled". See below.

0 0
replied on October 10, 2019

A process instance can be Cancelled by a user (the "Stop" button when you select an "in progress" instance in the instance monitoring), but it is important to note the distinction between the status of the Task, and the status of the overall Instance.

When you Cancel an Instance, it will Terminate any active Tasks, but the the Instance status references the entire process whereas the drilldown is showing the status of the individual Tasks within that instance.

0 0
replied on October 10, 2019

Hi Jason, Thank you for the distinction, that makes sense.

I am wondering though, in the case I've mentioned above, the process instance wasn't stopped in the instance monitoring area and yet the process instance shows that it was cancelled. Are there any other ways that an instance can be cancelled? Or, I guess the question also is, how is a task terminated (if not stopped in the instance monitoring)?

0 0
replied on October 10, 2019

That seems a bit confusing. When you select the instance, does it show the "clipboard" icon near the top right? This would include an error log if any were reported.

I'm not sure how a "Canceled" status could appear without it having been manually stopped via the instance monitoring interface. As far as I know, that's the only time that particular status is used.

Terminated instances/tasks can occur as the result of a critical error. For example, trying to assign a task to a user that does not exist. If errors like that did occur, they would show up in the error log.

0 0
replied on October 10, 2019

No clipboard.

I was just working on another issue on the form though and went to verify that the process was fine. It seems like "Finance to approve PO" was the exact same name as another instance (two different ID's but still) so that could be the critical error you're talking about. Still, I'd have expected the process instance to be suspended or terminated but not cancelled with no error...

0 0
replied on October 10, 2019

Who else has access to the environment?

When you say the names were the same, are you talking about the instance names or the task names? Usually name conflicts would be reported in the process diagram designer when you run the validation or try to save.

0 0
replied on October 10, 2019 Show version history

I'm the main administrator and am the only one with admin access to the process (and to the monitoring tab available in Forms).

Yes, I caught the name similarity when I ran validation on the process diagram: two user tasks in the process diagram had the same name. Oddly, it wasn't caught when I saved the diagram, but I ran validation to be sure everything was fine and that was when it was caught.

0 0
replied on October 10, 2019 Show version history

Does anyone have the Business Manager role for that process (under Access Rights in the process designer)? Just curious because those users can also stop instances without required Administrator rights.

0 0
replied on October 10, 2019

Just my admin user as a Process Admin and a group with all of our staff as submitters:

 

Access Rights.png
0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.