[JBoss JIRA] (LOGMGR-141) StringIndexOutOfBoundsException throw while formatting log with truncation
by James Perkins (JIRA)
[ https://issues.jboss.org/browse/LOGMGR-141?page=com.atlassian.jira.plugin... ]
James Perkins updated LOGMGR-141:
---------------------------------
Git Pull Request: https://github.com/jboss-logging/jboss-logmanager/pull/98, https://github.com/jboss-logging/jboss-logmanager/pull/99, https://github.com/jboss-logging/jboss-logmanager/pull/100 (was: https://github.com/jboss-logging/jboss-logmanager/pull/98)
> StringIndexOutOfBoundsException throw while formatting log with truncation
> --------------------------------------------------------------------------
>
> Key: LOGMGR-141
> URL: https://issues.jboss.org/browse/LOGMGR-141
> Project: JBoss Log Manager
> Issue Type: Bug
> Reporter: James Perkins
> Assignee: James Perkins
> Fix For: 1.5.7.Final, 2.0.5.Final, 2.1.0.Beta1
>
>
> When value in left-justified field is longer than maximum width following exception is thrown:
> {code}
> java.lang.StringIndexOutOfBoundsException
> at java.lang.AbstractStringBuilder.delete(AbstractStringBuilder.java:733)
> at java.lang.StringBuilder.delete(StringBuilder.java:244)
> at org.jboss.logmanager.formatters.Formatters$JustifyingFormatStep.render(Formatters.java:212)
> at org.jboss.logmanager.formatters.MultistepFormatter.format(MultistepFormatter.java:83)
> at org.jboss.logmanager.ExtFormatter.format(ExtFormatter.java:32)
> at org.jboss.logmanager.handlers.WriterHandler.doPublish(WriterHandler.java:46)
> at org.jboss.logmanager.ExtHandler.publish(ExtHandler.java:76)
> at org.jboss.logmanager.LoggerNode.publish(LoggerNode.java:302)
> at org.jboss.logmanager.LoggerNode.publish(LoggerNode.java:310)
> at org.jboss.logmanager.LoggerNode.publish(LoggerNode.java:310)
> at org.jboss.logmanager.LoggerNode.publish(LoggerNode.java:310)
> at org.jboss.logmanager.Logger.logRaw(Logger.java:719)
> at org.jboss.logmanager.Logger.log(Logger.java:670)
> at org.jboss.logging.JBossLogManagerLogger.doLogf(JBossLogManagerLogger.java:50)
> at org.jboss.logging.Logger.logf(Logger.java:2096)
> {code}
> Steps to Reproduce:
> 1. Configure formatter with left-justified field with maximum width:
> {code}
> /subsystem=logging/periodic-rotating-file-handler=FILE:write-attribute(name=formatter,value="%d{HH:mm:ss,SSS} %-5p [%c{1.}] [%-20.-20t] %s%E%n")
> {code}
> (in the example above thread name should be truncated to 20 characters, left-justified)
> 2. Write a log from a thread which has a name containg 21 characters or more. During server startup logs are written by "MSC service thread 1-7" thread.
> It seems there is an error in {{org.jboss.logmanager.formatters.Formatters()}} class, line 212. There is:
> {code:java}
> builder.delete(oldLen, overflow + 1);
> {code}
> but should be:
> {code:java}
> builder.delete(oldLen, oldLen + overflow);
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 3 months
[JBoss JIRA] (LOGMGR-141) StringIndexOutOfBoundsException throw while formatting log with truncation
by James Perkins (JIRA)
[ https://issues.jboss.org/browse/LOGMGR-141?page=com.atlassian.jira.plugin... ]
James Perkins updated LOGMGR-141:
---------------------------------
Fix Version/s: 1.5.7.Final
2.0.5.Final
> StringIndexOutOfBoundsException throw while formatting log with truncation
> --------------------------------------------------------------------------
>
> Key: LOGMGR-141
> URL: https://issues.jboss.org/browse/LOGMGR-141
> Project: JBoss Log Manager
> Issue Type: Bug
> Reporter: James Perkins
> Assignee: James Perkins
> Fix For: 1.5.7.Final, 2.0.5.Final, 2.1.0.Beta1
>
>
> When value in left-justified field is longer than maximum width following exception is thrown:
> {code}
> java.lang.StringIndexOutOfBoundsException
> at java.lang.AbstractStringBuilder.delete(AbstractStringBuilder.java:733)
> at java.lang.StringBuilder.delete(StringBuilder.java:244)
> at org.jboss.logmanager.formatters.Formatters$JustifyingFormatStep.render(Formatters.java:212)
> at org.jboss.logmanager.formatters.MultistepFormatter.format(MultistepFormatter.java:83)
> at org.jboss.logmanager.ExtFormatter.format(ExtFormatter.java:32)
> at org.jboss.logmanager.handlers.WriterHandler.doPublish(WriterHandler.java:46)
> at org.jboss.logmanager.ExtHandler.publish(ExtHandler.java:76)
> at org.jboss.logmanager.LoggerNode.publish(LoggerNode.java:302)
> at org.jboss.logmanager.LoggerNode.publish(LoggerNode.java:310)
> at org.jboss.logmanager.LoggerNode.publish(LoggerNode.java:310)
> at org.jboss.logmanager.LoggerNode.publish(LoggerNode.java:310)
> at org.jboss.logmanager.Logger.logRaw(Logger.java:719)
> at org.jboss.logmanager.Logger.log(Logger.java:670)
> at org.jboss.logging.JBossLogManagerLogger.doLogf(JBossLogManagerLogger.java:50)
> at org.jboss.logging.Logger.logf(Logger.java:2096)
> {code}
> Steps to Reproduce:
> 1. Configure formatter with left-justified field with maximum width:
> {code}
> /subsystem=logging/periodic-rotating-file-handler=FILE:write-attribute(name=formatter,value="%d{HH:mm:ss,SSS} %-5p [%c{1.}] [%-20.-20t] %s%E%n")
> {code}
> (in the example above thread name should be truncated to 20 characters, left-justified)
> 2. Write a log from a thread which has a name containg 21 characters or more. During server startup logs are written by "MSC service thread 1-7" thread.
> It seems there is an error in {{org.jboss.logmanager.formatters.Formatters()}} class, line 212. There is:
> {code:java}
> builder.delete(oldLen, overflow + 1);
> {code}
> but should be:
> {code:java}
> builder.delete(oldLen, oldLen + overflow);
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 3 months
[JBoss JIRA] (WFCORE-1861) Subsystem parsers should be created lazily when needed
by Tomaz Cerar (JIRA)
[ https://issues.jboss.org/browse/WFCORE-1861?page=com.atlassian.jira.plugi... ]
Tomaz Cerar moved STXM-16 to WFCORE-1861:
-----------------------------------------
Project: WildFly Core (was: StAXMapper)
Key: WFCORE-1861 (was: STXM-16)
Workflow: GIT Pull Request workflow (was: classic default workflow)
> Subsystem parsers should be created lazily when needed
> ------------------------------------------------------
>
> Key: WFCORE-1861
> URL: https://issues.jboss.org/browse/WFCORE-1861
> Project: WildFly Core
> Issue Type: Enhancement
> Reporter: Tomaz Cerar
> Assignee: Tomaz Cerar
>
> Currently when we register parsers for different versions of subsystem schema we always pass over instance of whole parser which is usually statically initialized.
> In practice legacy (non current) parsers are only used rarely and there is no point in having them loaded in memory when not needed.
> Impl should be based on provider pattern and as such also allow us to on demand create new instance of parser when needed, as well as enable us for parsers to be GCed, when they are not in use.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 3 months
[JBoss JIRA] (WFCORE-1861) Subsystem parsers should be created lazily when needed
by Tomaz Cerar (JIRA)
[ https://issues.jboss.org/browse/WFCORE-1861?page=com.atlassian.jira.plugi... ]
Tomaz Cerar updated WFCORE-1861:
--------------------------------
Component/s: Domain Management
> Subsystem parsers should be created lazily when needed
> ------------------------------------------------------
>
> Key: WFCORE-1861
> URL: https://issues.jboss.org/browse/WFCORE-1861
> Project: WildFly Core
> Issue Type: Enhancement
> Components: Domain Management
> Reporter: Tomaz Cerar
> Assignee: Tomaz Cerar
>
> Currently when we register parsers for different versions of subsystem schema we always pass over instance of whole parser which is usually statically initialized.
> In practice legacy (non current) parsers are only used rarely and there is no point in having them loaded in memory when not needed.
> Impl should be based on provider pattern and as such also allow us to on demand create new instance of parser when needed, as well as enable us for parsers to be GCed, when they are not in use.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 3 months
[JBoss JIRA] (WFCORE-848) "XNIO001001: No XNIO provider found" by some tests running with security manager
by Josef Cacek (JIRA)
[ https://issues.jboss.org/browse/WFCORE-848?page=com.atlassian.jira.plugin... ]
Josef Cacek commented on WFCORE-848:
------------------------------------
[~pkremens] Thanks for the comment.
[~iweiss] Yes, as comments show in the JIRA Petr had mentioned, we are eager to consume Widfly Security Manager from the Core.
> "XNIO001001: No XNIO provider found" by some tests running with security manager
> --------------------------------------------------------------------------------
>
> Key: WFCORE-848
> URL: https://issues.jboss.org/browse/WFCORE-848
> Project: WildFly Core
> Issue Type: Bug
> Components: Test Suite
> Affects Versions: 2.0.0.Alpha11
> Reporter: Petr Kremensky
> Assignee: Ingo Weiss
>
> Some tests in wildfly-core fails due to "XNIO001001: No XNIO provider found" while run with security manager enabled.
> {noformat}
> mvn test -Dtest=SuspendResumeTestCase -Dsecurity.manager -DtestLogToFile=false
> 10:27:16,814 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-1) MSC000001: Failed to start service jboss.test-undertow-server: org.jboss.msc.service.StartException in service jboss.test-undertow-server: Failed to start service
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1904)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> at java.lang.Thread.run(Thread.java:745)
> Caused by: java.lang.IllegalArgumentException: XNIO001001: No XNIO provider found
> at org.xnio.Xnio.doGetInstance(Xnio.java:238)
> at org.xnio.Xnio.getInstance(Xnio.java:181)
> at io.undertow.Undertow.start(Undertow.java:97)
> at org.wildfly.test.suspendresumeendpoint.TestUndertowService.start(TestUndertowService.java:94)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)
> ... 3 more
> 10:27:16,816 ERROR [org.jboss.as.controller.management-operation] (management-handler-thread - 2) WFLYCTL0013: Operation ("deploy") failed - address: ([("deployment" => "web-suspend.jar")]) - failure description: {"WFLYCTL0080: Failed services" => {"jboss.test-undertow-server" => "org.jboss.msc.service.StartException in service jboss.test-undertow-server: Failed to start service
> Caused by: java.lang.IllegalArgumentException: XNIO001001: No XNIO provider found"}}
> 10:27:16,817 ERROR [org.jboss.as.server] (management-handler-thread - 2) WFLYSRV0021: Deploy of deployment "web-suspend.jar" was rolled back with the following failure message:
> {"WFLYCTL0080: Failed services" => {"jboss.test-undertow-server" => "org.jboss.msc.service.StartException in service jboss.test-undertow-server: Failed to start service
> Caused by: java.lang.IllegalArgumentException: XNIO001001: No XNIO provider found"}}
> {noformat}
> Affected tests found so far:
> * org.wildfly.core.test.standalone.suspend.web.SuspendResumeTestCase
> * org.jboss.as.test.integration.domain.suspendresume.DomainGracefulShutdownTestCase
> * org.jboss.as.test.integration.domain.suspendresume.DomainSuspendResumeTestCase
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 3 months
[JBoss JIRA] (WFLY-1925) Unclear error message about conflict
by Luca Bueti (JIRA)
[ https://issues.jboss.org/browse/WFLY-1925?page=com.atlassian.jira.plugin.... ]
Luca Bueti edited comment on WFLY-1925 at 10/10/16 9:11 AM:
------------------------------------------------------------
After unsuccessfully trying to preserve module conflicts for the last 4 hours, I found an article on [JBoss EAP documentation|https://access.redhat.com/documentation/en-US/JBoss_Enterpr...] that explains that override and preserve commands work only for misc files. I verified that it's true by looking at wfly cli source code. In my humble opinion, the error message
_Use the --override-all, --override=[] or --preserve=[] arguments in order to resolve the conflict._
could be improved to add this useful information (which I couldn't find in wildfly Admin Docs).
was (Author: luck17):
After unsuccessfully trying to preserve module conflicts for the last 4 hours, I found an article on JBoss EAP documentation that explains that override and preserve commands work only for misc files. I verified that it's true by looking at wfly cli source code. In my humble opinion, the error message
_Use the --override-all, --override=[] or --preserve=[] arguments in order to resolve the conflict._
could be improved to add this useful information (which I couldn't find in wildfly Admin Docs).
> Unclear error message about conflict
> ------------------------------------
>
> Key: WFLY-1925
> URL: https://issues.jboss.org/browse/WFLY-1925
> Project: WildFly
> Issue Type: Bug
> Components: Patching
> Reporter: Jan Martiska
> Assignee: Emanuel Muckenhuber
> Priority: Minor
> Fix For: 8.0.0.CR1
>
>
> {noformat}
> [standalone@localhost:9990 /] patch apply /tmp/7e387d2d-a9de-4537-ad29-6f66ada17e53/77cc1914-21ea-4c9e-b023-d981b3cb80e0.zip
> Conflicts detected: jboss-modules.jar
> {noformat}
> That message doesn't say much. It should say something like 'the hash of xxx has changed, you have probably applied manual changes to xxx. Use --override or --preserve arguments to specify how the conflicts should be dealt with.'
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 3 months
[JBoss JIRA] (WFLY-1925) Unclear error message about conflict
by Luca Bueti (JIRA)
[ https://issues.jboss.org/browse/WFLY-1925?page=com.atlassian.jira.plugin.... ]
Luca Bueti edited comment on WFLY-1925 at 10/10/16 9:11 AM:
------------------------------------------------------------
After unsuccessfully trying to preserve module conflicts for the last 4 hours, I found an article on [JBoss EAP documentation|https://access.redhat.com/documentation/en-US/JBoss_Enterpr...] that explains that override and preserve commands work only for misc files. I verified this is true by looking at wfly cli source code. In my humble opinion, the error message
_Use the --override-all, --override=[] or --preserve=[] arguments in order to resolve the conflict._
could be improved to add this useful information (which I couldn't find in wildfly Admin Docs).
was (Author: luck17):
After unsuccessfully trying to preserve module conflicts for the last 4 hours, I found an article on [JBoss EAP documentation|https://access.redhat.com/documentation/en-US/JBoss_Enterpr...] that explains that override and preserve commands work only for misc files. I verified that it's true by looking at wfly cli source code. In my humble opinion, the error message
_Use the --override-all, --override=[] or --preserve=[] arguments in order to resolve the conflict._
could be improved to add this useful information (which I couldn't find in wildfly Admin Docs).
> Unclear error message about conflict
> ------------------------------------
>
> Key: WFLY-1925
> URL: https://issues.jboss.org/browse/WFLY-1925
> Project: WildFly
> Issue Type: Bug
> Components: Patching
> Reporter: Jan Martiska
> Assignee: Emanuel Muckenhuber
> Priority: Minor
> Fix For: 8.0.0.CR1
>
>
> {noformat}
> [standalone@localhost:9990 /] patch apply /tmp/7e387d2d-a9de-4537-ad29-6f66ada17e53/77cc1914-21ea-4c9e-b023-d981b3cb80e0.zip
> Conflicts detected: jboss-modules.jar
> {noformat}
> That message doesn't say much. It should say something like 'the hash of xxx has changed, you have probably applied manual changes to xxx. Use --override or --preserve arguments to specify how the conflicts should be dealt with.'
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 3 months
[JBoss JIRA] (WFLY-1925) Unclear error message about conflict
by Luca Bueti (JIRA)
[ https://issues.jboss.org/browse/WFLY-1925?page=com.atlassian.jira.plugin.... ]
Luca Bueti edited comment on WFLY-1925 at 10/10/16 9:06 AM:
------------------------------------------------------------
After unsuccessfully trying to preserve module conflicts for the last 4 hours, I found an article on JBoss EAP documentation that explains that override and preserve commands work only for misc files. I verified that it's true by looking at wfly cli source code. In my humble opinion, the error message
_Use the --override-all, --override=[] or --preserve=[] arguments in order to resolve the conflict._
could be improved to add this useful information (which I couldn't find in wildfly Admin Docs).
was (Author: luck17):
After unsuccessfully trying to preserve module conflicts for the last 4 hours, I found an article on JBoss EAP documentation that explains that override and preserve commands work only for misc files. In my humble opinion, the error message
Use the --override-all, --override=[] or --preserve=[] arguments in order to resolve the conflict.
could be improved to add this useful information (which I couldn't find in wildfly Admin Docs).
> Unclear error message about conflict
> ------------------------------------
>
> Key: WFLY-1925
> URL: https://issues.jboss.org/browse/WFLY-1925
> Project: WildFly
> Issue Type: Bug
> Components: Patching
> Reporter: Jan Martiska
> Assignee: Emanuel Muckenhuber
> Priority: Minor
> Fix For: 8.0.0.CR1
>
>
> {noformat}
> [standalone@localhost:9990 /] patch apply /tmp/7e387d2d-a9de-4537-ad29-6f66ada17e53/77cc1914-21ea-4c9e-b023-d981b3cb80e0.zip
> Conflicts detected: jboss-modules.jar
> {noformat}
> That message doesn't say much. It should say something like 'the hash of xxx has changed, you have probably applied manual changes to xxx. Use --override or --preserve arguments to specify how the conflicts should be dealt with.'
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 3 months