logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gary Gregory (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (LOG4J2-1050) Write log files relative to log4j2.xml
Date Fri, 12 Jun 2015 15:58:00 GMT

    [ https://issues.apache.org/jira/browse/LOG4J2-1050?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14583601#comment-14583601
] 

Gary Gregory commented on LOG4J2-1050:
--------------------------------------

When I run the tests I get:

{noformat}
Log4jLookupWithSpacesTest
org.apache.logging.log4j.core.lookup.Log4jLookupWithSpacesTest
lookupConfigParentLocation_withSpaces(org.apache.logging.log4j.core.lookup.Log4jLookupWithSpacesTest)
java.lang.AssertionError: expected:</a a/b b/c c/d d/e e> but was:<null>

	at org.junit.Assert.fail(Assert.java:88)

	at org.junit.Assert.failNotEquals(Assert.java:743)

	at org.junit.Assert.assertEquals(Assert.java:118)

	at org.junit.Assert.assertEquals(Assert.java:144)

	at org.apache.logging.log4j.core.lookup.Log4jLookupWithSpacesTest.lookupConfigParentLocation_withSpaces(Log4jLookupWithSpacesTest.java:69)

	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

	at java.lang.reflect.Method.invoke(Method.java:606)

	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)

	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)

	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)

	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)

	at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)

	at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)

	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)

	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)

	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)

	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)

	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)

	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)

	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)

	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)

	at org.junit.runners.ParentRunner.run(ParentRunner.java:309)

	at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)

	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)

	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)

	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675)

	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)

	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)



lookupConfigLocation_withSpaces(org.apache.logging.log4j.core.lookup.Log4jLookupWithSpacesTest)
org.junit.ComparisonFailure: expected:</[]a a/b b/c c/d d/e e/...> but was:</[C:/]a
a/b b/c c/d d/e e/...>

	at org.junit.Assert.assertEquals(Assert.java:115)

	at org.junit.Assert.assertEquals(Assert.java:144)

	at org.apache.logging.log4j.core.lookup.Log4jLookupWithSpacesTest.lookupConfigLocation_withSpaces(Log4jLookupWithSpacesTest.java:62)

	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

	at java.lang.reflect.Method.invoke(Method.java:606)

	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)

	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)

	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)

	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)

	at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)

	at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)

	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)

	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)

	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)

	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)

	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)

	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)

	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)

	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)

	at org.junit.runners.ParentRunner.run(ParentRunner.java:309)

	at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)

	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)

	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)

	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675)

	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)

	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)
{noformat}





> Write log files relative to log4j2.xml
> --------------------------------------
>
>                 Key: LOG4J2-1050
>                 URL: https://issues.apache.org/jira/browse/LOG4J2-1050
>             Project: Log4j 2
>          Issue Type: New Feature
>          Components: Configurators
>    Affects Versions: 2.3
>         Environment: All
>            Reporter: adam Retter
>            Priority: Minor
>             Fix For: 2.4
>
>         Attachments: 0001-feature-Added-support-for-properties-interpolation-o.patch
>
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> I attach a patch related to this mailing list post - http://mail-archives.apache.org/mod_mbox/logging-log4j-user/201506.mbox/%3CCAPK0icj%3DY3T9ptBGyGdgbHyMow_YWcfwC6UdLHS-QbgnBk8wkA%40mail.gmail.com%3E
> The patch makes the properties `log4j:configLocation` and `log4j:configParentLocation`
available for substitution in the log4j configuration file.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org


Mime
View raw message