Marco Bizzarri wrote:

> On 12/7/06, Mathias Bauer <[EMAIL PROTECTED]> wrote:
>> Marco Bizzarri wrote:
>>
>> > Hi all.
>> >
>> > I've a running OpenOffice server, to which I connect via UNO.
>> >
>> > I then issue a number of operations to the OpenOffice server, in order
>> > to manipulate documents.
>> >
>> > This process is quite slow (it takes 1.5 seconds on my test machine),
>> > and I would like to see if I can improve it. I need more investigation
>> > of course in order to find the bottleneck. However, I think if I could
>> > move the processing from my process to the OpenOffice process I could
>> > save a lot of overhead in the communication.
>> >
>> > Two questions:
>> >
>> > 1) is it this the right mailing list to ask these questions?
>>
>> At least it's not completely wrong. :-)
> 
> Good :-)
> 
>> > 2) is it possible to achieve what I'm looking for?
>> If I understood correctly you want to remove the overhead produced by
>> remote calls. To do this you must move your code into a UNO component
>> and install it as an extension to OOo. You then can instantiate and run
>> this UNO component with one or two remote calls.
>>
>> The UNO component must be implemented in Java, Python or C++, the latter
>> would give the best performance because even Java components running in
>> the same process as OOo still use a UNO bridge to communicate with OOo.
>>
>> But maybe I misunderstood you.
>>
>> Ciao,
>> Mathias
> 
> No, you understood me very well. Since I'm working on a Python
> application, I have read the pages about the UNO components in python
> (http://udk.openoffice.org/python/python-bridge.html).
> 
> On that pages, however, I read the following about writing UNO components:
> 
>     *   you want to easily roll out your code to multiple other
> machines (using UNO packages)
>     * your scripts shall get triggered by UI events (menu or toolbars)
>     * you have collected some experience with PyUNO
>     * you want your script to run with the best performance
> 
> This bring me a question: are UNO components to be activated only from
> UI events? Or they can be activated via remote calls from another
> process?

*Every* UNO-Service can be instantiated by the service manager in any
application that is connected to OOo. So if you inject your own service
into OOo's service manager by installing an extension providing the
necessary registry information not only OOo but also any client
application bootstrapping a connection to OOo can instantiate it.

Ciao,
Mathias

-- 
Mathias Bauer (mba) - Project Lead OpenOffice.org Writer
OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS
Please don't reply to "[EMAIL PROTECTED]".
I use it for the OOo lists and only rarely read other mails sent to it.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to