Remedy DST Time addition problems

When the DST match doesn’t appear to add up:

Here’s the original ARS List post I put out:

Fortunately this issue SHOULD be very straight forward.

Unfortunately – it isn’t.

There’s a button that calculates a person’s period of eligibility to make changes to their HR benefits, etc.  You enter their employment anniversary date and hit the button and this performs a calculation:

$My Date$ – 864000 (i.e., minus 10 days).

Here’s the interesting thing – when the date entered is  Daylight savings time – 3/15 this spring – the calculated value for the date time field returns 3/4/2010 11:00:00 PM.  Normally all of the times in this date/time field are left at 12:00:00 AM and are unused.

Technically speaking the calculation is EXACTLY correct.  3/4/2010 11:00:00 PM is exactly 10 days before 3/15/2010 12:00:00 AM – because 3/15 has an “extra” hour added that is a figment of our collective imagination.  Technically DST doesn’t happen until 2:00 AM though but that’s a matter for another time.

I was thinking about changing the times on these to default to 3:00:00 AM instead of 12:00:00 AM – but I’m open to suggestions.

As it turns out the solution was really simple – the original math for the “Set Fields” calculation did this:

$My Date$ – 864000

I just switched it to use the Remedy DATEADD function and added negative 10 days – this only evaluates the “date” portion of the value and ignores DST:

DATEADD(“day”,-10,$My Date$)

Thanks to C.B. on the arlist for the suggestion.


Remedy Email Engine SSL Error

SSL Errors

We had the email engine working fine for quite some time (ARS 7.1 on Solaris).

Then – one magical day after server patching – it quit.  The error messages reported in the email error logs form said this:

Connect failed
javax.mail.MessagingException: Connect failed;
nested exception is:
javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at com.sun.mail.pop3.POP3Store.protocolConnect(POP3Store.java:148)
at javax.mail.Service.connect(Service.java:275)
at javax.mail.Service.connect(Service.java:156)
at com.bmc.arsys.emaildaemon.ReceiverModule.initializeIncommingMailbox(ReceiverModule.java:1876)
at com.bmc.arsys.emaildaemon.ReceiverModule.doWork(ReceiverModule.java:216)
at com.bmc.arsys.emaildaemon.ThreadBase.run(ThreadBase.java:288)
at java.lang.Thread.run(Thread.java:595)

….and it looked like this…

SSL Error

Remedy Email Engine SSL Error

As it turned out – it was a pretty easy fix.

For some reason the patching (OS level patching by another group) had overwritten our CACERTS file.  We didn’t notice immediately because the replacement file had approximately the right size and date.

So – if you run into the “PKIX path building failed:  unable to find valid certification path to requested” error – re-import or otherwise replace your SSL certificates.

-William


How to add email attachments to incoming emails

Attachments for incoming emails

A while back I wrote a long series on how to process incoming emails into Remedy Incident Management.

I received a number of positive responses to that as well as a lot of questions.  One of the frequent questions was “How do we put attachments in?”.

Robert Fults of Florida International University was nice enough to provide a complete guide on how to do this.  The material below this paragraph was all provided by him.  Thanks Robert!

Getting your incoming email to accept a single attachment

First, add a new tab to the page holder called Attachments.

Remedy email attachment (click for full size)

Remedy email attachment (click for full size)

You will need a Character field to store the Email GUID and temp field to store the Attachment Unique ID or Attachment ID (I used the unique ID).  You also need a place to store those attachments so we add an attachment pool.  NOTE: I added an attachment table for further enhancement (I am planning to do a table loop to get the Attachment IDs of multiple attachments, which will change the way this works to some extent.)

Now we can start putting together some workflow.  First, we need to get the Email GUID from the AR System Messages form.  Remember that filter we created to get all the data pushed to our staging form? Just add this field to the list.  Mine has Email GUID = $Unique Identifier$. Done.

Now we create a filter that fires on submit to our staging form, in my case IncomingEmailProcessing, which will get the attachment to the staging form. It has two Set Fields actions.  The first will get the Attachement ID from the AR System Email Attachment join form.

Remedy Filter action 1 (click for full size)

Remedy Filter action 1 (click for full size)

The next Set Fields action will take the attachment ID and search the AR System Email Attachments form and get the attachment.

Remedy filter action 2 (click for full size)

Remedy filter action 2 (click for full size)

At this point your processing form should be collecting an email attachment. Now, how do we get it to the ticket?  First we need to make a correction: if you are using AR System 7.1, you need to modify filter HPD:HIJ:ModifyIncident_210_CreateWorklog to push z2AF Work Log01 = $SRAttachment (or whatever you name the attachment fields if you add more, point is that you need to push the attachment field).

Now we can go back to the filter we use to create new tickets from the data on our staging form, in my case +HPD:IncomingEmailCreateNewIncident, and add some new fields to it.

z2AF_Act_Attachment_1 = $attachment field1$

z1D_WorklogDetails="Incident submitted via Email" (or whatever you like, it need to contain something)

z1D_View_Access=Internal or Public (your choice)

z1D_CommunicationSource=Email (for clarity)

z1D_Activity_Type=Customer Communication (for clarity)

 And that takes care of New Incident requests. Now for incident updates.  Go to the filter where you processed updates, in my case +HPD:IncomingEmailModifyIncident, and add the attachment fields.

SRAttachment=$attachment field1$

 That’s it.  If you know how to use table loops you can copy the attachment table from the AR System Email Messages form and change the qualification to ( ‘Source ID2′ = $EmailGUID$) AND ( ‘Type’ = “Email”) which will populate it the table with the relevant attachments.  From there you change your work flow to walk the table and get the attachment IDs and attachments one at a time.  Then you could push them all at once to the appropriate places assuming you have added the necessary attachment fields to the attachment pool.

 

-Robert Fults

rfults@fiu.edu

Remedy Developer @ FIU 

 


BMC Remedy ACD Integration via the C API – opening a Display Only form

How to set open a display only field and set fields using the C API

I had posted a question on the ARSList about how to properly format the C API call for “OpenForm” – we were getting errors using it.

Mark Worley – a fellow poster – was kind enough to send me this example which worked and allowed us to fix the problem


Dim arSession as ARUSER.COMAppObj
Dim arForm as ARUSER.ICOMFormWnd
Dim arField as ARUSER.ICOMField
Dim sessionNumber as Long

Set arSession = New ARUSER.COMAppObj
sessionNumber = arSession.Login(“ARUserID”, “ARUserPassword”,False)

arSession.OpenForm sessionNumber, “ARServer”, “Form Name”, ARSubmit , 1
Set arForm = arSession.GetActiveForm
Set arField = arForm.GetFieldById(999999999)
arField.Value = “Value”
arForm.Submit

Auditing in BMC Remedy forms

A BMC Remedy Form Auditing Overview

In previous versions of Remedy it was necessary to do custom workflow and forms in order to “audit” the data contents of a field.  An audit is simply a historical recording of the values of a field in a record.

For example, a “Status” field in an Incident may change to these values over the course of the life of the Incident: 

  • New
  • Assigned
  • Work In Progress
  • Resolved

An “audit” of this field would show the following: 

  • Date/Time of the entry and change
  • User who made the change
  • Updated value

Previous versions of Remedy required custom forms, custom workflow, and various other development efforts in order to accomplish this.  As of Remedy AR Server version 7.x this can be accomplished by a Remedy Developer through configuration of the back end forms.

Setting up Auditing in Remedy 7.x

To implement Auditing in Remedy 7 the following steps need to be performed: 

  1. Identify audit form naming
  2. Identify fields to audit
  3. Identify audit operation
  4. Set up auditing on the form
  5. Set up auditing on the individual fields

Identify Audit Form Naming

The system will automatically create an audit form.  However, the name needs to be specified.  Typically this is the name of the original form plus the word “Audit”.  For example, the HPD:HelpDesk audit form could be named “HPD:HelpDesk Audit”.

Identify Fields to Audit

Identifying the fields to audit is a step that needs careful consideration.  Auditing every field on a form can cause performance issues.  Also, some fields can not be audited.  This includes the core fields (field id 1-6; field 7 – Status – can be audited).

The system automatically adds some fields to the audit table in order to facilitate auditing.  These include the user, Audit time/date, and other information.

Typically you will want to audit application fields that are used for reporting or quality analysis.  An example of this includes: 

  • Assigned to Group/Person
  • Status
  • Classification

Identify Audit Operation

There are three possible audit operations.  For each field identified in the previous step we need to identify the audit operation to be performed.  The possibilities for an audited field are: 

  • Audit – Whenever a value changes in this field the “Audit” operation will take place.  This means a new record will be created in the audit table and include this value.
  • Copy – Any time an audit is triggered this field will be copied.  For example, if the status changes from “New” to “Assigned” but the “Assigned to User” does not change but was set to “Copy” the “Assigned to User” would still copy to the audit form.  This is the preferred setting for data that may not change but is wanted in the audit log.
  • Audit and Copy – A copy of the data is triggered every time this field changes or whenever another field triggers an audit operation.  This is the preferred setting for data that is likely to change and is in the audit log.

Set up Auditing on the Form

Setting up auditing for a particular form requires Remedy Administrator access.  To turn on auditing you must first log into Remedy Administrator and open the form.

Once the form is open select the “Form Properties” window.  Then select the “Audit” tab: 

Remedy Form Auditing

Remedy Form Auditing

Check the “Enable” box to turn on Auditing.

For the “Audit style” select “Form”.  This means a record-based audit style will be used.

The other option is “Log”.  Log auditing records all information to a single field and this is non-reportable and has limited usefulness.

Enter the name of the “Audit Form” that you previously determined (e.g., “HPD:HelpDesk Audit”).

If necessary enter a qualification.  For example, you may only want to audit records that have a classification of “Security Issue”.  A sample qualification might be:

‘Categorization Tier 1′ = “Security Issue”

When done press “OK” and save the form.  The audit form will automatically be created.

Set Up Auditing on the Individual Fields

After turning on auditing and saving the form you need to configure each individual field that is identified for auditing.  This also must be done in the Remedy Administrator tool. 

Open the form in the Remedy Administrator tool.  Select the first field that needs to be audited.  Then select the “Field Properties” button and go to the “Attributes” tab: 

Auditing Options

Auditing Options

Select the “Audit Option” identified earlier for this field (“Audit”, “Copy”, or “Audit and Copy”). 

Repeat this step for each field that needs to be audited and save the form.

It is also possible to set up multiple fields at the same time.  To do this follow these steps: 

  1. Open the form (auditing for the form needs to be turned on)
  2. Go to the “Form/Multiple Field Properties” menu option 
  3. Select each field that needs to be audited and change the “Audit Option” to the appropriate operation identified previously.
  4. Save the form when finished.

 

Audit multiple fields in BMC Remedy

Audit multiple fields in BMC Remedy

Final Steps

After completing the steps above auditing is configured but may not be completely useful.  For example it may be necessary to create a join form with the original form and the audit form to facilitate reporting.

To test the auditing you can create a record in the original form.  Then change the value of a field set to be audited and re-save the record.

Check the audit form.  Each action should cause a new audit entry.