+1
New component makes sense.
Regards
JB
On 12/06/2016 07:53 AM, Andrea Cosentino wrote:
Probably creating a new component is the best solution
--
Andrea Cosentino
----------------------------------
Apache Camel PMC Member
Apache Karaf Committer
Apache Servicemix Committer
Email: ancosen1...@yahoo.com
Twitter: @oscerd2
Github: oscerd
On Monday, December 5, 2016 6:08 AM, Pontus Ullgren <ullg...@gmail.com> wrote:
Hello,
Thanks for doing this work.
One possibility would be to do both. That is introduce new
MongoDbOutputType enumeration values such as "List", "Document" and
"Iterator"
and keep the old possible values (marked as deprecated) as aliases for
these new once to preserve backwards compatibility. But I guess that might
make the code a bit messier.
However is this the only place where you are in a risk of breaking
backwards compatible ?
Another option would be to not upgrade the camel-mongodb component but
instead create a new camel-mongodb3 component.
The benefit of this would be that you could break backwards compatible as
much as you like.
Best regards
Pontus Ullgren
On Sun, 4 Dec 2016 at 11:26 sekaijin <jean-yves.terr...@aphp.fr> wrote:
Hi,
The mongodb driver has changed in its foundation.
It is recommended not to use many classes of the verion 2 still present in
the driver.
This is the case with DBObject, which is the basis for the configuration of
the camel component.
I'm working on the evolution of this component to use the new classes of
version 3, like "Document".
In the camel component configuration an option is outputType which is
implemented as a MongoDbOutputType enumeration
The values are DBObjectList, DBObject, DBCursor which matches in the new
API to List<Document>, Document, MongoIterable
I do not know what to do. This confirmation is purely camel
I can keep the enumeration values and use the new classes
Or define three new values (DocumentList, Document, MongoIterable) and
using the new classes.
In the first case the values of the option does not have a name to refer
to the mongo API but remains compatible with the previous versions of
camel-mongodb.
In the second the values correspond to the mongo API but are no longer
compatible with the previous versions.
A+JYT
--
View this message in context:
http://camel.465427.n5.nabble.com/Mongo-Java-driver-3-and-mongodb-component-tp5790969.html
Sent from the Camel Development mailing list archive at Nabble.com.
--
Jean-Baptiste Onofré
jbono...@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com