Jump to content

spring confiration error whie js_import.sh


raja_2035

Recommended Posts

1.Spring configuration files       2.All of the JasperServer jar files and JDB drivers                                                        in sping configuration we have to chane scripts/config/applicationContext-*.xml . but we dont hava any clear decription about what are the changes to be made.   i got the below exception while executing  .js-import.sh

 

error is:

./js-import.sh supermart_reports.zip
19:51:10,510 ERROR BaseExportImportCommand:45 - org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 1 in XML document from class path resource [supermart_reports.zip] is invalid; nested exception is org.xml.sax.SAXParseException: Content is not allowed in prolog.
org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 1 in XML document from class path resource [supermart_reports.zip] is invalid; nested exception is org.xml.sax.SAXParseException: Content is not allowed in prolog.
Caused by: org.xml.sax.SAXParseException: Content is not allowed in prolog.
        at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
        at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
        at org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:76)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:388)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:340)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:317)
        at com.jaspersoft.jasperserver.export.BaseExportImportCommand.registerConfig(BaseExportImportCommand.java:143)
        at com.jaspersoft.jasperserver.export.BaseExportImportCommand.createSpringContext(BaseExportImportCommand.java:115)
        at com.jaspersoft.jasperserver.export.BaseExportImportCommand.process(BaseExportImportCommand.java:76)
        at com.jaspersoft.jasperserver.export.ImportCommand.main(ImportCommand.java:43)
.

 

 

i had a proble while  setting configuration for sample reports  for inforbright database.

i had proble with 2 configurations in jasperserverCommunity additon install guide chapter 10 .

 

2. inthis  i didnt find the below  sturcure in my  jasper server

<js-install>/scripts/lib

Drivers can be found here:

<js-install>/scripts/drivers

<js-install>/buildomatic/conf_source/db/<db-type>/jdbc

 

 

Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

The import command should be like the following:

 

./js-import.sh --input-zip supermart_reports.zip

 

Regarding the second question:

<js-install>/scripts/lib

Drivers can be found here:

<js-install>/scripts/drivers

<js-install>/buildomatic/conf_source/db/<db-type>/jdbc

 

If you did your original installation from the installer, then there will be no "buildomatic" directory. Planning to add for the next release so that everything is consistent.

However, if you are using mysql or postgresql then there are already jdbc drivers in the scripts/lib dir.

 

Link to comment
Share on other sites

Thank you Tkavanagh for quick reply.

 

but this problem is still existing even i am using

./js-import.sh --input-zip supermart_reports.zip

 

can u please tell me what are the configuration changes need done for theese file.

scripts/config/applicationContext-*.xml .

 

In insatallation guide we have a note that we need to change these files.

but we dont hava any clear decription about what are the changes to be made.

 

regards

Raja k

Link to comment
Share on other sites

Are you using the infobright database? You will need to track down the settings for the jdbc parameters, such as uri. This is found in the scripts/config/js.jdbc.properties file. Here is what it looks like for MySQL:

 

    metadata.jdbc.driverClassName=com.mysql.jdbc.Driver
    metadata.jdbc.url=jdbc:mysql://localhost:3306/jasperserver?useUnicode=true&characterEncoding=UTF-8
    metadata.jdbc.username=jasperdb
    metadata.jdbc.password=password
 

You will need to find the propert hibernate setting which is also in the same file:

 

    metadata.hibernate.dialect= <setting for infobright>

 

And you need to make sure your jdbc driver is in the scripts/lib dir.

 

The only file you need to change is js.jdbc.properties. You do not need to change any of the ApplicationContext-*.xml files.

Also, what App Server are you running?

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