Feature: show if currently connected
Closed this issue · 4 comments
GoogleCodeExporter commented
What steps will reproduce the problem?
1. Starting officeManager
2. It is impossible to know if it started up correctly without issuing an
execute() and trying if an exception will be thrown.
What is the expected output? What do you see instead?
I would like to have a function isRunning() to check if the openOfficeService
is running and jodconverter is connected to it.
I've attached a patch for this. It is debatable if it should return true or
false if ExternalOfficeManager is started with connectOnStart=false:
- False: It is not currently connected
- True: It is ready to receive tasks.
Original issue reported on code.google.com by benjamin...@uni-siegen.de
on 16 Aug 2011 at 7:37
Attachments:
GoogleCodeExporter commented
Is there anything I can do to increase the chances of inclusion of this patch?
Write some unit tests maybe?
Original comment by benjamin...@uni-siegen.de
on 5 Sep 2011 at 6:58
GoogleCodeExporter commented
The code looks fine to me. I don't see any reason not to include it. Still,
Mirko has the final say.
Can I ask why you want this feature?
Original comment by shervin.asgari@gmail.com
on 12 Sep 2011 at 12:31
GoogleCodeExporter commented
There are two reasons:
1) It is considered bad practise to branch according to wether an exception
will be thrown or not. However, currently, this was the only way to detect if
connect() worked: by testing if the convert() throws an exception.
2) The library that I am currently building
(https://github.com/benjamin4ruby/java-thumbnailer) tries to fail as early as
possible, thus even before the first convert() takes place.
Original comment by benjamin...@uni-siegen.de
on 15 Sep 2011 at 7:52
GoogleCodeExporter commented
Fixed in trunk.
If Mirko objects, he can just revert the code
Original comment by shervin.asgari@gmail.com
on 15 Sep 2011 at 8:07
- Changed state: Fixed
- Added labels: Type-NewFeature