Re: Performance Analysis
- Original Message - From: Rhett Aultman [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, July 19, 2002 5:26 PM Subject: RE: Performance Analysis If you're really concerned about finding the source of the memory drain, I really have to :-) Yyou may want to run the JVM with a JVMPI memory profiling agent running. jProf is a pretty good one. If you do a Google search for jProf, you'll find it, and if you need help using it, I'm here. I've written a JVM profiling agent before, so I know my way around that block. IIRC, the heaviest drain on FOP is dealing with graphics and SVG. As for the question about keeping a thread with System.gc() running... That may help the JVM to more aggressively clean out memory, but most memory leaks in Java are caused by objects that the GC misses, either because of some unusual memory lay our or (more commonly) because a part of the program is still holding a reference to the object. It may not even be leaking memory...it could just be heavy usage. Heavy but conscientious use of memory would still cause memory to run out, and all the calls to System.gc() in the world won't keep that from happening. Aside from all of that, calling System.gc() does not guarantee that the GC will run. All it does is offer a suggestion that the GC's priority be greater for a short period of time. If you really want deterministic garbage collection, there are some JVMPI and JNI tricks that will let you get away with it, but in general, this won't really help your memory concerns. -Original Message- From: Holger Prause [mailto:[EMAIL PROTECTED]] Sent: Friday, July 19, 2002 11:17 AM To: [EMAIL PROTECTED] Subject: Performance Analysis - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
RE: Performance Analysis
If you're really concerned about finding the source of the memory drain, I really have to :-) you may want to run the JVM with a JVMPI memory profiling agent running. jProf is a pretty good one. If you do a Google search for jProf, you'll find it, and if you need help using it, I'm here. I've written a JVM profiling agent before, so I know my way around that block. That very nice, i could need it (Is JProf an api and u coded an profiler using that api?). I have to test it on a custom tag library - performing the xslt transformation. Can u mail the program to me ? My mail is [EMAIL PROTECTED] In the mean time i found out what takes so much memory, its a very brave way of programming (using strings as buffer instead of byte streams, etc...).As workaround i increased the heap of the vm to 256m. IIRC, the heaviest drain on FOP is dealing with graphics and SVG. Thats what all ppl told me as answer for my question what takes most memory.Ill suggest our customer to reduce the use of images. As for the question about keeping a thread with System.gc() running... That may help the JVM to more aggressively clean out memory, but most memory leaks in Java are caused by objects that the GC misses, either because of some unusual memory lay our or (more commonly) because a part of the program is still holding a reference to the object. It may not even be leaking memory...it could just be heavy usage. Heavy but conscientious use of memory would still cause memory to run out, and all the calls to System.gc() in the world won't keep that from happening. Aside from all of that, calling System.gc() does not guarantee that the GC will run. All it does is offer a suggestion that the GC's priority be greater for a short period of time. Ok good to know, but thats not very new for me.Hmm is that Thread running in fop or not ? (I suppos its not because of the funny answers i got) If you really want deterministic garbage collection, there are some JVMPI and JNI tricks that will let you get away with it, but in general, this won't really help your memory concerns. I think that will not be necessary. Thank you very much, Holger -- GMX - Die Kommunikationsplattform im Internet. http://www.gmx.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: Character Encoding
- Original Message - From: J.Pietschmann [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, July 09, 2002 9:58 PM Subject: Re: Character Encoding Holger Prause wrote: I use the character squence #8722; in a html page it will be dispalyed as an - minus sign. So far so good.Now i want to use that chracter sequence in FO but in the ^ ^ ^ ^ ^ ^ ^ It is a character reference Yes your are right. generated pdf it will displayed as an # sign(which stands for undefined ?) This means the selected font does not have a glyph for it. Ok i undestand that, its also written in the FOP Faq. What can i do to display this character squence, changeing the encoding in the stylesheet(or using xsl:output /)? The only way is to get a font with a glyph for it and let FOP use it. The mathematical minus is pretty esoteric, you'll probably need a special math font, rummage through implementations for MathML or TeX distributions. Why can't you usse a dash or hyphen? What i wanted was a dash, but for some reasons i choosed the character reference #8722; which is , like u already said, a mathematical minus. Now i use a the character reference for dash , and i works fine with my font. Thx for the quick response, Bye, Holger J.Pietschmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Stupid Question
Where do i can get the api docs for fop ? I already read the FAQ. As far as i can see it is not include in the distribution. Thx, Holger - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: Stupid Question
- Original Message - From: RamanaJV [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 10, 2002 12:29 PM Subject: RE: Stupid Question Refer to the JavaDocs folder in your FOP home directory. Ramana.JV. I got it, its diretly in theFOP home directory like u told me, but its only there if u download the src version and if u build the project Thank You, Holger - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: Converting HTML Table to PDF
- Original Message - From: Gilles Beaugeais [EMAIL PROTECTED] To: [EMAIL PROTECTED] Cc: Nicolas Goyet [EMAIL PROTECTED] Sent: Tuesday, July 02, 2002 10:51 AM Subject: Converting HTML Table to PDF Hye, Hi I need to convert a complex HTML table (with spannings, borders) to PDF. I had to do a similar task a time ago. Does someone have a xsl-fo script to do this ? Yes there is one but i will not work properbyl with any xslt engine because the the full xsl fo specification is not implemented from any xslt engine,yet http://www.antenna.co.jp/XML/downfree/Xhtml2fo.xsl Thanks for help. Gilles Beaugeais. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: PDF in a JSP ... searching alternative way
- Original Message - From: Massimiliano Cuccia [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, June 20, 2002 6:48 PM Subject: PDF in a JSP ... searching alternative way I want to produce a pdf in a jsp, so I have a string fo that contains the fo instructions ... I had found this code to output the pdf directily in the browser Driver driver = new Driver(new InputSource(new StringBufferInputStream(fo)), response.getOutputStream()); and it's OK, there is another way to do that task? I don't want to pass the response.getOutputStream() actual parameter ... any ideas?? A good way for performing xslt(an render it with fop) is using the xsl Taglibs from the jakarta project http://jakarta.apache.org/taglibs/doc/xsl-doc/intro.html thanks in advance bye -- -- Massimiliano Cuccia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: FopServlet
- Original Message - From: J.Pietschmann [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, June 14, 2002 1:47 AM Subject: Re: FopServlet Nirupama Yalavarti wrote: Thats a great anwere...THE servlet seems to ahve run correctly( In fact it didnt show me any error..) But where can I find the produced pdf? any idea? In your browser? Look into the browser cache first. IEx is a bit fragile when it comes to showing PDF. Configure your webapp so that you can use an URL ending in .pdf for retrieving the PDF: http://my.host/some/path/to/servlet.pdf or http://my.host/some/path/to/servlet.pdf?xml=foo.xmlxsl=foo.xsldummy=.pdf Hello, maybe you have Avtive X disabled and thats the reason why u dont see the produced pdf. I took my an half an hout to find this out .-) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: Interesting Comment
- Original Message - From: Arved Sandstrom [EMAIL PROTECTED] To: [EMAIL PROTECTED] [EMAIL PROTECTED] Sent: Friday, May 17, 2002 2:50 AM Subject: Interesting Comment Hello, Example #4 in Brett McLaughlin's XML Data Binding article on OReilly Net (http://www.onjava.com/pub/a/onjava/2002/05/15/databind.html). Very good Article.Thats exactly what i was looking for my own little project. Heres an Api that supports XML data Binding http://java.sun.com/xml/jaxb/. Ill check it out and write something about it here in the mailing list if desired. Its SQL Databinding avaible too ? (All Sql Wrapper Tools is tried out didnt generated the desired object structure for my purposes) Pretty obvious stuff but it's nice to see that people outside the XSL-FO community are aware of the technology and finding uses for it. I use xml mostly for data exchange between different applications(Soap,xml-rpc,BMECat,Xcbl,etc.). For my own little project i use xml as a a flatfile database. Regards, AHS __ Arved Sandstrom Sr Software Developer Platform Products Group Halifax RD Office Hummingbird Ltd Bye, Holger Prause - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
fo:external-graphic
Hello, I have to make a FOP customization for processing the fo:external-graphic statement.(Because the imges are stored in a strange way which i dont want to explain in details) What classes should i take a look at ? Whats the best entry point for that ? Thank you very much , Holger Prause - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Fw: keep-together.within-page implemented ?
- Original Message - From: Holger Prause [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, May 07, 2002 7:27 PM Subject: keep-together.within-page implemented ? Hello, I have some problems using keep-together.within-page and i am wondering if its implemented yet. (Obviously not, see http://xml.apache.org/fop/implemented.html# , i could not find it anywhere) But i dont get any warnings or errors that keep-together.within-page is not implemented yet. Here is a good sample stylesheet which uses the keep-together.within-page attribute http://www.renderx.com/Tests/pagebreak.fo The resulting pdf file is not the expected.The attribute keep-together.within-page will be ignored. http://www.renderx.com/Tests/pagebreak.pdf Thanx in Advance, Holger - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Logging Issuae AVALON vs LOGKIT
Hello, i have some questions about the status of the development of the logging class First of all some information about the jars i have in classpath 1 fop.jar from version fop-0.20.3 2 avalon-framework-4.1.2.jar from version Avalon-4.1.2 3 logkit.jar from version LogKit-1.0.1 I am a little bit cunfused about the using of the use of Loggin classes I downloaded the current source code(fop-0.20.3-src.tar.gz )and found out that its definitivly a fact that the Driver class only accepts an org.apache.log.Logger class from LOGKIT as a input parameter On the hompeage of FOP http://xml.apache.org/fop/embedding.html is written : FOP uses Jakarta Avalon's Logger interface http://jakarta.apache.org/avalon/api/org/apache/avalon/framework/logger/Logger.html# to do logging. See the Jakarta Avalon project for more information., but org.apache.log.Logger class from LOGKIT is NOT compatible with the org.apache.avalon.framework.logger class from AVALON So my conclusion is that FOP uses LOGKIT and not AVALON Another issue is that the documentation for logkit is not up to date ot not full documented http://jakarta.apache.org/avalon/logkit/api/index.html show no constructor details but when u download the current source version of logkit and if u take a look in the file Logger.java u will see that Logger has no default constructor , just a parametrized on pre Logger( final ErrorHandler errorHandler, final String category, final LogTarget[] logTargets, final Logger parent ) { } /pre It seems to be intended to make use of the Logger classes from the AVALON project in FOP(which is in my opinion the right way to do this logging stuff) ,but its not implemented yet.Pls correct me if i am wrong. What is the status of this development ? Can i use the AVALON Logger classes in FOP in the next time ? Thx a lot , Holger -- GMX - Die Kommunikationsplattform im Internet. http://www.gmx.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: Logging Issuae AVALON vs LOGKIT
The change from LogKit to Avalon Logger has happened after the 0.20.3 release. The documentation on the website already reflects the changes in CVS. There's no release yet with the new logging. You could download the CVS-version, though. Ok ,thx for this information, but our intranet solution is based on fop.0.20.3 and its running stable , so i have wait for the next realease(to much depends from FOP, we have 20 Stylesheets). Thx again, Holger -- GMX - Die Kommunikationsplattform im Internet. http://www.gmx.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
output PDF via java.io.Writer
Hello, I am using Fop-0.20.2 Is it generally possible to output a pdf stream via a java.io.Writer object ? I know its better to use OutputStreams objects to output binary streams as pdf,but i want to use a JSPWriter(in a TagLibrary Class) to output a Pdf Stream so that i can use it as embedded pdf. The following sourcode should do the the job InputSource foInputSource = getInputSource(); //buffer fo outputStream ByteArrayOutputStream foBufferStream = new ByteArrayOutputStream(); Driver driver = new Driver(foInputSource,foBufferStream); driver.setRenderer(driver.RENDER_PDF); //perform the fo rendering process driver.run(); String foOutString = new String(foBufferStream.toByteArray()); //the writer reference is as reference to the JSPWriter which was passed as Argument writer.write(foOutString); writer.flush(); The problem is that when i convert a ByteArrayOutputStream to a String , some characters are converted wrong. For Example , the HEX 8d will be converted to HEX 3f , how can i avoid this ? What encoding do i have to use to avoid this ? Thank you in advance, Holger -- GMX - Die Kommunikationsplattform im Internet. http://www.gmx.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]