Jump to content

ghudson_1

Members
  • Posts

    284
  • Joined

  • Last visited

  • Days Won

    3

 Content Type 

Forum

Downloads

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Security Advisories

Events

Profiles

Everything posted by ghudson_1

  1. The JRS Ultimate Guide provides ideas for making customizations of jsp. So I would check the few different means for determing what gets displayed after login. See these two: http://community.jaspersoft.com/wiki/customizing-home-or-login-page http://community.jaspersoft.com/wiki/how-set-role-based-home-page-version-55 To use entirely new JSP's read the JRS Ultimate Guide's chapter "11.9 Adding a Custom JSP Page in a Spring Web Flow" and use the proHomePageByRole stuff to "flow" to this new jsp upon login. For deeper info look into how the LoginController servlet creates calls into spring webflow..... and WEB-INFflowshomeFlow.xml defines the route for "homeFlow" as going to moduleshomehome.jsp, and you can potentially create your own flows routing to your own jsp's and get as fancy as your budget/time allows.
  2. Issue Description:A customer was running GET rest_v2 requests for a report and found problems specifying a date parameter. In one environment the format YYYY-MM-DD worked. In another environment only a format of DD.MM.YYYY would work. Resolution:One JVM's locale was different from the other, and different locales can require different date formats (reference Admin Guide's Localization chapter for more info). The server locale is fetched from the JVM, the JVM gets it either from the OS or from java options that are set within startup scripts. For confirmation of the date format required you can run the serverInfo request, like: http://localhost:8080/jasperserver-pro/rest_v2/serverInfo?j_username=superuser&j_password=superuser For the sake of testing, you can also force a locale via an additional URL query param, userLocale. So you could test both of your environments, each with different locales, like: http://localhost:8080/jasperserver-pro/rest_v2/serverInfo?userLocale=de_DE Or http://localhost:8080/jasperserver-pro/rest_v2/serverInfo?userLocale=en_US To force a particular locale in your JVM, in the startup script's JAVA_OPTS arguments, you can pass -Duser.language and -Duser.region (reference http://docs.oracle.com/cd/E23095_01/Platform.93/ATGProgGuide/html/s1809settingthejavavirtualmachineloca01.html). For example, these arguments passed to the JVM will set french / belgium: -Duser.language=fr -Duser.region=BE Ref. Case #00051770
  3. Issue Description:Typical actions to enable log4j logging in JasperReports Server v5.5 and lower are not working as expected in Websphere. Some classes or packages will log while others will not, even when rootLogger is set to DEBUG. Resolution:Deep within IBM documention there is info about Jakarta Commons Logging, and apparently the class-loading surrounding this area is complex - hence the reason why some classes log, some don't. The workaround:Create folder called "services" in META-INF Create file named "org.apache.commons.logging.LogFactory" , no file extension, inside META-INF/services The content of org.apache.commons.logging.LogFactory should be: org.apache.commons.logging.impl.Log4jFactory[/code]In other words, the file should be empty aside from the single line above. restart Ref. Case #00043194
  4. Issue Description:A customer wished to run SSL on port 8080. They were able to configure Tomcat to run SSL on port 8080 put the jasperserver-pro web-application was rewriting the port to 8443 when they tried to navigate to it. For example, https://:8080/jasperserver-pro became https://:8443/jasperserver-pro/login.html. The customer had generated a certificate and had no problems associating it with Tomcat via it's server.xml config file: <Connector port="8080" protocol="HTTP/1.1" SSLEnabled="true" maxThreads="150" scheme="https" secure="true" clientAuth="false" sslProtocol="TLS" SSLCertificateFile="${catalina.base}/conf/cert.crt" SSLCertificateKeyFile="${catalina.base}/conf/privkey-nopass.pem" /> Resolution:Spring Security contains default configurations which swap the port for a few particular requests, including HTTPS requests for port 8080. So if you want SSL requests to be made only through port 8080, then in addition to the appserver-specific steps (like generating an SSL Certificate and associating this with your appserver), configurations needed to be adjusted in Spring Security layer to update portResolver and portMapper values for several filters. First ensure you have portMapper and portResolver beans in WEB-INFapplicationContext-security-web.xml, like the entries below: <bean id="portResolverImpl" class="org.springframework.security.util.PortResolverImpl"> <property name="portMapper" ref="portMapperImpl"/> </bean> <bean id="portMapperImpl" class="org.springframework.security.util.PortMapperImpl"> <property name="portMappings"> <map> <entry key="8080" value="8080"/> </map> </property> </bean> Second, associate both as properties of authenticationProcessingFilterEntryPoint in the same xml file: <bean id="authenticationProcessingFilterEntryPoint" class="org.springframework.security.ui.webapp.AuthenticationProcessingFilterEntryPoint"> <property name="loginFormUrl"> <value>/login.html</value> </property> <property name="forceHttps"> <value>false</value> </property> <property name="portMapper" ref="portMapperImpl" /> <property name="portResolver" ref="portResolverImpl"/> </bean> Third, associate the portResolver with exceptionTranslationFilter in the same xml file: <bean id="exceptionTranslationFilter" class="org.springframework.security.ui.ExceptionTranslationFilter"> <property name="authenticationEntryPoint"> <ref local="authenticationProcessingFilterEntryPoint"/> </property> <property name="accessDeniedHandler"> <bean class="com.jaspersoft.jasperserver.war.themes.ThemeAwareAccessDeniedHandlerImpl"> <property name="errorPage" value="/WEB-INF/jsp/modules/system/AccessDeniedPage.jsp"/> <property name="themeResolver" ref="themeResolver"/> <property name="themeSource" ref="themeSource"/> </bean> </property> <property name="portResolver" ref="portResolverImpl"/> </bean> Ref. Case #00048547
  5. "Why prohibit any user who is not under an organization from making a domain? Not sure if this was necessary for something or a bug." - It's a defect, it's been filed against JRS 5.6
  6. Thanks for posting the above workaround. A defect against JRS 5.6 has been filed, #38332. For search/reference the stacktrace is: java.lang.NullPointerException at org.hibernate.criterion.IlikeExpression.getTypedValues(IlikeExpression.java:69) at org.hibernate.loader.criteria.CriteriaQueryTranslator.getQueryParameters(CriteriaQueryTranslator.java:274) at org.hibernate.loader.criteria.CriteriaLoader.list(CriteriaLoader.java:118) at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1597) at
  7. Issue Description:Environments with heavy scheduling and browsing can result in the JICONTENTRESOURCE table becoming large when the scheduled output is saved to the repository. Resolution:An enhancement request exists for an auto-purging facility of saved content (aka scheduled job output). Additionally, your DBA can create scripts that you schedule or run periodically to help clean-up some of the tables. The key is to remove records from JICONTENTRESOURCE first. Note, dashboards will create some .html resources in JICONTENTRESOURCE from layouts, so filter these out. Following is an interesting example of something you could schedule/cron to delete data older than 30 days that is type PDF (SQL syntax may vary per db vendor and obviously you could get as fancy as you'd like). Always backup your database before making manual changes. CREATE TABLE WRK_CONTENTRESOURCE_TBL (id int) TRUNCATE TABLE WRK_CONTENTRESOURCE_TBL /* exclude JIResource where name = layout, or you'll damage dashboards */ INSERT INTO WRK_CONTENTRESOURCE_TBL select id from jiresource b where b.id in( SELECT a.id from jicontentresource a where a.id in( select id from jiresource where name != 'layout' and creation_date < (current_date - 30) ) and file_Type = 'pdf' ) DELETE FROM JIAccessEvent where resource_id in ( Select id from WRK_CONTENTRESOURCE_TBL ) DELETE FROM jicontentresource WHERE ID in ( Select id from WRK_CONTENTRESOURCE_TBL ) DELETE FROM jiresource WHERE ID in ( Select id from WRK_CONTENTRESOURCE_TBL ) DROP TABLE WRK_CONTENTRESOURCE_TBLRef. Case #00050398
  8. Issue Description:It seems like the scrollbar for a List of Values input control will only appear for certain quantities of values/items. This can be a problem for dense dashboards with limited "real estate" when there are a very small number of values in the list. Resolution:Pixel size of the area consumed by the values is actually the driving factor behind whether or not the scrollbar is displayed. A customization can be made to pagespecific.css within a theme to trigger the display of the scrollbar for the List of Values input control. Find .sList: .sList { max-height: 240px; ... } You can set this value to a lower value than 240px, then it will cause the scrollbar to appear for smaller counts of list values/options. Ref. Case #00049456
  9. How to see which reports are currently running in JasperReports Server via JConsole and JMX Issue Description:Via JMX you can see reports which haven't completed. This is described in Chapter 8 CHAPTER 8 SERVER DIAGNOSTICS of the JasperReports Server v5.5 Administration Guide Resolution:For recently run reports Create an Adhoc View from the Monitor Domain - Enable audit & monitoring by setting audit.enabled=true and monitoring.enabled=true in WEB-INFjs.config.properties and restart your application server. -Create your view from /public/monitoring/domains/ReportMonitoringDomain. - Add "Report URI" to Columns. - Add a filter for "Event Type" and set it to runReport. - Add a filter for Time Stamp and use this to define the time-period of recently run reports that you'd like to display. - Add "Query Execution Time" or any other interesting fields. Monitor and Audit data is event based, so that info is only recorded after completion of the event (like the running of the report). For currently running reports use JConsole or another JMX tool: (NOTE: In newer versions the RunningReportsList can be found in the Diagnostic Report shipped with JRS in /public/diagnostic) - Connect <jdk>binjconsole.exe to our JMX mbean data which is enabled by default. The default connection string is service:jmx:rmi://localhost/jndi/rmi://<host>:<port>/<connectionName>, connection below is to my personal machine, so I used "localhost" in place of <host>. - Expand down to the RunningReportsList mbean attribute as seen below, and click Refresh. After clicking refresh, the "name" / "value" might need to be expanded to see all reports, do this by double-clicking the "value". The screenshot shows the expanded list after being double-clicked. Ref. Case #00046260
  10. java.lang.NumberFormatException: For input string: 'nu' when importing from 5.5 to 5.x Description:When using buildomatic to import from an earlier version of JRS to a newer version, a customer encountered this stacktrace within their buildomatic output: [toc]java.lang.NumberFormatException: For input string: "nu"java.lang.NumberFormatException: For input string: "nu" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) at java.lang.Integer.parseInt(Integer.java:492) at com.jaspersoft.jasperserver.api.metadata.common.service.impl.Cipherer.dehexify(Cipherer.java:215) at com.jaspersoft.jasperserver.api.metadata.common.service.impl.Cipherer.decode(Cipherer.java:154) at com.jaspersoft.jasperserver.export.modules.auth.beans.UserBean.copyTo(UserBean.java:128) .....[/code]JasperReport Server v5.5 contained a defect, #35723, characterized by incorrectly encypted data in user password tags of js-exports. This can cause an exception upon import in circumstances where the user can an empty/blank/null password in the JIUSER table. This empty/blank/null password circumstance is typically associated with externally authenticated users. Resolution:Two options exist for resolution: Manually edit each individual user's .xml file, removing 'null' from the password element, then import. Find/replace tools (ReplaceText for win OS) can be executed against the export's directories of users. find: <password>ENC<null></password>[/code]replace with: <password>ENC<></password>[/code]Example sed commands: sed -i 's/null//g' *.xml[/code]OR more robust sed -i 's/ENC<null>/ENC<>/g'; *[/code]Patch your JasperReport Server v5.5 instance with the cumulative hotfix patch & re-run the original export. Ref. Case #00050467
  11. Question:When using the JR API/library version 5.5, what are the minimum required jars for compile & fill of a jrxml that contains an html5 element. This question does not apply to export, only compile & fill. Answer:Report's containing html5/highcharts can compile with the libs shipped with pro JasperReports API in jasperreports-pro-5.5.0lib and jasperreports-pro-5.5.0jasperreportslib, though not all are required since many are only necessary for particular components/elements, or particular export type. For example, barcode4j-2.1.jar is only necessary if you have a barcode in your chart, likewise the poi-3.7-20101029.jar from poi.apache.org is only necessary if exporting to Microsoft formats like .docx. The following is the minimal list of jars needed to compile (transform the file from a .jrxml into a compiled jasper design file, aka .jasper) a report containing an html5/highchart element: commons-beanutils-1.8.0.jar commons-collections-2.1.1.jar commons-digester-2.1.jar commons-javaflow-20060411.jar commons-LICENSE.txt commons-logging-1.1.1.jar commons-NOTICE.txt groovy-all-2.0.1-LICENSE.txt groovy-all-2.0.1.jar jasperreports-5.5.0.jar jasperreports-fusion-5.5.0.jar jasperreports-highcharts-5.5.0.jar jasperreports-license-5.1.0.jar jasperreports-pro-5.1.0.jar protection-4.6.3.jar rhino-1.7R3-LICENSE.txt rhino-1.7R3.jar servlet-api-2.4.jar spring-2.5.5-LICENSE.txt spring-beans-2.5.5.jar spring-core-2.5.5.jar Note that the groovy jar may not be required depending on the report type. For filling, you also need to add jars that your datasource requires, like a jdbc driver in the case of a jdbc datasource. For exporting you'll obviously need to add jars pertinent to your export type. Ref. Case #00050154
  12. MetaDataException when creating new domainA customer created a new Domain, clicked 'Edit with Domain Designer', and at the moment when the Designer should prompt the user to select a database schema they were given an error: "MetaDataException: Cannot get database meta info" Log analysis showed this root error: com.microsoft.sqlserver.jdbc.SQLServerException: Cannot resolve the collation conflict between "SQL_Latin1_General_CP1_CI_AS" and "Latin1_General_CI_AS" in the INTERSECT operation.[/code]Resolution:This customer was using Microsoft Sql Server 2008 r2 , JAVA version 1.6.0_43. Their DBA indicated no known collation problems across their tables. They found that replacing the microsoft jdbc driver, sqljdbc4.jar, with a newer version resolved the problem. Apparently there is an obscure defect in the older version of that driver. Ref. Case #00049457
  13. The 5.5 hotfix is available for the professional version of the product, if you are using the professional version of the product, you can open a case via your customer support portal and request it.
  14. Hyperlinks in Ad Hoc reports are not a supported feature. You can try to edit Ad Hoc reports within iReport or Studio, but in the case of a chart you may have some difficulty since the chart's dataset is more complex (built against domains or topics, thus generated/referenced in a different manner).
  15. I'd crank up spring auth related logging in log4j.properties: log4j.logger.org.springframework.security=DEBUG It's possible that you are using the pro product, with multi-tenant feature and your soap app is specifying an organization while you aren't doing the same via the login? Or is it possible that your login is using customized filters and your entrypoints for the soap urls go thru some filters while your regular UI login page go thru different filters?
  16. You could create a secondary report that is your is "clicked bar detail" report. Then you create hyperlinks to this secondary report. Hyperlinks and an example for html5 charts are defined here http://community.jaspersoft.com/wiki/how-do-i-set-chart-hyperlinks-html5-charts, or amongst a larger snippet of info, here- http://community.jaspersoft.com/wiki/html5-charts-ireport#To_create_hyperlinks
  17. $X syntax for params is described here: http://community.jaspersoft.com/documentation/jasperreports-server-administration-guide-beta/query-based-input-controls But that's more appropriate for creating an IN clause in a SQL query. You need to cast your collection into string that retains the delimited values? parameters can be based upon values of other parameters. Sounds like you need to investigate a java method like this org.springframework.util.StringUtils.collectionToDelimitedString($P{mycollection},",") <-- that could be the expression of the parameter which you pass to the storedproc
  18. 0nce you choose "none" , I wonder if the param is being calculated as "" or empty. And in $X syntax, empty results in 1=1 or 0=0.... so if you stick 0=0 instead your where clause instead of "where Category IN {x,y,z} - you get back all results. If you set defaultValueExpressions does the behavior change? For null try: <defaultValueExpression><![CDATA[]]></defaultValueExpression>[/code]
  19. the mechanism for porting repo data from one server/environment to another is our js-export and js-import tools documented in the Admin guide. The commands fetch the repo data from the db in xml format and store them in a zip. These are command utilities in all versions, but also in recent versions you can use the from the UI's Manage ->server settings pages.
  20. This Article will discuss how to submit queries via JDBC outside of JasperReports Server via command line tools, like SQLLine For query development, connection testing, or performance reasons sometimes you want to execute a query in a manner that matches the connection and execution of JasperReports Server. To do this you simply need a jdbc driver and a program that uses this driver to call your query. Note that this is different from using psql for postgres, or sqlplus for Oracle, mysql for MySQL, and isql Sybase, etc because these tools use native apis for connection, not JDBC. ResolutionIn hosts with a GUI you can install a feature-rich JDBC-based client like squirrel (http://squirrel-sql.sourceforge.net). Without a GUI, or for something more simple, try the cmdline-only tool, SQLLine. To use SQLLineJava needs to be on your executable PATH, and you need versions of jline-xxx.jar, sqlline-xxx.jar, and your jdbc driver jar. The first two are attached in jars.zip, or you can download them from http://jline.sourceforge.net/downloads.html and http://sqlline.sf.net/download.html. Copy all three jars into a single directory, like my example: /opt/ghudson/mysqlLine/ To start SQLLine, follow the syntax below. Linux:[root@localhost /]# java -Djava.ext.dirs=/opt/ghudson/mysqlLine/ sqlline.SqlLine Windows:C:\Users\ghudson>java -Djava.ext.dirs="C:\tools_apps\mysqlLine" sqlline.SqlLine Use the !connect command within SQLLine, after it starts, to connect to your database. Pass your jdbc connection string, username, password, jdbc driver classname as parameters to !connect. Then execute querys. See windows cmd.exe example below of starting then connecting to a mysql db as user root with password tiger5: C:\Users\ghudson>java -Djava.ext.dirs="C:\tools_apps\mysqlLine" sqlline.SqlLine sqlline version 1.0.2 by Marc Prud hommeaux sqlline> !connect jdbc:mysql://localhost:3306/sugarcrm51 root tiger5 com.mysql.jdbc.Driver Connecting to jdbc:mysql://localhost:3306/sugarcrm51 Connected to: MySQL (version 5.1.59-community) Driver: MySQL-AB JDBC Driver (version mysql-connector-java-5.1.10 ( Revision: ${svn.Revision} )) Autocommit status: true Transaction isolation: TRANSACTION_REPEATABLE_READ Querying0: jdbc:mysql://localhost:3306/sugarcrm51> select distinct billing_address_state from accounts where billing_address_city = 'Los Angeles'; +------------------------+ | billing_address_state | +------------------------+ | CA | +------------------------+ 1 row selected (0.108 seconds) 0: jdbc:mysql://localhost:3306/sugarcrm51> Select SLEEP(30); +------------+ | SLEEP(30) | +------------+ | 0 | +------------+ 1 row selected (30.129 seconds) When you are finished, close your connections with the !closeall command: 0: jdbc:mysql://localhost:3306/sugarcrm51> !closeall Closing: com.mysql.jdbc.JDBC4Connection sqlline> Then control-C to exit sqlline entirely. Full command documentation and syntax can be found at http://sqlline.sourceforge.net/ Ref. Case #00048969 jars.zip
  21. ProblemWhen clicking the "test connection" button in Jaspersoft Studio's Server Connection Wizard an error occurs: Exception, if you want to see more information look into details Reason: No password provided. Details: org.eclipse.equinox.security.storage.StorageException: No password provided. at org.eclipse.equinox.internal.security.storage.SecurePreferences.put(SecurePreferences.java:237) ... etc Continuing to try "test connection" results in a "401" authentication error code. ResolutionStudio stores passwords in a secure manner, based on eclipse framework storage settings documented here: http://help.eclipse.org/helios/index.jsp?topic=%2Forg.eclipse.platform.doc.user%2Freference%2Fref-securestorage-start.htm We are unsure of the cause of this problem. Perhaps it could occur if mulitple installs of Studio have occurred incorrectly or Studio un-installs have occurred incorrectly, etc. In these cases you may need to reset these password storage mechanisms. Things to tryWindows->Preferences ->General -> Security -> Secure Storage | Contents tab: Delete the old information stored in preference by clicking the button delete at the right bottom corner. There is also a setting to setup just "plain-text" passwords that might be a useable workaround if you are stuck. In >Preferences>Jaspersoft Studio>Global Settings there is a checkbox "Use the Secure Storage to save credentials" which can be unchecked to let plain-text, but unsecure passwords be used. Ref. Case #00049085
  22. Issue Description:A customer's Ad Hoc View contains filters which were populated with foreign characters from their MYSQL datasource. When selecting these foreign characters in the filters, the "enable view query" showed valid SQL containing appropriate looking characters, but the result-set returned from the database was obviously incomplete, the correct data was not being displayed in the view. Additionally, using native database tools, like SQLYog for MYSQL, the customer could execute the same SQL statement without error, returning desired resultset. Resolution:Further testing in iReport/JS Studio also lead to no result-set returning, so settings on the database-side or jdbc-side needed to be adjusted. Manipulation of MYSQL's .ini or .cfg file resolved the problem for non-native connections like JDBC. In the client section try adding: [mysql] # orig default-character-set=latin1 default-character-set=utf8 And in the server section, down under [mysqld] add: # orig character-set-server=latin1 character-set-server=utf8 collation-server=utf8_general_ci Ref. Case #00046642
  23. Is jasperreports-extensions-x.x.x.jar on the classpath? If not, you can get it from <ireport>ireportmodulesext
  24. I wonder if your data-Adapter is specific to only one Studio project, but your report is in another. In this case you might need to configure the Build Path for this other project and add the jar containing the jdbc driver.
  25. Doc regarding the ireport "plug-in" which Studio mimics: http://community.jaspersoft.com/documentation/jasperreports-server-user-guide/v550/accessing-reports-and-domains-ireport
×
×
  • Create New...