Updating Event Action updated through "Repair All" function

  • 12 September 2008
  • 3 replies
  • 0 views

Badge +7

Hi,


 I've a problem with my customer's K2.net 2003 production server. It is related to this forum post : http://www.k2underground.com/forums/thread/19307.aspx


 To resume: I repaired Mail event with hard coded email and now, all same events in error are sent to the same people.


 My question:


Is there a way to update the mail event to avoid this behavior without publishing a new version of the process definition? I was thinking about updating directly in database (even don't know if it's possible)...


Thank you for your help


3 replies

Badge +13

Even if you publish a new version all existing in-progress workitems will still use the hard coded email address.

I don't know if there is a way K2 Support can help you clean up the code in the database.

If you can somehow trigger it to error again then you can fix the problem but that might be hard to do.

Badge +6

you can likely trigger an error by removing the email account information (from AD) for the currently defined user.


This will then ("typically"...it will fail if only one Destination User is defined. I'm not sure if it will fail if multiple DU's are involved) generate an error in K2 which you can then apply the propper if/then statement to only email the 'hard-coded' DU for that specific Process instance Id.


Naturally, the 'gotcha' is ALL of the user's emails will fail...not just those related to K2 processes.But you only need to throw one process in error (to enable the 'Repair Error' option), then re-add the email account info to restore email functionality to that user.

Badge +9

Hmm tricky to fix.


If you want to change back the code without publishing a new version, you probably need to find a creative way to trigger an error on one of the process instances.


 e.g. try blocking the permissions to the email server's SMTP port for any connections from the K2 server.


Once you have an instance in error at the same event, you can "fix" back your code and maybe try to redirect the activity back to the same activity again to re-trigger the email to the right user.  However, there are a lot of gotchas with doing this (e.g. the GotoActivity will wipe out any parallel processing), so you need to think this through based on your own process flow.

Reply