Crashes with javafx extension in Linux

Discussions about using 3rd party extension with OpenOffice.org
Post Reply
arch
Posts: 7
Joined: Sat Jan 10, 2015 8:00 am

Crashes with javafx extension in Linux

Post by arch »

Hello
I got an extension which works fine on windows systems, but openoffice crushes when i try to use in on linux, tested it on Arch,CentOs,fedora results are same... There is no exception thrown in logs, also no exception happens when debugging from source code.What may be the reason?
OpenOffice Version : 4.1.0
Os : Arch Linux x86_64
User avatar
RoryOF
Moderator
Posts: 34586
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: OO Crashes when trying to use extension in Linux

Post by RoryOF »

What extension? Name and URL, please.
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
arch
Posts: 7
Joined: Sat Jan 10, 2015 8:00 am

Re: OO Crashes when trying to use extension in Linux

Post by arch »

RoryOF wrote:What extension? Name and URL, please.
Unfortunately can't link the extension.
Its custom extension, it just loads javafx window to connect to other software, can see the addon in openoffice menu but when it tries to load javafx openoffice freezes. Is there any known issue with openoffice & javafx in linux?
OpenOffice Version : 4.1.0
Os : Arch Linux x86_64
User avatar
RoryOF
Moderator
Posts: 34586
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: Crashes with javafx extension in Linux

Post by RoryOF »

I don't know of any problem. If it works when compiled in debug mode it may be a timing problem and some carefully inserted delays may help.
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
arch
Posts: 7
Joined: Sat Jan 10, 2015 8:00 am

Re: Crashes with javafx extension in Linux

Post by arch »

No it's same when i run it in debug mode, the problem is that there is no exception thrown whatsoever, no errors in openoffice logs, but it freezes. Cant understand what causes the crush, os java or oo.
OpenOffice Version : 4.1.0
Os : Arch Linux x86_64
bankadmin
Posts: 2
Joined: Tue Jan 13, 2015 11:59 am

Re: Crashes with javafx extension in Linux

Post by bankadmin »

Thank you for your reply RoryOF,

Link to extension will be provided soon , but it is really does not meter . Even "Hello World" on JavaFX crashes same way.
OpenOffice 4.1.1 on CentOs 6.5 , Fedora and/or Windows 7
bankadmin
Posts: 2
Joined: Tue Jan 13, 2015 11:59 am

Re: Crashes with javafx extension in Linux

Post by bankadmin »

Problem was resolved.
Java FX works perfectly for AOO Extensions on Linux
OpenOffice 4.1.1 on CentOs 6.5 , Fedora and/or Windows 7
User avatar
RoryOF
Moderator
Posts: 34586
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: Crashes with javafx extension in Linux

Post by RoryOF »

Will you please expand on what caused the problem?
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
arch
Posts: 7
Joined: Sat Jan 10, 2015 8:00 am

Re: Crashes with javafx extension in Linux

Post by arch »

RoryOF wrote:Will you please expand on what caused the problem?
Managed to catch exception, it had problem with loading resources and class initialization. I think there is some problem which bugs classloader when javafx launched from oo. So, manualy setting classloader in init methods solved the problem.

ClassLoader cl = Thread.currentThread().getContextClassLoader();
if (cl == null) {
cl = ClassLoader.getSystemClassLoader();
Thread.currentThread().setContextClassLoader(cl);
}
OpenOffice Version : 4.1.0
Os : Arch Linux x86_64
User avatar
RoryOF
Moderator
Posts: 34586
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: Crashes with javafx extension in Linux

Post by RoryOF »

I don't know enough about Java to comment sensibly, except to say that when a program/macro works in manual mode and not in installed mode, there can often be some form of timing problem. A delay loop inserted might cure the problem - there was a recent case of this reported on the Forum when a macro was being used.
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
Post Reply