Hi All,
The interface org.apache.logging.log4j.core.appender.nosql.NoSqlObject<W>
requires arrays in two methods:
set(String, NoSqlObject<BasicDBObject>[])
set(String, Object[])
For some providers like the new MongoDB driver 3.x provider I am working on
this causes double work. First the log4j NoSQL guts converts a list into an
array
in
org.apache.logging.log4j.core.appender.nosql.NoSqlDatabaseManager.setFields(LogEvent,
NoSqlObject<W>):
entity.set("contextStack", contextStack.asList().toArray());
Then, the new NoSqlObject impl I have converts that array back into a list
to pass to Mongo.
If I wanted to add List versions of the two array APIs in NoSqlObject,
should I:
- Just add-em and adjust all providers.
- Create a NoSqlObject2 sub-interface
Thoughts?
Gary