Jump to content
We've recently updated our Privacy Statement, available here ×

masteryoda

Members
  • Posts

    4
  • Joined

  • Last visited

masteryoda's Achievements

  1. edit: this has been mistakenly selected as the best answer...... this is the question i am asking. I am using the following program in html <!DOCTYPE html><html><head><script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script><script>$(document).ready(function () { $.get("http://localhost:8080/jasperserver-pro/rest/login?j_username=jasperadmin&j_password=jasperadmin", function() { alert("Logged in! Do stuff here!") }).fail(function() { alert("Cannot login!") });}});</script></head><body> </body></html> but the page is not showing anything...
  2. I have tried a lot of URL mentioned in the document --http://community.jaspersoft.com/sites/default/files/docs/jasperreports-server-web-services-guide_1.pdf#pdfjs.action=download. but none of them are working. many are showing the error of page not found.eg.-- http://localhost:8080/jasperserver/rest/serverinfo/ When i tried to find the rest in the jasperserver folder it was not there. can somebody tell me how can i integrate rest with jasper server . I am using version 5.1.0. thanks in advance.....
  3. Hi pssp25 I have logged in using the username- jasperadmin and password- jasperadmin as specified in the Consts.java of the example. and i have also checked the credentials from the test. but still it is not working. i am new to jasperserver and have read the documents but cannot figure out what is the problem ... please any suggestions....
  4. the example given here -- http://community.jaspersoft.com/wiki/getting-started-rest-web-service-api is not working . i have done everything mentioned there but it is giving this error E:restapicodesample>mvn test[iNFO] Scanning for projects...[iNFO][iNFO] ------------------------------------------------------------------------[iNFO] Building REST Code Sample 1.0-SNAPSHOT[iNFO] ------------------------------------------------------------------------[WARNING] The artifact org.apache.commons:commons-io:jar:1.3.2 has been relocated to commons-io:commons-io:jar:1.3.2[iNFO][iNFO] --- maven-resources-plugin:2.6:resources (default-resources) @ RESTCodeSample ---[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent![iNFO] skip non existing resourceDirectory E:restapicodesamplesrcmainresources[iNFO][iNFO] --- maven-compiler-plugin:2.5.1:compile (default-compile) @ RESTCodeSample ---[iNFO] Nothing to compile - all classes are up to date[iNFO][iNFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ RESTCodeSample ---[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent![iNFO] skip non existing resourceDirectory E:restapicodesamplesrctestresources[iNFO][iNFO] --- maven-compiler-plugin:2.5.1:testCompile (default-testCompile) @ RESTCodeSample ---[iNFO] Nothing to compile - all classes are up to date[iNFO][iNFO] --- maven-surefire-plugin:2.12.4:test (default-test) @ RESTCodeSample ---[iNFO] Surefire report directory: E:restapicodesampletargetsurefire-reports ------------------------------------------------------- T E S T S-------------------------------------------------------Running com.jaspersoft.jasperserver.rest.sample.BasicResourceCRUDTestlog4j:WARN No appenders could be found for logger (com.jaspersoft.jasperserver.rest.sample.RestAPIUtils).log4j:WARN Please initialize the log4j system properly. INFO [com.jaspersoft.jasperserver.rest.sample.RestAPIUtils] sending Request. url: http://localhost:8080/jasperserver-pro/rest/resource req verb: PUT INFO [com.jaspersoft.jasperserver.rest.sample.RestAPIUtils] response status line: HTTP/1.1403 ForbiddenTests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.353 sec <<< FAILURE!com.jaspersoft.jasperserver.rest.sample.BasicResourceCRUDTest Time elapsed: 0.353 sec <<<FAILURE!java.lang.AssertionError: basic response check did not pass at org.junit.Assert.fail(Assert.java:91) at org.junit.Assert.assertTrue(Assert.java:43) at com.jaspersoft.jasperserver.rest.sample.RestAPIUtils.sendAndAssert(RestAPIUtils.java:123) at com.jaspersoft.jasperserver.rest.sample.RestAPIUtils.sendAndAssert(RestAPIUtils.java:117) at com.jaspersoft.jasperserver.rest.sample.BasicResourceCRUDTest.setUp(BasicResourceCRUDTest.java:47) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41) at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:27) at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31) at org.junit.runners.ParentRunner.run(ParentRunner.java:236) at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252) at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141) at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189) at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165) at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85) at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115) at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75) Results : Failed tests: com.jaspersoft.jasperserver.rest.sample.BasicResourceCRUDTest: basic response check did not pass Tests run: 1, Failures: 1, Errors: 0, Skipped: 0 [iNFO] ------------------------------------------------------------------------[iNFO] BUILD FAILURE[iNFO] ------------------------------------------------------------------------[iNFO] Total time: 1.538s[iNFO] Finished at: Tue Jul 23 18:11:36 IST 2013[iNFO] Final Memory: 7M/111M[iNFO] ------------------------------------------------------------------------[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project RESTCodeSample: There are test failures.[ERROR][ERROR] Please refer to E:restapicodesampletargetsurefire-reports for the individual test results.[ERROR] -> [Help 1][ERROR][ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.[ERROR] Re-run Maven using the -X switch to enable full debug logging.[ERROR][ERROR] For more information about the errors and possible solutions, please read the following articles:[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureExceptionE:restapicodesample> //-------------------------------------------------------------------------
×
×
  • Create New...