How can I generate the JMeter HTML/dashboard report without having always generated and saved the sbadmin2 folder that is needed for the bootstrap layout? Also, where does the import of the results into the index.html file happen?
The feature you're asking for does not exist, I've created this enhancement request for it:
https://bz.apache.org/bugzilla/show_bug.cgi?id=61458
It should not be to hard to add if it's needed.
Related
I'm starting with Adobe AEM right now and as my first training, I was in need of importing a static image into a template.
I have a 100% static page but I can't seem to find out how to use an image that I've saved in /etc/designs/{MY_PROJ}/clientlib-site/img.
That's the real example of the problem I'm facing:
I've the following snippet inside my template:
<img src="/etc/designs/{MY_PROJ}/clientlib-site/img/logo.png"/>
My folder structure looks like the following (Link to imgur)
I was able to use the sly tag to import my CSS and JS correctly. But I really can't understand why I can't import images as well. Any thoughts?
Thanks in advance!
If you are able to access your image directly http://localhost:4502/etc/designs/{MY_PROJ}/clientlib-site/img/logo.png
but not in www.yourhost.org/etc/designs/{MY_PROJ}/clientlib-site/img/logo.png it could be some /filter Dispatcher configuration.
If you cannot see your image, make sure you have set the proper filter in your vault workspace like so:
<workspaceFilter version="1.0">
/etc/designs/{MY_PROJ}/
</workspaceFilter>
More info about Jackrabbit filters: http://jackrabbit.apache.org/filevault/filter.html
Have you checked in CRX/DE http://localhost:4502/crx/de/index.jsp? If the image file is not present at the designated path in crx/de, it means the package is not installed successfully.
Then check the workspace filter file (usually located at /META-INF/vault/filter.xml) and ensure the image path is included and reinstall the package and watch the logs. There should be an log entry like
A /etc/designs/{MY_PROJ}/clientlib-site/img/logo.png
I created one custom java function in TIBCO designer. I loaded class file from my desktop. It was working fine. But, now I did some changes in that function and then created and loaded class file, but this time class file location is different(from clearcase). This cause an error where I used this function earlier and the error is :
"No function in namespace:java://xyz"(xyz is class file name which I not changed).
Please help me to resolve this error without changing previous code.
Please check your package hierarchy in the Java file, if there is no change, looks like your Designer did not pick up the latest .class file from the new location.
1. Retry by completely closing your designer instances in your machine.
2. Reload by browsing the new .class file and save your project.
3. Check by validating this particular process only.
Hope you are out of this issue already.
so I am in the process of making a small application.
Right now, the project works fine. I am running it through an IDE. The problem comes about when trying to run the project as a jar - which is the end result. Right now, it fails to properly load the required files (classes and simple ASCII files).
The method I am using is one based off of:
final Enumeration<URL> paths = CLASS_LOADER.getResources("");
Where CLASS_LOADER is an instance of class.getClassLoader().
This works great when not inside a jar. Inside a jar though, it seems to fail horribly. For example, in the code above, paths would be empty.
I am assuming that the fault is that the files are all within a jar - the same jar to be precise.
The class path for the manifest file is blank at the moment.
If it helps, I have two tasks that require loading files.
I need to create a list of all files that are a subclass of
another class.
I need to load a list of language files (all of
which are in the same directory).
If you need anything else to help debug this problem or provide a solution - let me know. Thanks for reading this!
For ClassLoader.getResources() to work you need to feed a path relative to the jar root. If you want to search the jar then ClassLoader public API won't help you. You have to use custom code based on java.util.jar.JarFile, like the one here.
I'm using Jetty 8.0. to create a simple web server (html/json/png) inside my java application.
I added an handler to use jsp pages positioned inside a package (as mentioned here: http://docs.codehaus.org/display/JETTY/Embedding+Jetty):
String WEBAPPDIR = "com/econorma/jsp/resources";
String CONTEXTPATH = "/jsp";
URL warUrl = WebApplication.class.getClassLoader().getResource(WEBAPPDIR);
final String warUrlString = warUrl.toExternalForm();
WebAppContext webapp = new WebAppContext(warUrlString, CONTEXTPATH);
I tested this code in Eclipse without any problems: html and jsp both work.
My problem come when I run my jar deployed. I get NULL POINTER exception in the getClassLoader line.
I try to put the slash at the end of WEBAPPDIR as mentioned in one StackOverflow post but, also if I solve the null pointer exception, I can't me it work.
You need to put the updated codes of jsp and html files back into the jar to work properly.
The local jsp pages in the package com.econorma.ui.resources will be available only for development process and when you export your project as a war file. The jars will not have the changes that you made in jsp pages which you had in com.econorma.ui.resources.
So you need to copy of jsp or html files from the package you created. And then put these files in the jar in the appropriate packages and update it.
Now you have to build your project again after installing the new jars files and restart your jetty server to see the changes and you should be able to run your server without errors. Hope this helps.
There was two problems for my embedded jetty and jsp:
1-Missing code before calling my webClass:
System.setProperty("org.apache.jasper.compiler.disablejsr199", "true");
2-The Eclipse export to prepare the jar: I used the EXTRACT method and non the PACKAGE one and so it wasn't possibile to find jsp inside the jar.
I wrote some Java class, created jar file. I want to add it to JasperReports Server. When I determine the path to my jar file, using Tools -> Preferences -> Classpath menu in my iReport, it works correctly. But it doesn't work, when I take access to JR Server from another host.
What I must to do, to make this jar file available on this JR Server, from anywhere?
Option 1 - If you want to use your Jar in a several reports.
You should "Add Jar" (as it called in iReport repository manager) to some folder in the Jasper Server folder tree. Then "Add reference" to this resource in Resources section of you specific report.
Option2 - You need a jar in a specifc report.
Use "Add Jar" option in a resources section of specific report.
Worked perfectly on JasperServer 4.7
Add the jar as a resource of the report (if it's one time use) or add it to some path in Jasper Report Server and add a reference to it as Alex suggested.
I'd suggest you to create some folders in Jasper Server (via web interface or iReport) and put all commonly used filed there (be sure to manage correctly the permissions ROLE_USER should have access to the file but you can remove it from the folder so it's not listed).
Then use references on the reports that need those. For example, I use it for the report logo and some helper Java classes.
Edit as #NormTatlock asked more details on how to do it:
Create your Java package my.sample.package for example:
public class MyClass extends JRDefaultScriptlet ...
Compile it and upload the jar as a resource using its full name (e.g. my.sample.package.jar) or upload it to another folder and create a reference to it in the resources folder of the report.
Edit the report and set the Scriptlet Class property to:
my.sample.package.MyClass
Or set the property in the XML tag jasperreports (the root tag) as:
scriptletClass="my.sample.package.MyClass"
Use the scriptlet in your report like this:
$P{REPORT_SCRIPTLET}.myMethod(myParam1, myParam2)
Mind the return type of the methods and so on.
Hope it helps. Have fun!