Jump to content
Changes to the Jaspersoft community edition download ×

Jasper server scheduling report throws validation error on contentRepositoryDestination.folderUR


kothany

Recommended Posts

I tried to schedule a report with rest v2 on JRS 7.1.1

1. url: http://127.0.0.1:8083/jasperserver/rest_v2/jobs

2. body  :

{  
   "id":null,
   "version":null,
   "username":null,
   "label":"My Report",
   "description":"Scheduling a report",
   "creationDate":null,
   "baseOutputFilename":"ScheduledTestReport",
   "outputLocale":null,
   "repositoryDestination":{  
      "folderURI":null,
      "id":null,
      "outputDescription":null,
      "overwriteFiles":null,
      "sequentialFilenames":null,
      "version":null,
      "timestampPattern":null,
      "saveToRepository":null,
      "defaultReportOutputFolderURI":null,
      "usingDefaultReportOutputFolderURI":null,
      "outputLocalFolder":null,
      "outputFTPInfo":null
   },
   "mailNotification":{  
      "bccAddresses":null,
      "ccAddresses":null,
      "toAddresses":{  
         "address":[  
            "foo@foo.com"
         ]
      },
      "version":null,
      "id":102,
      "includingStackTraceWhenJobFails":true,
      "messageText":"Report has been successfully run and attached.",
      "resultSendType":"SEND_ATTACHMENT_ZIP_ALL",
      "skipEmptyReports":null,
      "skipNotificationWhenJobFails":null,
      "subject":"My Report",
      "messageTextWhenJobFails":"Reports recevied an Error"
   },
   "source":{  
      "reportUnitURI":"/reports/MyReports/reports/sample/orgsample/finReport",
      "parameters":{  
         "parameterValues":{  
            "id":[  
               "105"
            ],
            "User_Id":[  
               "FOO"
            ]
         }
      }
   },
   "outputFormats":{  
      "outputFormat":[  
         "PDF"
      ]
   },
   "trigger":{  
      "simpleTrigger":{  
         "id":null,
         "version":null,
         "timezone":null,
         "calendarName":null,
         "startType":2,
         "startDate":"2019-06-27 14:32",
         "endDate":null,
         "misfireInstruction":null,
         "occurrenceCount":1,
         "recurrenceInterval":null,
         "recurrenceIntervalUnit":null
      }
   },
   "outputTimeZone":null
}

3. Headers :

content-type: application/job+json
accept: application/job+json
X-HTTP-Method-Override: PUT
authorization: Basic ........(using the admin username and password for authentication)

and  response:

 

{

"error": [  {

"errorCode": "error.not.empty",

"defaultMessage": "The value cannot be empty",

"field": "contentRepositoryDestination.folderURI"

}],

}

The same request works with JRS 6.4.0 and the job is getting scheduled with no issues. 

 

 

 

 

Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

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...