[
https://issues.apache.org/jira/browse/TIKA-4319?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Corrado Fiore updated TIKA-4319:
--------------------------------
Description:
I was trying to create a systemd unit file for Tika and I noticed that the
server will return an exit code of `1` instead of `0`. This makes it confusing
b/c systemd will report that the service crashed (whereas it started correctly).
h3. Steps to reproduce the problem
{{{color:#00875a}user@test-instance{color}:~$ sudo su -c
"TIKA_INCLUDE=\"/etc/default/tika.in.sh\" /opt/tika/bin/tika start" - tika}}
{{Default server /opt/tika/}}
{{Waiting up to 180 seconds to see Tika running on port 9998 [-] }}
{{Started Tika server on port 9998 (pid=50039}}
{{50001). Happy extracting!}}
{{{color:#00875a}user@test-instance{color}:~$ echo $?}}
{{1}}
h3. Expected behaviour
A command that executes successfully should exit with an exit code 0.
was:
I was trying to create a systemd unit file for Tika and I noticed that the
server will return an exit code of `1` instead of `0`. This makes it confusing
b/c systemd will report that the service crashed (whereas it started correctly).
h3. Steps to reproduce the problem
{{user@test-instance:~$ sudo su -c "TIKA_INCLUDE=\"/etc/default/tika.in.sh\"
/opt/tika/bin/tika start" - tika}}
{{Default server /opt/tika/}}
{{Waiting up to 180 seconds to see Tika running on port 9998 [-] }}
{{Started Tika server on port 9998 (pid=50039}}
{{50001). Happy extracting!}}
{{user@test-instance:~$ echo $?}}
{{{}1{}}}{{{}{}}}
h3. Expected behaviour
A command that executes successfully should exit with an exit code 0.
> Wrong exit code upon successful start of Tika server
> ----------------------------------------------------
>
> Key: TIKA-4319
> URL: https://issues.apache.org/jira/browse/TIKA-4319
> Project: Tika
> Issue Type: Bug
> Components: server
> Affects Versions: 2.9.2
> Environment: Tested on a Debian 12 VM with the following kernel:
> 6.1.0-11-cloud-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.38-4 (2023-08-08)
> x86_64 GNU/Linux
> Reporter: Corrado Fiore
> Priority: Trivial
> Labels: easyfix
>
> I was trying to create a systemd unit file for Tika and I noticed that the
> server will return an exit code of `1` instead of `0`. This makes it
> confusing b/c systemd will report that the service crashed (whereas it
> started correctly).
> h3. Steps to reproduce the problem
> {{{color:#00875a}user@test-instance{color}:~$ sudo su -c
> "TIKA_INCLUDE=\"/etc/default/tika.in.sh\" /opt/tika/bin/tika start" - tika}}
> {{Default server /opt/tika/}}
> {{Waiting up to 180 seconds to see Tika running on port 9998 [-] }}
> {{Started Tika server on port 9998 (pid=50039}}
> {{50001). Happy extracting!}}
> {{{color:#00875a}user@test-instance{color}:~$ echo $?}}
> {{1}}
> h3. Expected behaviour
> A command that executes successfully should exit with an exit code 0.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)