iReport 5.x with Mongo Authentication on Replica Set - authentication failure

Hi,

I am testing iReport 5.x on a Mongo Replica Set with authentication enabled. An error is being returned when I test the connection:

"Error: net.sf.jasperreports.engine.JRException: not authorized for query on... [our database name] .system.namespaces "

I can connect successfully on a MongoDB without authentication enabled. I can connect with other tools to the authenticated mongo replica set with no issues.

Has anyone else seen this issue, or have a suggestion for resolution. Two constraints are (1) must include replicaset usage and (2) must include authentication.

Best,

John

jcicilio's picture
Joined: Jun 10 2013 - 7:29am
Last seen: 9 years 9 months ago

3 Answers:

I too have this issue, and also the same signs of trouble attaching to mongo through the Jasperserver-pro (assume its the same driver being called)

 Scenario: Rep-set with Auth on. can connect with other tools, locally. just not this MongoDB connector within Ireport 5.x /Jasperserver 5.1.0

 

 I have attempted 3rd party connectors with same results.

 

 

coryc_1's picture
22
Joined: Nov 26 2012 - 11:10am
Last seen: 8 years 8 months ago

I am also having this issue.

I am trying to hook up a brand new AWS Jasperserver service to my 2.4.1 MongoDB replica set hosted on MongoHQ.

Any idea if and when this might be resolved?

Is there a workaround?

 

carlt's picture
13
Joined: Jul 29 2013 - 8:47pm
Last seen: 9 years 1 month ago

I seem to have posted an answer rather than a comment

carlt - 9 years 8 months ago

This is a known bug, and comes from an issue between the JRS mongo driver in iReport and the error code changes in Mongo 2.4.

Attached is a replacement Jar for the JS MongoDB datasource that fixes this issue and allows you connect to MongoDB with replicasets as well as mongo 2.4. To install it; just replace your "js-mongodb-datasource-1.0.0.jar" in both iReport and JasperServer with the attached Jar.

in iReport the file is located in: /modules/ext/js-mongodb-datasource-1.0.0.jar
and in JasperServer in: /webapps/jasperserver-pro/WEB-INF/lib/js-mongodb-datasource-1.0.0.jar

This bug is fixed in 5.2

Attachments: 
AttachmentSize
File js-mongodb-datasource-1.0.0.jar40.59 KB
marianol's picture
15800
Joined: Sep 13 2011 - 8:04am
Last seen: 4 years 6 months ago
Feedback