Jump to content
Changes to the Jaspersoft community edition download ×

Jaspersoft server 500 null response for rest v2 call

Recommended Posts

Hi Guys,

I am trying to pull PDF exports from Jaspersoft server by making REST V2 calls from my application. But for some reports i get HTTP 500 null error and a huge HTML content in response. I have pasted an excerpt of the HTML content below this mail, can anyone please help me understand this issue and provide me some resolution for this.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
        <title>TIBCO Jaspersoft: Internal Server Error</title>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <meta http-equiv="X-UA-Compatible" content="IE=8"/>
        <link rel="shortcut icon" href='/jasperserver-pro/_themes/D2A0689A/images/favicon.ico' />
            <link rel="shortcut icon" href="favicon.ico" />
<meta name = "viewport" content="user-scalable=no, initial-scale=1.0, maximum-scale=1.0, width=device-width">
<meta name="apple-mobile-web-app-capable" content="yes"/>
        <link rel="stylesheet" href="/jasperserver-pro/runtime/4AF93600/themes/reset.css" type="text/css" media="screen">
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/themeMinimal.css" type="text/css" media="screen,print"/>
        <!--[if IE 7.0]>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/overrides_ie7.css" type="text/css" media="screen"/>
        <!--[if IE 8.0]>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/overrides_ie8.css" type="text/css" media="screen"/>
        <!--[if IE]>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/overrides_ie.css" type="text/css" media="screen"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/jasper-ui/jasper-ui.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/jquery-ui/jquery-ui.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/panel.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/menu.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/simpleColorPicker.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/webPageView.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/notifications.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/attributes.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/importExport.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/manageTenants.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/pagination.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/dashboard/designer.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/dashboard/viewer.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/dashboard/canvas.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/dashboard/toolbar.css" type="text/css" media="screen,print"/>
        <link rel="stylesheet" href="/jasperserver-pro/_themes/D2A0689A/overrides_custom.css" type="text/css" media="screen"/>
<script type="text/javascript">
    var JRS = {};
    var __jrsConfigs__ = {
        i18n: {},
        localContext: {},
        isIPad: "",
        contextPath: "/jasperserver-pro",
        runtimeContextPath: "/jasperserver-pro/runtime/4AF93600",
        organizationsFolderUri: "",
        publicFolderUri: "",
        tempFolderUri: "",
        enableAccessibility: "",
        organizationId: "",
        commonReportGeneratorsMetadata: [],
        templatesFolderUri: '',
        defaultTemplateUri: '',
        advNotSelected: "To generate a report, first select an Ad Hoc view.",
        templateNotSelected: "To generate a report using template generator, first select an Template.",
        calendar: {
            userLocale: "en_US",
            timepicker: {
                timeText: 'Time:',
                hourText: 'Hour',
                minuteText: 'Minute',
                secondText: 'Second',
                currentText: 'Now',
                closeText: 'Close',
                timeFormat: 'HH:mm:ss',
                dateFormat: 'yy-mm-dd',
                separator:' '
            i18n: {
                bundledCalendarTimeFormat: 'HH:mm:ss',
                bundledCalendarFormat: 'yy-mm-dd'
        webHelpModuleState: {
            contextMap: {"default":"100","bi_overview":"100","login":"150","legacy_dashboard":"200","ad_hoc":"300","domain":"500","search":"600","analysis":"700","admin":"800","repo":"900","dashboard":"1000"},
            hostURL: 'http://help.jaspersoft.com/js-help-v6-en/',
            pagePrefix: 'Default_CSH.htm#'
        urlContext: "/jasperserver-pro",
        defaultSearchText: "",
        serverIsNotResponding: "The server is slow or isn't responding. Confirm that you want to continue."
    // dirty hack to get path to current theme
    __jrsConfigs__.currentThemePath = "_themes/D2A0689A/theme.css".split("/").slice(0, -1).join("/");
    __jrsConfigs__.isProVersion = "true" === "true" ? true : false;
    __jrsConfigs__.userLocale = "en_US";
    __jrsConfigs__.userTimezone = "Zulu";
    __jrsConfigs__.isFreeOrLimitedEdition = false;
    //TODO: get it from the server
    __jrsConfigs__.avaliableLocales = ["de", "en", "es", "fr", "it", "ja", "ro", "zh_TW", "zh_CN"];
    __jrsConfigs__.localeSettings = {
        locale: "en_US",
        decimalSeparator: "" || ".",
        groupingSeparator: "" || ",",
        timeFormat: "HH:mm:ss",
        dateFormat: "yy-mm-dd",
        timestampSeparator: " "
    __jrsConfigs__.heartbeatInitOptions = {
        baseUrl: "/jasperserver-pro",
        showDialog: false,
        sendClientInfo: false
            __jrsConfigs__.initAdditionalUIComponents = true;
    __jrsConfigs__.heartbeatInitOptions.sendClientInfo = true;
    __jrsConfigs__.flowExecutionKey = "";
    if (window.localStorage && window.localStorage.previousPageHash){
        window.location.hash = window.localStorage.previousPageHash;
        delete window.localStorage.previousPageHash;
        <script type="text/javascript" src="/jasperserver-pro/runtime/4AF93600/optimized-scripts/bower_components/requirejs/require.js"></script>
<script type="text/javascript" src="/jasperserver-pro/runtime/4AF93600/optimized-scripts/require.config.js"></script>
<script type="text/javascript">
        baseUrl: "/jasperserver-pro/runtime/4AF93600/optimized-scripts"
</script> ......................

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

500 is not a null reponse, it is a Internal Server Error reponse. 
Is your server running without any issues. 
Maybe check the jasperserver logs and the tomcat logs. 

Lol in the html reponse you have this below, might be the reason for the internal server error. 
 // dirty hack to get path to current theme  


Also maybe try some and test other rest calls besides a report call, to identify if it is a general server issues or specfic to a given area or request. 
Try  GET http://<host>:<port>/jasperserver[-pro]/rest_v2/serverInfo    - If you still get issue with this one, you definetly have a server issues. 
Maybe to a rest login request there after.
Then maybe just do repo folder request. 
Then a report request to see that is working. 
Th other thing is when you do the pdf export request, maybe share your rest call requets, obviously replace the sensative info for dummy into. 

You could also enable more logging on your jasperserver , i.e. rest calls on debug mode, so you could see each request made etc.

Link to comment
Share on other sites

Are you trying to pull pdf from a report designed by Jaspersoft Studio or an Adhoc Report?

You've said the some reports are OK so the chance is particular to a report. It may be the data source for the report.

Check JasperReports Server log for a caused by error message. The log is located in the following directory.

/<the directory where you've installed JasperReports Server>/webapps/jasperserver-pro/WEB-INF/logs



Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...