Defect #2193
closedLRT: configure logback to show configured thread name in logs
100%
Description
Check thread pools (test + event) usage, prevent to reuse LRT thread in event processing. This could lead to change authentication context for already running task.
Related issues
Updated by Radek Tomiška over 4 years ago
- Subject changed from LRT: authentization is changed during tas processing to LRT: authentization is changed during task processing
Updated by Radek Tomiška over 4 years ago
I'm not able to reproduce the issue with changing authorization for running LRT.
Spring default logback configuration uses wrong thread name in logs - is generated generally with prefix 'task-executor-' for all thread pools created by bean configuration. This can lead to misunderstanding, which thread pool is used.
Change logback configuration is needed to show thread pool prefix by thread pool configuration:
logging.pattern.console=%d{yyyy-MM-dd HH:mm:ss.SSS} %5level %relative --- [%thread] %logger{36}.%M : %msg%n logging.pattern.file=%d{yyyy-MM-dd HH:mm:ss.SSS} %5level %relative --- [%thread] %logger{36}.%M : %msg%n
I will continue with transaction id - is posible to authentication is ok, but transaction is reused somehow. Then i will check project implementation.
Updated by Radek Tomiška over 4 years ago
- Subject changed from LRT: authentization is changed during task processing to LRT: configure logback to show configured thread name in logs
- Status changed from In Progress to Needs feedback
- Assignee changed from Radek Tomiška to Vít Švanda
- Priority changed from High to Low
- % Done changed from 0 to 90
I improved logging, added annotations for documentation reason and set properties above into product.
I'm not able to reproduce issue with relogin in processed LRT, but I've added some logs into DefaultLongRunningTaskManager and DefaultEntityEventManager, we can debug project if it occurs again.
Commit:
https://github.com/bcvsolutions/CzechIdMng/commit/0484ca117f2d540bdd769a1d4288340a93ba5657
Doc:
https://wiki.czechidm.com/devel/documentation/application_configuration/dev/backend#logger
Could you please test tomcat setting above and provide me a feedback please? After that I will ask sys to update instalation guides.
Updated by Vít Švanda over 4 years ago
- Status changed from Needs feedback to Resolved
- Assignee changed from Vít Švanda to Radek Tomiška
- % Done changed from 90 to 100
I did review. Thanks for that.
Updated by Radek Tomiška over 4 years ago
- Status changed from Resolved to Closed
Updated by Radek Tomiška over 4 years ago
- Related to Task #2203: Configure pattern for logback - server configuration documentation added