Jump to content

highjo

Members
  • Posts

    28
  • Joined

  • Last visited

highjo's Achievements

Explorer

Explorer (4/14)

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

Recent Badges

0

Reputation

  1. Hello, I'm developing an application in Java which generates reports using Jasperreports. My report has summary tables and a graph that uses a summarized form of the same data the main report uses. Rather than make multiple calls to the database for the same data, I fetch it once, process it and create three JRDataSources, one for the main and two for the tables/chart. Now, i want to pass the data sources for the tables as template parameters. Is this possible? If it is, could someone guide me as to how to do this? I need to set the data source passed as the source for the table. Here are some snippets of my xml file: Thanks. Code:...<subDataset name="Summary" uuid="7a0d9924-1304-410f-bfb5-2bccc7005adb"> ....fields...</subDataset> ...<parameter name="summary" class="java.lang.Object"/>...<jr:table xmlns:jr="http://jasperreports.sourceforge.net/jasperreports/components" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports/components http://jasperreports.sourceforge.net/xsd/components.xsd"> <datasetRun subDataset="Summary" uuid="7a0d9924-1304-410f-bfb5-2bccc7005adb"> <parametersMapExpression><![CDATA[$P{REPORT_PARAMETERS_MAP}]]></parametersMapExpression> <dataSourceExpression><![CDATA[$P{summary}]]></dataSourceExpression></datasetRun>...</jr:table>
  2. Hi!! very kind of you to respond.I think i would put the blame on myself because, i intend to do a fresh installation anyway. My real issue is how to backup the gerenated pdf thanks for responding, any idea on how to backup the files?
  3. Hello anyone? i really need your opinion to proceed. thanks.
  4. Hello Experts I will be doing another fresh installation of jasperserver preferably 4 and i would like to backup all the generated pdfs. It's seems i can't find them on the file system to copy.how can i possibly get them in a pdfs form? thanks!!!! Post Edited by highjo at 08/17/2011 21:38
  5. lucianc Wrote: Set a validation query for the JNDI data source. Some details at http://jasperforge.org/plugins/espforum/view.php?group_id=112&forumid=102&topicid=41903 Regards, Lucian hello lucianc and tkavanagh i seem to be having the same wait_timeout error and here is basically what's in my log org.quartz.SchedulerException: Job threw an unhandled exception. [see nested exception: org.springframework.transaction.CannotCreateTransactionException: Could not open Hibernate Session for transaction; nested exception is org.hibernate.TransactionException: JDBC begin failed: ] at org.quartz.core.JobRunShell.run(JobRunShell.java:206) at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)* Nested Exception (Underlying Cause) ---------------org.springframework.transaction.CannotCreateTransactionException: Could not open Hibernate Session for transaction; nested exception is org.hibernate.TransactionException: JDBC begin failed: at org.springframework.orm.hibernate3.HibernateTransactionManager.doBegin(HibernateTransactionManager.java:599) at org.springframework.transaction.support.AbstractPlatformTransactionManager.getTransaction(AbstractPlatformTransactionManager.java:374) at org.springframework.transaction.interceptor.TransactionAspectSupport.createTransactionIfNecessary(TransactionAspectSupport.java:263) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:101) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) at $Proxy3.loadUserByUsername(Unknown Source) at com.jaspersoft.jasperserver.api.engine.common.service.impl.AcegiSecurityContextProvider.setAuthenticatedUser(AcegiSecurityContextProvider.java:88) 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.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:198) at $Proxy6.setAuthenticatedUser(Unknown Source) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.ReportExecutionJob.execute(ReportExecutionJob.java:228) at org.quartz.core.JobRunShell.run(JobRunShell.java:195) at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)Caused by: org.hibernate.TransactionException: JDBC begin failed: at org.hibernate.transaction.JDBCTransaction.begin(JDBCTransaction.java:96) at org.hibernate.impl.SessionImpl.beginTransaction(SessionImpl.java:1354) at org.springframework.orm.hibernate3.HibernateTransactionManager.doBegin(HibernateTransactionManager.java:558) ... 17 moreCaused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: The last packet successfully received from the server was 42,578,794 milliseconds ago. The last packet sent successfully to the server was 42,578,794 milliseconds ago. is longer than the server configured value of 'wait_timeout'. You should consider either expiring and/or testing connection validity before use in your application, increasing the server configured values for client timeouts, or using the Connector/J connection property 'autoReconnect=true' to avoid this problem. at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Unknown Source) at com.mysql.jdbc.Util.handleNewInstance(Util.java:406) at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1074) at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:3313) at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1940) at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2109) at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2642) at com.mysql.jdbc.ConnectionImpl.setAutoCommit(ConnectionImpl.java:5034) at org.apache.tomcat.dbcp.dbcp.DelegatingConnection.setAutoCommit(DelegatingConnection.java:331) at org.apache.tomcat.dbcp.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.setAutoCommit(PoolingDataSource.java:317) at org.hibernate.transaction.JDBCTransaction.begin(JDBCTransaction.java:91) ... 19 moreCaused by: java.net.SocketException: Software caused connection abort: socket write error at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(Unknown Source) at java.net.SocketOutputStream.write(Unknown Source) at java.io.BufferedOutputStream.flushBuffer(Unknown Source) at java.io.BufferedOutputStream.flush(Unknown Source) at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:3294) ... 26 more i've read the thread posted by lucianc and made necessary changes and restarted the tomcat server there is my context: <Resource name="jdbc/jasperserver" auth="Container" type="javax.sql.DataSource" maxActive="100" maxIdle="30" maxWait="180000" username="root" password="" validationQuery="select count(*) from JIRole" driverClassName="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost:3306/jasperserver?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&autoReconnectForPools=true" /> <Resource name="jdbc/sugarcrm" auth="Container" type="javax.sql.DataSource" maxActive="100" maxIdle="30" maxWait="10000" username="root" password="" driverClassName="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost:3306/sugarcrm?autoReconnect=true"/> <Resource name="jdbc/foodmart" auth="Container" type="javax.sql.DataSource" maxActive="100" maxIdle="30" maxWait="10000" username="root" password="" driverClassName="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost:3306/foodmart?autoReconnect=true"/> and that doesnt seem to have affected the server.But i had to say that the report itself runs fine and when the scheduled one failed given the error i've posted, i send the report manually by clicking on run now and it works fine with no entry in the log. now should i add the properties bellow to the jdbc-connection-pool-params element in the jasperserverDS-jdbc.xml as suggested by developerrude in lucianc's link thread or just add wait_time out to mysql my.cnf ? # Here follows entries for some specific programs # The MySQL server[mysqld]port= 3306socket= "C:/xampp/mysql/mysql.sock"basedir="C:/xampp/mysql" tmpdir="C:/xampp/tmp" datadir="C:/xampp/mysql/data"skip-lockingkey_buffer = 16Mmax_allowed_packet = 1Mtable_cache = 64sort_buffer_size = 512Knet_buffer_length = 8Kread_buffer_size = 256Kread_rnd_buffer_size = 512Kmyisam_sort_buffer_size = 8M# commented in by lampp security#skip-networkingskip-federatedserver-id = 1#skip-innodbinnodb_data_home_dir = "C:/xampp/mysql/"innodb_data_file_path = ibdata1:10M:autoextendinnodb_log_group_home_dir = "C:/xampp/mysql/"#innodb_log_arch_dir = "C:/xampp/mysql/"## You can set .._buffer_pool_size up to 50 - 80 %## of RAM but beware of setting memory usage too highinnodb_buffer_pool_size = 16Minnodb_additional_mem_pool_size = 2M## Set .._log_file_size to 25 % of buffer pool sizeinnodb_log_file_size = 5Minnodb_log_buffer_size = 8Minnodb_flush_log_at_trx_commit = 1innodb_lock_wait_timeout = 50[mysqldump]quickmax_allowed_packet = 16M[mysql]no-auto-rehash# Remove the next comment character if you are not familiar with SQL#safe-updates[isamchk]key_buffer = 20Msort_buffer_size = 20Mread_buffer = 2Mwrite_buffer = 2M[myisamchk]key_buffer = 20Msort_buffer_size = 20Mread_buffer = 2Mwrite_buffer = 2M[mysqlhotcopy]interactive-timeout we are using xampp for this.it's a work server so i've been told xampp is fine for the purpose. One thing is sure, i've started getting pressure from management so i'would like to make this solved as soon as possible.thanks for reading he who help me out will be my hero thanks again
  6. Hello Good People!! I've having a slight problem and i'll like you so share you opinion experience on it.I've deployed a jasperserver on tomcat 6 in a environment where anything has to pass through the proxy server to have access to the internet. i'm wondering about where to put the proxy params and credentials. at tomcat level or at jasperserver level ?I've seen that JavaMail does support retrieving or sending mail through proxy server.Another thing is that i've also seen that all Java Tcp can be configured using the Java Runtime to direct socket connection to the proxy server which can harm performance. What other options do i have? thanks for reading this! Post Edited by highjo at 12/07/2010 11:42
  7. Hello thanks for replying this.I 've realized that to use tls the port number has to be 587, and i just happened to noticed that it was said earlier.So after making that change i started having an entry in the the jasperserver.log file which i put with this poste.so is it a common error on jasperserver or it's has to go with my environement?anyway how to fix it? thanks for reading this Code:2010-03-02 16:53:14,677 ERROR ReportExecutionJob,quartzScheduler_Worker-1:308 - An error occurred while sending job error notification.org.springframework.mail.MailSendException; nested exception details (1) are:Failed message 1:javax.mail.MessagingException: IOException while sending message; nested exception is: javax.activation.UnsupportedDataTypeException: no object DCH for MIME type multipart/mixed; boundary="----=_Part_0_1879321.1267548791209" at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:625) at org.springframework.mail.javamail.JavaMailSenderImpl.doSend(JavaMailSenderImpl.java:403) at org.springframework.mail.javamail.JavaMailSenderImpl.send(JavaMailSenderImpl.java:342) at org.springframework.mail.javamail.JavaMailSenderImpl.send(JavaMailSenderImpl.java:338) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.ReportExecutionJob.sendMailNotification(ReportExecutionJob.java:1259) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.ReportExecutionJob.executeAndSendReport(ReportExecutionJob.java:445) at com.jaspersoft.jasperserver.api.engine.scheduling.quartz.ReportExecutionJob.execute(ReportExecutionJob.java:231) at org.quartz.core.JobRunShell.run(JobRunShell.java:195) at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)Caused by: javax.activation.UnsupportedDataTypeException: no object DCH for MIME type multipart/mixed; boundary="----=_Part_0_1879321.1267548791209" at javax.activation.ObjectDataContentHandler.writeTo(DataHandler.java:870) at javax.activation.DataHandler.writeTo(DataHandler.java:301) at javax.mail.internet.MimeBodyPart.writeTo(MimeBodyPart.java:1350) at javax.mail.internet.MimeMessage.writeTo(MimeMessage.java:1683) at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:585) ... 8 more
  8. Hello good people! i know this thread is old and i've seen some slight differences in files which are supposed to be edited in the version 3.7 which are js.quartz.properties and applicationContext-report-scheduling. what differences i've seen here, is at the applicationContext-report-scheduling level : <prop key="mail.smtp.starttls.enable">true</prop> is that ok just to add it?
  9. Hello good people, I've been trying to schedule a report and using the email features.While the scheduling works as expected meaning a pdf is put in the specified folder.Only the emailing bit is worring me since it's not working. i wanted to use gmail smtp and here are details.What exactly i'm doing wrong? is anyone using gmail smtp? thanks for reading Code://js.quartz.propertiesquartz.delegateClass=org.quartz.impl.jdbcjobstore.StdJDBCDelegatequartz.tablePrefix=QRTZ_quartz.extraSettings=report.scheduler.mail.sender.host=smtp.gmail.comreport.scheduler.mail.sender.username=XXXXXXXX@gmail.comreport.scheduler.mail.sender.password=XXXXXXXreport.scheduler.mail.sender.from=XXXXX@XXXXXX.comreport.scheduler.mail.sender.protocol=smtpreport.scheduler.mail.sender.port=465//applicationContext-report-scheduling.xml<property name="javaMailProperties"> <props> <prop key="mail.smtp.auth">true</prop> </props></property>
  10. Hello good People! I have a report of 6 pages where in the last page i need to show something more like policy stuffs as subreport where the user's name is passed to it from the main report.Now i don't really know how to achieve this.First because the text of the policy is not picked from the database and second i can't picture exactly what control to use.Text field or static test. For example : We, "THE -NAME-TO-PASS" agree to make an amount of "AMOUNT-TO-PASS" bla bla bla by the 27th day of the month. This amount may only alter on term by term basis. Upon default of payment in a particular month and where this continues for a period of three (3) months, We hereby agree that all our monthly contributions in total be refunded to us without any commercial interest charges less an administrative fee of 15% and the property reallocated to a prospective applicant. so in this example there are 2 place holder or parameters where to pass the real values.Can anyone share its experience? thanks for reading this. Post Edited by highjo at 01/28/2010 11:48 Post Edited by highjo at 01/28/2010 13:18 Post Edited by highjo at 01/28/2010 15:08
  11. Yes Thanks to you all Lucian and Giovani.the error was due to the case of the parameter.Fixed it.Thanks again
  12. Thanks tony for the reply.I just got the sample working with some tweaks here and there.First i didnt' know it was using Pear Soap i made the assumptions that it was using and old version of php soapclient class (which has changed a bit actually).So I got it working fine now.But since it's a web service it's supposed to work with every implementation of php soap library right? correct me if i'm wrong.Yesterday after posting it i tried with Nusoap and i got the Returncode 1.And i got stack because i didin't know how to get the attachement.Anyway in my free time i can submit a nusoap version to one of the admin guys to do a sticky post with it.Thanks a lot again
  13. Hello i've successfully deployed my report on JS-3.7RC and could run it both from ireport and from the web app. I had php 5.3.1 install and mysql 5.1.41. all under windows xp sp2. i've tried running the sample bundled with the server but it seems soap implementation of php has changed a bit and i've tried to accomodate it a bit but no success.Then i download the nusoap-0.7.3 library and try my own implementation(and copy some of the sample files) to connect to the web service i was having this error: "error no transport found, or selected transport is not yet supported!" then i've decided to see what is happening and i downloaded soapUI to connect to the webservice.i had all the function created for me in the soapUI project but when calling the page it gives this : Error report HTTP Status 401 -Full authentication is required to access this resource.This request requires HTTP authentication. i've tried to put and authentication header but no success.i'm sure i'm not doing it well.here it is : <soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:axis="http://axis2.ws.jasperserver.jaspersoft.com"> <soapenv:Header/> <wsse:Security soapenv:mustUnderstand="0" xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/07/secext"> <wsse:UsernameToken> <wsse:Username xsi:type="xsd:string"> jasperadmin</wsse:Username> <wsse:Password Type="wsse:PasswordBasic" xsi:type="xsd:string">jasperadmin</wsse:Password> </wsse:UsernameToken> </wsse:Security> <soapenv:Body> <axis:runReport soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"> <requestXmlString xsi:type="xsd:string" operationName="runReport"> <argument name='RUN_OUTPUT_FORMAT'>PDF</argument> <resourceDescriptor name="" wsType="reportUnit" uriString="/reports/clientMainReport" isNew="false"> <label></label> <parameter name="accountId"> <![CDATA[275ff0ed-7c52-a1d1-aeab-44c2aae5fa6e]]> </parameter> </resourceDescriptor> </requestXmlString> </axis:runReport> </soapenv:Body> </soapenv:Envelope> i've attached too the php files that i'm using to connect.Can please anyone help.I need this to get going , and i'm very behind schedule i've allocate myself to get a hand on jasperserver basic stuffs So please.thanks for reading this.thanks Post Edited by highjo at 01/16/2010 20:11
×
×
  • Create New...