Skip to content

Latest commit

 

History

History
88 lines (59 loc) · 2.15 KB

README.adoc

File metadata and controls

88 lines (59 loc) · 2.15 KB
tags projects
rest
spring-framework

Travis-CI

Build Status

What you’ll build

You’ll build a service that will accept HTTP GET requests at:

http://localhost:8080/reports/PieChartReport/?format=pdf&MaxOrderID=10800

and respond with a link:Jasper Report Document in the format you specified (pdf / html / csv / xls / xlsx)

You can customize the request with optional parameters in the query string:

http://localhost:8080/reports/PieChartReport/?format=pdf&MaxOrderID=10800&ReportTitle=test&param2=test&param3=test

It is important that these parameters are supported in the SQL query string in the underlying .jrxml Jasper template

What you’ll need

  • java_version: 1.8

  • maven: >3: (for building the project if you wish to)

How to build it

use the following command in the cloned directory:

mvn package

How to run the DEMO package

Download the latest release from here: Releases

Download the "config" and "demo" directories from github

Folder structure should look like this:

- config
    --application.properties
- demo
    --data
    --fonts
    --images
    --reports
- jasper-reporting-service.jar

Install the FONTS on your system from demo/fonts

Run SQL from data/h2_data.sql against your Demo-Database (in-memory H2 database is pre-configured!)

If you wish to use the pre-configured H2 database activate the "h2 console" in config/application.properties and run the SQL script in the GUI: localhost:8080/h2

Run with command:

java -jar jasper-reporting-service.jar:

test with:

http://localhost:8080/reports/PieChartReport/?format=pdf&MaxOrderID=10800

You should get a nice looking PDF-Report looking like this:

example pdf report