Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Send email from Custom Build Task

Hi,

I'm working on a custom ant task for a customer. One of their requirements is to have some type of notification when builds fail. Are there API's to utilize RTC Mail Notifications for something like this?

Ant includes an EmailTask, so if I could simply pull the mail host and port that would work too. I'd like to make the code as robust as possible and not have to hard code anything.

Thanks,
Scott

0 votes



3 answers

Permanent link

...
One of their requirements is to have some type of notification when builds fail.
...


Not sure if you are aware, but if you are using a build definition in RTC, you can add the "Email Notification" post-build participant to the build definition. On this "Email Notification" page, you can add a new notification criteria, and check-off "Send notifications when a build as completed" --> "Only if there are errors" (assuming that's what you want), or you can customize it as you see fit. You can do this per build definition, or you can set this up at the project area level so that it applies to all build definitions in that project area. To do this, open the project area editor --> Process Configuration --> Project Configuration --> Configuration Data --> Build --> Email Notification.

1 vote


Permanent link
Scott,

the com.ibm.team.repository.service.MailSender seems not to be availabe in the client libraries. I would assume you would not be able to access the advanced properties either. Your task could leave some data in the build result and have a server side extension to do the e-mail. Otherwise, I assume, you would have to use the Ant task and store the mail information in the build scripts.

0 votes


Permanent link
David,

thanks for the hint, I was not aware and I will look into it!

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 10,938

Question asked: Apr 20 '12, 4:46 p.m.

Question was seen: 6,179 times

Last updated: Apr 20 '12, 4:46 p.m.

Confirmation Cancel Confirm