[jira] [Commented] (LOG4J2-1864) Support capped collection for MongoDB Log-Provider

2017-04-11 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on LOG4J2-1864:


Github user jvz commented on the issue:

https://github.com/apache/logging-log4j2/pull/62
  
It looks correct based on a quick look, so I'm not sure what exactly is 
incorrect. I would like to note that the builders generally use the parsed type 
rather than a string, though I can help clean that up afterward.


> Support capped collection for MongoDB Log-Provider
> --
>
> Key: LOG4J2-1864
> URL: https://issues.apache.org/jira/browse/LOG4J2-1864
> Project: Log4j 2
>  Issue Type: New Feature
>  Components: Appenders
>Reporter: Matt
>
> MongoDB supports sth. called capped collections. If the 
> nosql-mongodb-appender supports this feature, the mongodb-collection could 
> never "overflow" and stick to a defined maximum size.
> see [pull request 62|https://github.com/apache/logging-log4j2/pull/62] for 
> more details.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Commented] (LOG4J2-1864) Support capped collection for MongoDB Log-Provider

2017-04-11 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on LOG4J2-1864:


Github user codescale commented on the issue:

https://github.com/apache/logging-log4j2/pull/62
  
I updated the `MongoDbProvider` how I understood you want it. But it's not 
working. Maybe you know why @jvz ?


> Support capped collection for MongoDB Log-Provider
> --
>
> Key: LOG4J2-1864
> URL: https://issues.apache.org/jira/browse/LOG4J2-1864
> Project: Log4j 2
>  Issue Type: New Feature
>  Components: Appenders
>Reporter: Matt
>
> MongoDB supports sth. called capped collections. If the 
> nosql-mongodb-appender supports this feature, the mongodb-collection could 
> never "overflow" and stick to a defined maximum size.
> see [pull request 62|https://github.com/apache/logging-log4j2/pull/62] for 
> more details.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Commented] (LOG4J2-1864) Support capped collection for MongoDB Log-Provider

2017-04-10 Thread Gary Gregory (JIRA)

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

Gary Gregory commented on LOG4J2-1864:
--

The old factory method does not come into play if you remove its annotation, 
which is what I have done in the past when adding a builder.

> Support capped collection for MongoDB Log-Provider
> --
>
> Key: LOG4J2-1864
> URL: https://issues.apache.org/jira/browse/LOG4J2-1864
> Project: Log4j 2
>  Issue Type: New Feature
>  Components: Appenders
>Reporter: Matt
>
> MongoDB supports sth. called capped collections. If the 
> nosql-mongodb-appender supports this feature, the mongodb-collection could 
> never "overflow" and stick to a defined maximum size.
> see [pull request 62|https://github.com/apache/logging-log4j2/pull/62] for 
> more details.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Commented] (LOG4J2-1864) Support capped collection for MongoDB Log-Provider

2017-04-10 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on LOG4J2-1864:


Github user jvz commented on a diff in the pull request:

https://github.com/apache/logging-log4j2/pull/62#discussion_r110666194
  
--- Diff: 
log4j-nosql/src/main/java/org/apache/logging/log4j/nosql/appender/mongodb/MongoDbProvider.java
 ---
@@ -97,6 +103,8 @@ public String toString() {
 @PluginFactory
 public static MongoDbProvider createNoSqlProvider(
 @PluginAttribute("collectionName") final String collectionName,
+@PluginAttribute(value = "capped", defaultBoolean = false) 
final Boolean isCapped,
--- End diff --

What we've been doing with old factory methods is removing the annotations 
from them and marking them deprecated. That way it doesn't break custom 
configurations, but only the new builder is used for normal configuration 
(although builders are used before factory methods regardless).


> Support capped collection for MongoDB Log-Provider
> --
>
> Key: LOG4J2-1864
> URL: https://issues.apache.org/jira/browse/LOG4J2-1864
> Project: Log4j 2
>  Issue Type: New Feature
>  Components: Appenders
>Reporter: Matt
>
> MongoDB supports sth. called capped collections. If the 
> nosql-mongodb-appender supports this feature, the mongodb-collection could 
> never "overflow" and stick to a defined maximum size.
> see [pull request 62|https://github.com/apache/logging-log4j2/pull/62] for 
> more details.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Commented] (LOG4J2-1864) Support capped collection for MongoDB Log-Provider

2017-04-10 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on LOG4J2-1864:


Github user codescale commented on a diff in the pull request:

https://github.com/apache/logging-log4j2/pull/62#discussion_r110581005
  
--- Diff: 
log4j-nosql/src/main/java/org/apache/logging/log4j/nosql/appender/mongodb/MongoDbProvider.java
 ---
@@ -97,6 +103,8 @@ public String toString() {
 @PluginFactory
 public static MongoDbProvider createNoSqlProvider(
 @PluginAttribute("collectionName") final String collectionName,
+@PluginAttribute(value = "capped", defaultBoolean = false) 
final Boolean isCapped,
--- End diff --

I took a look at the CassandraAppender. It's not a big deal to adjust the 
MongoDbProvider to match this style. But the API is also broken. Or do you 
intend to keep the old public methods? Shouldn't this even be another issues 
and pull-request?


> Support capped collection for MongoDB Log-Provider
> --
>
> Key: LOG4J2-1864
> URL: https://issues.apache.org/jira/browse/LOG4J2-1864
> Project: Log4j 2
>  Issue Type: New Feature
>  Components: Appenders
>Reporter: Matt
>
> MongoDB supports sth. called capped collections. If the 
> nosql-mongodb-appender supports this feature, the mongodb-collection could 
> never "overflow" and stick to a defined maximum size.
> see [pull request 62|https://github.com/apache/logging-log4j2/pull/62] for 
> more details.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Commented] (LOG4J2-1864) Support capped collection for MongoDB Log-Provider

2017-04-03 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on LOG4J2-1864:


Github user jvz commented on a diff in the pull request:

https://github.com/apache/logging-log4j2/pull/62#discussion_r109425995
  
--- Diff: 
log4j-nosql/src/main/java/org/apache/logging/log4j/nosql/appender/mongodb/MongoDbProvider.java
 ---
@@ -97,6 +103,8 @@ public String toString() {
 @PluginFactory
 public static MongoDbProvider createNoSqlProvider(
 @PluginAttribute("collectionName") final String collectionName,
+@PluginAttribute(value = "capped", defaultBoolean = false) 
final Boolean isCapped,
--- End diff --

Take a look at CassandraAppender for how to write a plugin builder class. 
Any manual type conversion in the factory method can be generally updated to 
use the proper types as conversions for most common types is supported (and new 
types can always be added as appropriate; see InetAddress et al. added for 
CassandraAppender).


> Support capped collection for MongoDB Log-Provider
> --
>
> Key: LOG4J2-1864
> URL: https://issues.apache.org/jira/browse/LOG4J2-1864
> Project: Log4j 2
>  Issue Type: New Feature
>  Components: Appenders
>Reporter: Matt
>
> MongoDB supports sth. called capped collections. If the 
> nosql-mongodb-appender supports this feature, the mongodb-collection could 
> never "overflow" and stick to a defined maximum size.
> see [pull request 62|https://github.com/apache/logging-log4j2/pull/62] for 
> more details.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Commented] (LOG4J2-1864) Support capped collection for MongoDB Log-Provider

2017-04-03 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on LOG4J2-1864:


Github user codescale commented on a diff in the pull request:

https://github.com/apache/logging-log4j2/pull/62#discussion_r109365941
  
--- Diff: 
log4j-nosql/src/main/java/org/apache/logging/log4j/nosql/appender/mongodb/MongoDbProvider.java
 ---
@@ -97,6 +103,8 @@ public String toString() {
 @PluginFactory
 public static MongoDbProvider createNoSqlProvider(
 @PluginAttribute("collectionName") final String collectionName,
+@PluginAttribute(value = "capped", defaultBoolean = false) 
final Boolean isCapped,
--- End diff --

Hi @jvz, I changed the `Boolean` member to be a primitive type. But I don't 
know what kind of Builder you mean for the attributes? Does this builder exist 
for the MongoDbProvider? Cheers Matt


> Support capped collection for MongoDB Log-Provider
> --
>
> Key: LOG4J2-1864
> URL: https://issues.apache.org/jira/browse/LOG4J2-1864
> Project: Log4j 2
>  Issue Type: New Feature
>  Components: Appenders
>Reporter: Matt
>
> MongoDB supports sth. called capped collections. If the 
> nosql-mongodb-appender supports this feature, the mongodb-collection could 
> never "overflow" and stick to a defined maximum size.
> see [pull request 62|https://github.com/apache/logging-log4j2/pull/62] for 
> more details.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Commented] (LOG4J2-1864) Support capped collection for MongoDB Log-Provider

2017-04-02 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on LOG4J2-1864:


Github user codescale commented on the issue:

https://github.com/apache/logging-log4j2/pull/62
  
Hi @jvz, Thanks that you're interested in this feature.
I added a `feature request` to 
[jira](https://issues.apache.org/jira/browse/LOG4J2-1864). And I will take a 
look at your remarks as soon as possible. Cheers


> Support capped collection for MongoDB Log-Provider
> --
>
> Key: LOG4J2-1864
> URL: https://issues.apache.org/jira/browse/LOG4J2-1864
> Project: Log4j 2
>  Issue Type: New Feature
>  Components: Appenders
>Reporter: Matt
>
> MongoDB supports sth. called capped collections. If the 
> nosql-mongodb-appender supports this feature, the mongodb-collection could 
> never "overflow" and stick to a defined maximum size.
> see [pull request 62|https://github.com/apache/logging-log4j2/pull/62] for 
> more details.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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