You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4net-dev@logging.apache.org by "Maik (JIRA)" <ji...@apache.org> on 2008/12/12 10:19:44 UTC

[jira] Created: (LOG4NET-189) XmlConfigurator.Configure(Stream) needs a a Stream with pointer at beginning

XmlConfigurator.Configure(Stream) needs a a Stream with pointer at beginning
----------------------------------------------------------------------------

                 Key: LOG4NET-189
                 URL: https://issues.apache.org/jira/browse/LOG4NET-189
             Project: Log4net
          Issue Type: Improvement
            Reporter: Maik
            Priority: Trivial


Is it possible to set the stream for configuring log4net to the beginning of the stream by default?

In my application I created my own MemoryStream with an XML-Configuration for log4net. Trying to call XmlConfigurator.Configure(myStream), I got an Exeption of the type 

System.Xml.XmlException: Missing Root-Element.

Setting the StreamPointer to the beginning by calling

myStream.Seek(0, SeekOrigin.Begin);

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (LOG4NET-189) XmlConfigurator.Configure(Stream) needs a a Stream with pointer at beginning

Posted by "Ron Grabowski (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LOG4NET-189?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ron Grabowski resolved LOG4NET-189.
-----------------------------------

    Resolution: Won't Fix

I haven't heard any additional discussions why we should change the current behavior so I'm resolving this item. Log4net will continue to process the Stream based on the position that is passed in.

> XmlConfigurator.Configure(Stream) needs a a Stream with pointer at beginning
> ----------------------------------------------------------------------------
>
>                 Key: LOG4NET-189
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-189
>             Project: Log4net
>          Issue Type: Improvement
>            Reporter: Maik
>            Priority: Trivial
>
> Is it possible to set the stream for configuring log4net to the beginning of the stream by default?
> In my application I created my own MemoryStream with an XML-Configuration for log4net. Trying to call XmlConfigurator.Configure(myStream), I got an Exeption of the type 
> System.Xml.XmlException: Missing Root-Element.
> Setting the StreamPointer to the beginning by calling
> myStream.Seek(0, SeekOrigin.Begin);

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (LOG4NET-189) XmlConfigurator.Configure(Stream) needs a a Stream with pointer at beginning

Posted by "Ron Grabowski (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LOG4NET-189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12656714#action_12656714 ] 

Ron Grabowski commented on LOG4NET-189:
---------------------------------------

I think the current behavior is good enough...log4net starts reading the stream based on the stream's current position.

> XmlConfigurator.Configure(Stream) needs a a Stream with pointer at beginning
> ----------------------------------------------------------------------------
>
>                 Key: LOG4NET-189
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-189
>             Project: Log4net
>          Issue Type: Improvement
>            Reporter: Maik
>            Priority: Trivial
>
> Is it possible to set the stream for configuring log4net to the beginning of the stream by default?
> In my application I created my own MemoryStream with an XML-Configuration for log4net. Trying to call XmlConfigurator.Configure(myStream), I got an Exeption of the type 
> System.Xml.XmlException: Missing Root-Element.
> Setting the StreamPointer to the beginning by calling
> myStream.Seek(0, SeekOrigin.Begin);

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (LOG4NET-189) XmlConfigurator.Configure(Stream) needs a a Stream with pointer at beginning

Posted by "Maik (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LOG4NET-189?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Maik closed LOG4NET-189.
------------------------


> XmlConfigurator.Configure(Stream) needs a a Stream with pointer at beginning
> ----------------------------------------------------------------------------
>
>                 Key: LOG4NET-189
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-189
>             Project: Log4net
>          Issue Type: Improvement
>            Reporter: Maik
>            Priority: Trivial
>
> Is it possible to set the stream for configuring log4net to the beginning of the stream by default?
> In my application I created my own MemoryStream with an XML-Configuration for log4net. Trying to call XmlConfigurator.Configure(myStream), I got an Exeption of the type 
> System.Xml.XmlException: Missing Root-Element.
> Setting the StreamPointer to the beginning by calling
> myStream.Seek(0, SeekOrigin.Begin);

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.