Jump to content
Changes to the Jaspersoft community edition download ×

christopher.g.kennedy

Members
  • Posts

    15
  • Joined

  • Last visited

christopher.g.kennedy's Achievements

Apprentice

Apprentice (3/14)

  • Week One Done
  • One Month Later
  • One Year In
  • First Post Rare
  • Collaborator Rare

Recent Badges

0

Reputation

  1. Hi, Please advise. I upload a security domain file and submit the domain and get this error: "Domain security references an invalid object [JoinTree_1]." Thank you, Chris Kennedy christopher.g.kennedy@state.ma.us
  2. I had the same error condition when I changed my tenant id. To fix, I ran an oracle update: update jitenant set tenantalias = 'organization_1', tenantid = 'organization_1', tenantname = 'Organization',tenanturi='/organization_1', tenantfolderuri='/organizations/organization_1' where id = 2; commit;
  3. order by clause will return the rows you want in your limitted subset query, or additional where clauses. It may be data dependent.
  4. At the oracle plsql level you can set rownum <= x in the where clause in your jrxml file. The following will return 5 itemnames from an item table when the user enters rowlimit = 5: <queryString> <![CDATA[selectitemname from items where rownum <= $P{rowlimit};]]></queryString>Hope this helps, Chris Kennedy
  5. I have an external authentication/authorization authority which stores the password as SHA-2:xxx where xxx is 64 bytes (e.g. SHA-2 SHA-512) with a 32 byte variable salt also hex encoded. Can someone discuss how to configure jasper server to use this external oracle to authenticate a user for jasperserver, please let me know if you need further information Thanks Chris Kennedy.
  6. Hi Fabrice. To activate verbositye, I added to: C:Jaspersoftjasperreports-server-6.2.0apache-tomcatwebappsjasperserver-proWEB-INFlog4j.properties log4j.logger.org.springframework.security=DEBUG, stdout, fileout[/code]Here is my C:Jaspersoftjasperreports-server-6.2.0apache-tomcatwebappsjasperserver-proWEB-INFjs.externalAut.properties: # External authentication properties that can be configured via# the master.properties fileexternal.jdbc.driverClassName=oracle.jdbc.driver.OracleDriverexternal.jdbc.url=jdbc:oracle:thin:@170.154.102.43:1521:STARTERexternal.jdbc.username=______external.jdbc.password=______[/code]Here is what I see in C:Jaspersoftjasperreports-server-6.2.0apache-tomcatlogsjasperreportstomcat-stdout.2016-01-25.txt DEBUG MethodSecurityInterceptor,localhost-startStop-2:159 - Validated configuration attributes2016-01-25 12:47:43,866 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:63 - Error creating connection.org.postgresql.util.PSQLException: The connection attempt failed. at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:225) at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:64) at org.postgresql.jdbc2.AbstractJdbc2Connection.<init>(AbstractJdbc2Connection.java:136) at org.postgresql.jdbc3.AbstractJdbc3Connection.<init>(AbstractJdbc3Connection.java:29) at org.postgresql.jdbc3g.AbstractJdbc3gConnection.<init>(AbstractJdbc3gConnection.java:21) at org.postgresql.jdbc4.AbstractJdbc4Connection.<init>(AbstractJdbc4Connection.java:31) at org.postgresql.jdbc4.Jdbc4Connection.<init>(Jdbc4Connection.java:24) at org.postgresql.Driver.makeConnection(Driver.java:393) at org.postgresql.Driver.connect(Driver.java:267) at java.sql.DriverManager.getConnection(Unknown Source) at java.sql.DriverManager.getConnection(Unknown Source) at org.apache.commons.dbcp.DriverManagerConnectionFactory.createConnection(DriverManagerConnectionFactory.java:75) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDriverManagerConnectionFactory.createConnection(JdbcDriverManagerConnectionFactory.java:36) at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:582) at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:1148) at org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:106) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.TibcoDriverManagerImpl.getOriginalConnection(TibcoDriverManagerImpl.java:197) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.TibcoDriverManagerImpl.unlockConnection(TibcoDriverManagerImpl.java:88) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection(JdbcDataSourceService.java:56) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.BaseJdbcDataSource.setReportParameterValues(BaseJdbcDataSource.java:49) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.setReportParameterValues(JdbcDataSourceService.java:69) at com.jaspersoft.jasperserver.war.common.HeartbeatBean.createDatabaseInfoCache(HeartbeatBean.java:736) at com.jaspersoft.jasperserver.war.common.HeartbeatBean.call(HeartbeatBean.java:480) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.springframework.util.MethodInvoker.invoke(MethodInvoker.java:269) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.JSMethodInvokingJobDetailFactoryBean$MethodInvokingJob.executeInternal(JSMethodInvokingJobDetailFactoryBean.java:247) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.JSQuartzJobBean.execute(JSQuartzJobBean.java:51) at org.quartz.core.JobRunShell.run(JobRunShell.java:213) at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557)Caused by: java.net.UnknownHostException: ci-catalogs.jaspersoft.com at java.net.AbstractPlainSocketImpl.connect(Unknown Source) at java.net.PlainSocketImpl.connect(Unknown Source) at java.net.SocksSocketImpl.connect(Unknown Source) at java.net.Socket.connect(Unknown Source) at java.net.Socket.connect(Unknown Source) at org.postgresql.core.PGStream.<init>(PGStream.java:60) at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:101) ... 31 more2016-01-25 12:47:43,885 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:63 - Error creating connection.org.postgresql.util.PSQLException: The connection attempt failed. at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:225) at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:64) at org.postgresql.jdbc2.AbstractJdbc2Connection.<init>(AbstractJdbc2Connection.java:136) at org.postgresql.jdbc3.AbstractJdbc3Connection.<init>(AbstractJdbc3Connection.java:29) at org.postgresql.jdbc3g.AbstractJdbc3gConnection.<init>(AbstractJdbc3gConnection.java:21) at org.postgresql.jdbc4.AbstractJdbc4Connection.<init>(AbstractJdbc4Connection.java:31) at org.postgresql.jdbc4.Jdbc4Connection.<init>(Jdbc4Connection.java:24) at org.postgresql.Driver.makeConnection(Driver.java:393) at org.postgresql.Driver.connect(Driver.java:267) at java.sql.DriverManager.getConnection(Unknown Source) at java.sql.DriverManager.getConnection(Unknown Source) at org.apache.commons.dbcp.DriverManagerConnectionFactory.createConnection(DriverManagerConnectionFactory.java:75) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDriverManagerConnectionFactory.createConnection(JdbcDriverManagerConnectionFactory.java:36) at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:582) at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:1148) at org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:106) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.TibcoDriverManagerImpl.getOriginalConnection(TibcoDriverManagerImpl.java:197) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.TibcoDriverManagerImpl.unlockConnection(TibcoDriverManagerImpl.java:88) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection(JdbcDataSourceService.java:56) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.BaseJdbcDataSource.setReportParameterValues(BaseJdbcDataSource.java:49) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.setReportParameterValues(JdbcDataSourceService.java:69) at com.jaspersoft.jasperserver.war.common.HeartbeatBean.createDatabaseInfoCache(HeartbeatBean.java:736) at com.jaspersoft.jasperserver.war.common.HeartbeatBean.call(HeartbeatBean.java:480) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.springframework.util.MethodInvoker.invoke(MethodInvoker.java:269) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.JSMethodInvokingJobDetailFactoryBean$MethodInvokingJob.executeInternal(JSMethodInvokingJobDetailFactoryBean.java:247) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.JSQuartzJobBean.execute(JSQuartzJobBean.java:51) at org.quartz.core.JobRunShell.run(JobRunShell.java:213) at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557)Caused by: java.net.UnknownHostException: ci-catalogs.jaspersoft.com at java.net.AbstractPlainSocketImpl.connect(Unknown Source) at java.net.PlainSocketImpl.connect(Unknown Source) at java.net.SocksSocketImpl.connect(Unknown Source) at java.net.Socket.connect(Unknown Source) at java.net.Socket.connect(Unknown Source) at org.postgresql.core.PGStream.<init>(PGStream.java:60) at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:101) ... 31 more2016-01-25 12:48:05,005 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:63 - Error creating connection.java.sql.SQLException: The Network Adapter could not establish the connection at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:412) at oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:531) at oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:221) at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32) at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:503) at java.sql.DriverManager.getConnection(Unknown Source) at java.sql.DriverManager.getConnection(Unknown Source) at org.apache.commons.dbcp.DriverManagerConnectionFactory.createConnection(DriverManagerConnectionFactory.java:75) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDriverManagerConnectionFactory.createConnection(JdbcDriverManagerConnectionFactory.java:36) at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:582) at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:1148) at org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:106) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.TibcoDriverManagerImpl.getOriginalConnection(TibcoDriverManagerImpl.java:197) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.TibcoDriverManagerImpl.unlockConnection(TibcoDriverManagerImpl.java:88) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection(JdbcDataSourceService.java:56) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.BaseJdbcDataSource.setReportParameterValues(BaseJdbcDataSource.java:49) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.setReportParameterValues(JdbcDataSourceService.java:69) at com.jaspersoft.jasperserver.war.common.HeartbeatBean.createDatabaseInfoCache(HeartbeatBean.java:736) at com.jaspersoft.jasperserver.war.common.HeartbeatBean.call(HeartbeatBean.java:480) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.springframework.util.MethodInvoker.invoke(MethodInvoker.java:269) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.JSMethodInvokingJobDetailFactoryBean$MethodInvokingJob.executeInternal(JSMethodInvokingJobDetailFactoryBean.java:247) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.JSQuartzJobBean.execute(JSQuartzJobBean.java:51) at org.quartz.core.JobRunShell.run(JobRunShell.java:213) at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557)Caused by: oracle.net.ns.NetException: The Network Adapter could not establish the connection at oracle.net.nt.ConnStrategy.execute(ConnStrategy.java:359) at oracle.net.resolver.AddrResolution.resolveAndExecute(AddrResolution.java:422) at oracle.net.ns.NSProtocol.establishConnection(NSProtocol.java:672) at oracle.net.ns.NSProtocol.connect(NSProtocol.java:237) at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1042) at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:301) ... 27 moreCaused by: java.net.ConnectException: Connection timed out: connect at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method) at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source) at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source) at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source) at java.net.AbstractPlainSocketImpl.connect(Unknown Source) at java.net.PlainSocketImpl.connect(Unknown Source) at java.net.SocksSocketImpl.connect(Unknown Source) at java.net.Socket.connect(Unknown Source) at oracle.net.nt.TcpNTAdapter.connect(TcpNTAdapter.java:141) at oracle.net.nt.ConnOption.connect(ConnOption.java:123) at oracle.net.nt.ConnStrategy.execute(ConnStrategy.java:337) ... 32 more2016-01-25 12:48:05,012 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:63 - Error creating connection.org.postgresql.util.PSQLException: The connection attempt failed. at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:225) at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:64) at org.postgresql.jdbc2.AbstractJdbc2Connection.<init>(AbstractJdbc2Connection.java:136) at org.postgresql.jdbc3.AbstractJdbc3Connection.<init>(AbstractJdbc3Connection.java:29) at org.postgresql.jdbc3g.AbstractJdbc3gConnection.<init>(AbstractJdbc3gConnection.java:21) at org.postgresql.jdbc4.AbstractJdbc4Connection.<init>(AbstractJdbc4Connection.java:31) at org.postgresql.jdbc4.Jdbc4Connection.<init>(Jdbc4Connection.java:24) at org.postgresql.Driver.makeConnection(Driver.java:393) at org.postgresql.Driver.connect(Driver.java:267) at java.sql.DriverManager.getConnection(Unknown Source) at java.sql.DriverManager.getConnection(Unknown Source) at org.apache.commons.dbcp.DriverManagerConnectionFactory.createConnection(DriverManagerConnectionFactory.java:75) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDriverManagerConnectionFactory.createConnection(JdbcDriverManagerConnectionFactory.java:36) at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:582) at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:1148) at org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:106) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.TibcoDriverManagerImpl.getOriginalConnection(TibcoDriverManagerImpl.java:197) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.TibcoDriverManagerImpl.unlockConnection(TibcoDriverManagerImpl.java:88) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection(JdbcDataSourceService.java:56) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.BaseJdbcDataSource.setReportParameterValues(BaseJdbcDataSource.java:49) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.setReportParameterValues(JdbcDataSourceService.java:69) at com.jaspersoft.jasperserver.war.common.HeartbeatBean.createDatabaseInfoCache(HeartbeatBean.java:736) at com.jaspersoft.jasperserver.war.common.HeartbeatBean.call(HeartbeatBean.java:480) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.springframework.util.MethodInvoker.invoke(MethodInvoker.java:269) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.JSMethodInvokingJobDetailFactoryBean$MethodInvokingJob.executeInternal(JSMethodInvokingJobDetailFactoryBean.java:247) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.JSQuartzJobBean.execute(JSQuartzJobBean.java:51) at org.quartz.core.JobRunShell.run(JobRunShell.java:213) at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557)Caused by: java.net.UnknownHostException: ci-catalogs.jaspersoft.com at java.net.AbstractPlainSocketImpl.connect(Unknown Source) at java.net.PlainSocketImpl.connect(Unknown Source) at java.net.SocksSocketImpl.connect(Unknown Source) at java.net.Socket.connect(Unknown Source) at java.net.Socket.connect(Unknown Source) at org.postgresql.core.PGStream.<init>(PGStream.java:60) at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:101) ... 31 more2016-01-25 12:48:05,050 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection2016-01-25 12:48:05,117 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection2016-01-25 12:48:05,184 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection2016-01-25 12:48:05,185 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection2016-01-25 12:48:05,185 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection2016-01-25 12:48:05,186 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection2016-01-25 12:48:05,187 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection2016-01-25 12:48:05,187 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection2016-01-25 12:48:05,188 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection2016-01-25 12:48:05,190 DEBUG JdbcDataSourceService,JasperServerMaintenanceScheduler_Worker-1:58 - CreateConnection successful at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.JdbcDataSourceService.createConnection[/code]
  7. Hi Fabric, I updated jasperserver-proWEB-INFjs.externalAuth.properties as shown. Still I am unable to use the queries as defined in jaserpserver-proWEB-INFapplicationContext-externalAuth-db-mt.xml as: changed line 77: <property name="usersByUsernameAndTenantNameQuery" value="SELECT u.login_name as "username", u.password as "password",'jjems' as "tenantId"FROM ids_user uWHERE u.expiration_date is null and u.login_name = '?';"/>changed line 78: <property name="authoritiesByUsernameQuery" value="SELECT u.login_name as "username", upper(replace(r.name,' ','_')) as "rolename"FROM ids_user u, ids_user_role_map irm, ids_role rWHERE u.unid = irm.user_id and irm.role_id = r.unid and u.expiration_date is null and u.login_name = '?';"/> [/code]to authenticate users from my external jdbc database as defined below. Please advise as to my next step. Thank you for your assistance to date. Chris # External authentication properties that can be configured via# the master.properties fileexternal.jdbc.driverClassName=oracle.jdbc.driver.OracleDriverexternal.jdbc.url=jdbc:jdbc:oracle:thin:@localhost:1521:STARTERexternal.jdbc.username=jjemsexternal.jdbc.password=_________ (here I entered the db password for the user in the STARTER Oracle 11g database on my local machine).[/code]# Note that I left the following as it was.external.ldap.url=${external.ldapUrl}external.ldap.username=${external.ldapDn}external.ldap.password=${external.ldapPassword}[/code]Also, I modified: postgresqldatapostgresql.conf at line: 89 as shown:#password_encryption = onpassword_encryption = off[/code]
  8. Thanks Fabric, I will give this a try and let you know how it goes. KennedyChris.
  9. Hi Newfoundland Mark, Understand that pdf format is portable document format. It is called this becuase it is intended to be a portable format for use on the web. For a reference compare the file size of a pdf and a postScript rendition of the same file, the pdf will be smaller. With that said, when you add the images to the pdf file, you should use images with a good compression, for example 1. tiff group IV, 2. gif: supports only 256 colors, lossless, good for text images, line drawings, animation. gif can be large and not photo quality. 3. png: great for logos, lossless, not great for large images compared to jpeg, not for animated images, 24 bit png ssupports millions of colors, 8 bit png has same 256 color limit as gif. 4. jpeg good option for photos, not recommended for line art and logos, jpeg supports broad compression based on loss you are ok with. An option is to compress the pdf after you create it in your java code: something like `gzip -9 $image` will create a .gz file with maximum compression. This will work on all Linux/unix platforms. For your java code, you could also try something like this: import java.io.BufferedReader;import java.io.FileOutputStream;import java.io.IOException;import java.io.InputStream;import java.io.InputStreamReader;import java.util.Arrays;import org.apache.pdfbox.exceptions.COSVisitorException;import org.apache.pdfbox.pdmodel.PDDocument;import org.apache.pdfbox.pdmodel.common.PDStream;import com.itextpdf.text.DocumentException;import com.itextpdf.text.pdf.PdfReader;import com.itextpdf.text.pdf.PdfStamper;import com.itextpdf.text.pdf.PdfWriter;public class compressPDF {public static void main (String[] args) throws IOException, DocumentException, COSVisitorException {// Using PDF Box PDDocument doc; // = new PDDocument();doc = PDDocument.load("C:/_dev_env_/TEMP/compressPDF/TRPT_135002_1470_20131212_121423.PDF");PDStream stream= new PDStream(doc);stream.addCompression();doc.save("C:/_dev_env_/TEMP/compressPDF/compressed_pdfBox.pdf");doc.close();// or Using itextPdfReader reader = new PdfReader("C:/_dev_env_/TEMP/compressPDF/TRPT_135002_1470_20131212_121423.PDF");PdfStamper stamper = new PdfStamper(reader, new FileOutputStream("C:/_dev_env_/TEMP/compressPDF/compressed_Itext.pdf"), PdfWriter.VERSION_1_5);stamper.setFullCompression();stamper.getWriter().setCompressionLevel(50);int total = reader.getNumberOfPages() + 1;for (int i = 1; i < total; i++) {reader.setPageContent(i, reader.getPageContent(i));}stamper.close();reader.close();}}java image pdf itext pdfbox
  10. Question regarding Spring 3.2.5 integration Jasperserver-pro 6.2: ____________________________________________________________________________________ 1. I installed JasperServer-pro 6.2 recently: C:Jaspersoftjasperreports-server-6.2.0>dir Volume in drive C is Windows Volume Serial Number is 90AE-07BB Directory of C:Jaspersoftjasperreports-server-6.2.0 01/11/2016 04:21 PM <DIR> . 01/11/2016 04:21 PM <DIR> .. 01/11/2016 04:11 PM <DIR> apache-ant 01/11/2016 04:11 PM <DIR> apache-tomcat 01/11/2016 04:15 PM <DIR> apps 01/11/2016 04:17 PM <DIR> buildomatic 01/11/2016 04:10 PM <DIR> common 01/11/2016 04:14 PM <DIR> docs 01/11/2016 04:14 PM <DIR> eval-licenses 01/11/2016 04:15 PM <DIR> images 01/11/2016 04:21 PM 1,823,893 installation.log 11/19/2015 04:22 AM 1,935 jasperserver.license 01/11/2016 04:11 PM <DIR> java 11/19/2015 04:22 AM 21,971 license.txt 01/11/2016 04:15 PM <DIR> licenses 01/11/2016 04:10 PM <DIR> postgresql 01/11/2016 04:18 PM 724 properties.ini 11/19/2015 04:22 AM 48,440 releaseNotes.txt 01/11/2016 04:15 PM <DIR> samples 01/11/2016 04:15 PM <DIR> scripts 01/11/2016 04:11 PM 5,464 serviceinstall.bat 01/11/2016 04:11 PM 5,648 servicerun.bat 11/19/2015 04:22 AM 5,765,811 TIBCO-EULA.txt 01/11/2016 04:18 PM 210,310 uninstall.dat 01/11/2016 04:18 PM 7,063,903 uninstall.exe 10 File(s) 14,948,099 bytes 15 Dir(s) 314,039,169,024 bytes free ____________________________________________________________________________________ 2. I have a local ORACLE_SERVER on the same PC as the jasper server 6.2 --------------------------- C:>sqlplus %ORACLE_USER%/%ORACLE_PASSWORD%@%ORACLE_SID% SQL*Plus: Release 11.2.0.1.0 Production on Fri Jan 15 14:04:21 2016 Copyright © 1982, 2010, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> select count(*) from dual; COUNT(*) ---------- 1 SQL> quit Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64 bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options ____________________________________________________________________________________ 3. The server has tables for users and roles: SQL> SELECT u.login_name as "username", u.password as "password",'jjems' as "tenantId" FROM ids_user u SQL> WHERE u.expiration_date is null and u.login_name = 'fperalta'; username -------------------------------------------------- password tenan ---------------------------------------------------------------------- ----- fperalta PASSWORD jjems SQL> SELECT u.login_name as "username", upper(replace(r.name,' ','_')) as "rolename" FROM ids_user u, ids_user_role_map irm, ids_role r SQL> WHERE u.unid = irm.user_id and irm.role_id = r.unid and u.expiration_date is null and u.login_name = 'fperalta'; username -------------------------------------------------- rolename -------------------------------------------------------------------------------- fperalta SUPERUSER ______________________________________________________________________________________________________________ 4. I ran the following command: copy c:jaspersoftjasperreports-server-6.2.0samplesexternalAuth-sample-configsample-applicationContextexternalAuth-db-mt.xml C:Jaspersoftjasperreports-server-6.2.0apache-tomcatwebappsjasperserver-proWEB-INFapplicationContext-externalAuth-db-mt.xml ______________________________________________________________________________________________________________ 5. I editted the destination file and added the following code blocks. The purpose of this is to configure the Spring 3.2.5 beans for external database authentication. Note, I set the tenantID = 'jjems' to match the organization I create in step 9 and enter in step 11 below. changed line 77: <property name="usersByUsernameAndTenantNameQuery" value="SELECT u.login_name as "username", u.password as "password",'jjems' as "tenantId" FROM ids_user u WHERE u.expiration_date is null and u.login_name = '?';"/> changed line 78: <property name="authoritiesByUsernameQuery" value="SELECT u.login_name as "username", upper(replace(r.name,' ','_')) as "rolename" FROM ids_user u, ids_user_role_map irm, ids_role r WHERE u.unid = irm.user_id and irm.role_id = r.unid and u.expiration_date is null and u.login_name = '?';"/> changed lines 83-88: set keyInPlainText = true and commend out the secretKey, Algorithm and cipher transformation <bean id="passwordValidator" class="com.jaspersoft.jasperserver.api.metadata.common.service.impl.PasswordValidator" lazy-init="false"> <property name="keyInPlainText"><value>true</value></property> <!--property name="secretKey"><value>0xC8 0x43 0x29 0x49 0xAE 0x25 0x2F 0xA1 0xC1 0xF2 0xC8 0xD9 0x31 0x01 0x2C 0x52 0x54 0x0B 0x5E 0xEA 0x9E 0x37 0xA8 0x61</value></property> <property name="secretKeyAlgorithm"><value>DESede</value></property> <property name="cipherTransformation"><value>DESede/CBC/PKCS5Padding</value></property--> </bean> changed line 129: <entry key="SUPERUSER " value="ROLE_ADMINISTRATOR|*"/> added at line 138: <property name="conflictingExternalInternalRoleNameSuffix"><value>"_JJEMS_ROLE|*"</value></property> changed lines 175-180: <bean id="externalDataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource"> <property name="driverClassName" value="oracle.jdbc.OracleDriver"/> <property name="url" value="jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=10.199.35.7)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=JJEMRPTP.hhs.ma.local)))"/> <property name="username" value="jjems"/> <property name="password" value ="password"/> </bean> I saved this file ______________________________________________________________________________________________________________ 6. I copied ojdbc6.jar from my oracle client folder to C:Jaspersoftjasperreports-server-6.2.0apache-tomcatlib> C:Jaspersoftjasperreports-server-6.2.0apache-tomcatlib>dir ojdbc6.jar Volume in drive C is Windows Volume Serial Number is 90AE-07BB Directory of C:Jaspersoftjasperreports-server-6.2.0apache-tomcatlib 03/04/2010 04:37 AM 2,111,338 ojdbc6.jar 1 File(s) 2,111,338 bytes 0 Dir(s) 314,045,784,064 bytes free ______________________________________________________________________________________________________________ 7. I remove all logs from the log folder: C:Jaspersoftjasperreports-server-6.2.0apache-tomcatlogs>dir Volume in drive C is Windows Volume Serial Number is 90AE-07BB Directory of C:Jaspersoftjasperreports-server-6.2.0apache-tomcatlogs 01/15/2016 02:53 PM <DIR> . 01/15/2016 02:53 PM <DIR> .. 0 File(s) 0 bytes 2 Dir(s) 314,044,194,816 bytes free ______________________________________________________________________________________________________________ 8. I start the postgresql repository and the applicaiton server: right click > Start Task Manager > Services tab > jasperreportsPostgreSQL > Start Service wait until I see it is running right click > Start Task Manager > Services tab > jasperreportsTomcat > Start Service wait until I see it is running Both Services now show as running. ______________________________________________________________________________________________________________ 9. I open Google Chrome 47.0.2526.111m and enter url: localhost:8080/jasperserver-pro/login.html I login as jasperadmin/jasperadmin Manage > Organizations > add Organization > I enter jjems for the Organziation Name, ID, Alias and Description and Select Add Organization to Organization_1 ______________________________________________________________________________________________________________ 10. I restart the postgreSQL and Jasper services (as in step 8 above) ______________________________________________________________________________________________________________ 11. I open Google Chrome 47.0.2526.111m and enter url: localhost:8080/jasperserver-pro/login.html I enter the values as shown in steps 3 and 5 above. The values are: Organization: jjems User: fperalta Password: PASSWORD ______________________________________________________________________________________________________________ 12. The response is: Invalid credentials supplied. Could not login to JasperReports Server. Note: Your license will expire on 2016-01-27 23:59:59. ______________________________________________________________________________________________________________ 13. Next I log back in as: Organization: jjems User: jasperadmin Password: jasperadmin and check Manager > Users and I see only 2 users: jasperadmin and joeuser, no fperalta user in the jjems organization in the jasper repository. ______________________________________________________________________________________________________________ 14. I looked for errors in the folder c:jaspersoftjasperreports-server-6.2apache-tomcatlogs and find the following: jasperreportstomcat-stdout.2016-01-15.log: 2016-01-15 15:19:04 Commons Daemon procrun stdout initialized 2016-01-15 15:25:12,090 ERROR EhCacheImpl,localhost-startStop-6:552 - -- JasperServer: EhCacheImpl shutdown called. This normal shutdown operation. 2016-01-15 15:25:12,099 ERROR EhCacheImpl,localhost-startStop-6:555 - -- JasperServer: EhCacheImpl calling cleanerTimer.cancel(). This normal shutdown operation. localhost_access_log.2016-01-15.txt 127.0.0.1 - - [15/Jan/2016:15:21:13 -0500] "GET /jasperserver-pro/login.html?error=1 HTTP/1.1" 200 70609 ______________________________________________________________________________________________________________ ***** MY QUESTION IS: ***** What do I need to change in the file C:Jaspersoftjasperreports-server-6.2.0apache-tomcatwebappsjasperserver-proWEB-INFapplicationContext-externalAuth-db-mt.xml to make this work. Or is there another file that I should modify or another step in the process to make the external authorization work for jasperserver-pro. Please advise, Thank you, Chris Kennedy ______________________________________________________________________________________________________________
  11. Hi, To add/update a query in studio: use the data set and query editor dialog to the left of the + and - hourglass buttons top center of the design view main report window. For iReports, use the "Report Query" Button, in the Designer view. The button is to the right of preview. if you review the jrxml source, your query will look like the following: <queryString> <![CDATA[sELECT ... FROM ... JOIN ... ON ... LEFT OUTER JOIN ... ON ... WHERE RVL.VISIT_DATE >= $P{Begin} AND RVL.VISIT_DATE <= $P{End} AND RVL.REGION = $P{Region} ORDER BY RVL.REGION, ...]]> I hope this helps, Chris Kennedy
  12. Hi Kumar, Thank you for responding. I appreciate your solution. Since I wanted to solve it last night, I selected a different method. What I did was to create an image folder as: C:Jaspersoftjasperreports-server-6.2.0apache-tomcatwebappsjasperserver-proimages To the folder, I added my image. Then within studio, when I added the image from the design palette basic elements, I selected URL (a remote URL referring to an image, will be the expression value) For the url, I enterred: http://localhost:8080/jasperserver-pro/images/DYSSeal.png Directory of C:Jaspersoftjasperreports-server-6.2.0apache-tomcatwebappsjasperserver-proimages 01/13/2016 06:52 PM <DIR> .01/13/2016 06:52 PM <DIR> ..01/13/2016 05:47 PM 15,091 DYSSeal.png 1 File(s) 15,091 bytes 2 Dir(s) 310,665,125,888 bytes freeC:Jaspersoftjasperreports-server-6.2.0apache-tomcatwebappsjasperserver-pro>[/code]In this way, I did not have to replace the image path with repo:... prior to uploading to jasper server, since the image is already in a server folder. Additionally, I can use the same url for multiple reports. My jrxml file looks as follows, localhost is c:jaspersoftjasperreports-server-6.2.0apache-tomcat{bin,conf,logs,webapps} <imageExpression><![CDATA["http://localhost:8080/jasperserver-pro/images/DYSSeal.png"]]></imageExpression>[/code]
  13. http://community.jaspersoft.com/sites/all/libraries/ckeditor/plugins/smiley/images/sad_smile.gif Please Help http://community.jaspersoft.com/sites/all/libraries/ckeditor/plugins/smiley/images/sad_smile.gif How do I add an image to a Jasper Report using studio 6.2 and make the image available in Jasper Server after uploading the report.
  14. Bonjour mon amie, apportera les modifications suivantes à votre context.xml <Context path="/jasperserver" reloadable="false"><Resource name="jdbc/jasperserver" auth="Container" type="javax.sql.DataSource" maxActive="100" maxIdle="30" maxWait="10000" username="jasperdb" password="password" driverClassName="org.postgresql.Driver" accessToUnderlyingConnectionAllowed="true" validationQuery="SELECT 1" testOnBorrow="true" url="jdbc:postgresql://127.0.0.1:5432/jasperserver?useUnicode=true&amp;characterEncoding=UTF-8&amp;autoReconnect=true&amp;autoReconnectForPools=true" factory="com.jaspersoft.jasperserver.tomcat.jndi.JSCommonsBasicDataSourceFactory"/> <Resource name="jdbc/sugarcrm" auth="Container" type="javax.sql.DataSource" maxActive="100" maxIdle="30" maxWait="10000" username="jasperdb" password="password" driverClassName="org.postgresql.Driver" accessToUnderlyingConnectionAllowed="true" validationQuery="SELECT 1" testOnBorrow="true" url="jdbc:postgresql://127.0.0.1:5432/sugarcrm?useUnicode=true&amp;characterEncoding=UTF-8&amp;autoReconnect=true&amp;autoReconnectForPools=true" factory="com.jaspersoft.jasperserver.tomcat.jndi.JSCommonsBasicDataSourceFactory"/> <Resource name="jdbc/foodmart" auth="Container" type="javax.sql.DataSource" maxActive="100" maxIdle="30" maxWait="10000" username="jasperdb" password="password" driverClassName="org.postgresql.Driver" accessToUnderlyingConnectionAllowed="true" validationQuery="SELECT 1" testOnBorrow="true" url="jdbc:postgresql://127.0.0.1:5432/foodmart?useUnicode=true&amp;characterEncoding=UTF-8&amp;autoReconnect=true&amp;autoReconnectForPools=true" factory="com.jaspersoft.jasperserver.tomcat.jndi.JSCommonsBasicDataSourceFactory"/> <Manager pathname=""/></Context>en supposant que vous utilisez le référentiel de jaspe.au revoir, Christophe KennedyBoston, Les etat unis
×
×
  • Create New...