karaf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lukasz Lech (JIRA)" <j...@apache.org>
Subject [jira] [Created] (KARAF-5348) Log redirected to Console, hangs until Ctrl+C pressed
Date Thu, 07 Sep 2017 09:11:00 GMT
Lukasz Lech created KARAF-5348:
----------------------------------

             Summary: Log redirected to Console, hangs until Ctrl+C pressed
                 Key: KARAF-5348
                 URL: https://issues.apache.org/jira/browse/KARAF-5348
             Project: Karaf
          Issue Type: Bug
          Components: karaf-shell
    Affects Versions: cellar-4.1.0
         Environment: Windows 10 x64
            Reporter: Lukasz Lech


The issue is random. It happens from time to time, after starting Karaf. 

Everything starts fine, until my code invokes JPA and an attempt to create database connection
is made. Than everything hangs. 

My attempts to locate the problem are listed here: https://stackoverflow.com/questions/45283937/eclipselink-hangs-while-creating-session-in-logging-subsystem

I've located the hanging threads and I've found out, that it's the FileOutputStream.writeBytes
method that hangs. It is invoked by EntityManager's attempt to log info. 

The solution was to restart karaf, because the error seemed to happen randomly every X starts.
However, recently I've accidentally pressed Ctrl+C in console and the call unlocked, with
the log message apearing onto console.

It looks like, then, that it was the console that was blocking the call. I'm not sure if it's
not caused by accidentally pressing some key in the moment the cmd window appear on screan
and steals focus, however, anything blocking logging subsystem is a potential bug in production
system. 

I haven't noticed that behaviour on linux (I launch Karaf in docker container there) but I
can't state either the problem is limited to Windows. It seems to be random, anyway, so I
have no strategy to replicate it. 



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message