BIRT Reports - How to schedule them and send by email?
Asked Answered
N

2

9

I am currently creating reports with Eclipse embedded Report Designer for BIRT reports. In my next step, I would like to schedule this reports in such a way:

  1. It will run once per day on a set time.
  2. It will be produced as PDF.
  3. It will be sent by email to a concrete email address.

I am working on Windows. Is it possible to do all of that by running bash script as a scheduled task in Windows Task Scheduler? Thanks.

Nonconformity answered 23/10, 2014 at 7:14 Comment(2)
you could run BIRT on a tomcat server and add a scheduled task to the tomcat.Luzon
but how will I schedule that it will be sent to a concrete email address?Nonconformity
C
3

You can either do this yourself with the free BIRT runtime or download the free BIRT iHub F-Type server at http://www.actuate.com/resources/product-downloads/.

How to use the BIRT runtime:

  1. Download the BIRT runtime and install it. http://download.eclipse.org/birt/downloads/#runtime
  2. Test the runtime installation (if you use Windows it will look like the following)

    C:\birt\ReportEngine>echo %BIRT_HOME%
    C:\birt
    
    C:\birt\ReportEngine>genReport.bat
    
    C:\birt\ReportEngine>ECHO off
    Help for ReportRunner
    
    --mode/-m [run|render|runrender] [options] [rptdesign|rptdocument]
        The default mode is runrender.
    To see options for run mode, use:
        --help/-h run
    To see options for render mode, use:
        --help/-h render
    To see options for runrender mode, use:
        --help/-h runrender
    Print current message, use --help/-h
    
  3. Test the runtime in console with a job like

    C:\birt\ReportEngine>genReport.bat -o test.pdf -f PDF new_report.rptdesign
    
  4. Create a batch file for your job (the sample you ran earlier).

  5. In Windows Task Scheduler, make a task to run the batch file for your job.
  6. Run your task on demand to make sure it runs correctly.

Windows task scheduler does have a simple email function but you will probably have to find a better program to send the generated file as email. Then add the script to run this program to your batch file. Make sure you read up on how to configure a task for Windows task scheduler correctly.

Ciprian answered 22/4, 2015 at 14:36 Comment(0)
P
1

It sounds like you need a way of

  • running the a BIRT report, through the BIRT reporting engine,
  • using scheduler to control execution of the report a on a particular schedule
  • specifying output format
  • and specifying how the output should be delivered in the scheduled job.

You could role your own or you could use a Reporting/BI server that already has all of those capabilities. Depending on your other needs, this may be overkill or exactly right. I am using SpagoBI for that exact purpose. SpagoBI supports BIRT as one of the reporting formats and engines. It uses the quartz scheduler, and does support emailing a PDF version of a report to a specific email address (or list). You might also look into iHub or other products.

http://www.spagobi.org/

http://birt.actuate.com/products/birt-ihub

In SpagoBI, you would deploy your BIRT report to the SpagoBI server from SpagoBI Studio. Then, in SpagoBI Server you would setup the parameters on the report document and create a schedule for the report. On the schedule, you would specify the parameters (if other than default), a schedule, output format, and how you want the output stored/sent.

Pteropod answered 20/4, 2015 at 13:56 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.