Re: Docbook 5.x

From: Alexander Lakhin <exclusion(at)gmail(dot)com>
To: Jürgen Purtz <juergen(at)purtz(dot)de>, Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Cc: pgsql-docs(at)postgresql(dot)org
Subject: Re: Docbook 5.x
Date: 2017-09-18 14:38:27
Message-ID: 11c0be48-6125-bbe1-1d02-6d61e889bd5e@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs

Hello,
15.09.2017 21:54, Jürgen Purtz wrote:
> On 15.09.2017 19:32, Peter Eisentraut wrote:
>> On 9/8/17 08:30, Alexander Lakhin wrote:
>>>> I have started working through these patches now. I have committed the
>>>> escaping of < and & and will work through the rest slowly, to minimize
>>>> disruptions to other development.
>>> Great!
>>>
>>> I have rebased all the remaining patches and updated scripts for the
>>> current master (see attachment).
>> So, I've been looking at this profiling stuff, to replace the marked
>> sections in the installation instructions. I found the overhead of that
>> a bit too much for building the full documentation, so I have come up
>> with the attached alternative solution. What do you think?
Peter, can you show what performance drop you see with the profiling
(e.g. for HTML)?
I get the following numbers:
1. make html with profiling (import profile-chunk.xsl in stylesheet.xsl):
85.98user 0.76system 1:29.85elapsed

2. make html without profiling (import chunk.xsl in stylesheet.xsl):
77.36user 0.62system 1:21.28elapsed

3. Separate profiling (performed before making epub, as dbtoepub doesn't
support profiling)
8.52user 0.22system 0:10.31elapsed

So I get ~10% performance drop when making html. Are you concerned about
the same overhead?
I would choose some standard way to have separate content in the same
file, but if the overhead is not acceptable, and we're not going to
extend the profiling usage, then we need to invent something that will
complicate XML-related processing (I think about translation but the
other issues are possible too).

> I'm not happy with the 'particular conversions'-part of
> 'standalone-profile.xsl'. It applies subsequent modifications, which
> are in not very intuitive to a reader, eg:
>
> <xsl:template match="phrase[(at)id='install-ldap-links']">
> <xsl:text>the documentation about client authentication and
> libpq</xsl:text>
> </xsl:template>
>
> This approach spreads the intended text over two very different files
> (in this example: 'installation.xml' and 'standalone-profile.xsl').
>
> My suggestion is to keep the source code in one file in the same
> manner as with the SGML standalone-include/standalone-ignore
> mechanism. A *generic* xsl file shall create the extended output
> similar to 'standalone-profile.xsl'.
>
Jürgen, this approach implemented by applying profiling.xsl in Makefile
(for make postgres.epub). (See Makefile in
https://www.postgresql.org/message-id/attachment/54854/pg-doc.check.tar.bz2)

Best regards,
Alexander

In response to

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message jonny.battiato 2017-09-18 17:04:50 max_replication_slots in subscriber for subscription?
Previous Message Peter Eisentraut 2017-09-18 13:57:02 Re: Docbook 5.x