TopFieldDocCollector and v3.0.0

classic Classic list List threaded Threaded
6 messages Options
adb
Reply | Threaded
Open this post in threaded view
|

TopFieldDocCollector and v3.0.0

adb
I'm on 2.3.2 and looking to move to 2.9.1 or 3.0.0

In 2.9.1 TopFieldDocCollector is

"Deprecated. Please use TopFieldCollector instead."

in 3.0.0 TopFieldCollector says

NOTE: This API is experimental and might change in incompatible ways in the next
release

What is the suggested path for migrating TopFieldDocCollector usage?

Antony



---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: TopFieldDocCollector and v3.0.0

Uwe Schindler
That's a java docs issue and already fixed for the 3.0 branch. You have to
use the no longer experimental API.

Any by the way: Experimental means not "bad" or "functionally unstable", it
just means that the API might change on later releases.

-----
Uwe Schindler
H.-H.-Meier-Allee 63, D-28213 Bremen
http://www.thetaphi.de
eMail: [hidden email]

> -----Original Message-----
> From: Antony Bowesman [mailto:[hidden email]]
> Sent: Tuesday, December 08, 2009 7:44 AM
> To: Lucene User
> Subject: TopFieldDocCollector and v3.0.0
>
> I'm on 2.3.2 and looking to move to 2.9.1 or 3.0.0
>
> In 2.9.1 TopFieldDocCollector is
>
> "Deprecated. Please use TopFieldCollector instead."
>
> in 3.0.0 TopFieldCollector says
>
> NOTE: This API is experimental and might change in incompatible ways in
> the next
> release
>
> What is the suggested path for migrating TopFieldDocCollector usage?
>
> Antony
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]



---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: TopFieldDocCollector and v3.0.0

Erick Erickson
In reply to this post by adb
You might want to move to 2.9.1 first, find and fix all the deprecations
and *then* move to 3.x.

It seems like more work, but it's actually not. Especially if you have
reasonable
unit tests. Since lots of effort has been put into maintaining backwards
compatibility in the 2.X versions, 2.9.1 should "just work" for you. Then
you can remove the deprecated methods a little bit at a time rather than
all at once. It's always tempting to do things in "one big edit", but then
you
never know which one of the many changes actually broke something. Unless
you can code perfectly the first time, in which case I'd recommend we hire
you and pay you a gazillion dollars <G>....

Once all the deprecations are removed from 2.9.1, you shouldn't have to do
anything to move to 3.x. So you get the best of both worlds....

Best
Erick


On Tue, Dec 8, 2009 at 1:44 AM, Antony Bowesman <[hidden email]> wrote:

> I'm on 2.3.2 and looking to move to 2.9.1 or 3.0.0
>
> In 2.9.1 TopFieldDocCollector is
>
> "Deprecated. Please use TopFieldCollector instead."
>
> in 3.0.0 TopFieldCollector says
>
> NOTE: This API is experimental and might change in incompatible ways in the
> next release
>
> What is the suggested path for migrating TopFieldDocCollector usage?
>
> Antony
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
Reply | Threaded
Open this post in threaded view
|

RE: TopFieldDocCollector and v3.0.0

Uwe Schindler
The only difference to 3.0 is, that after moving to 3.0, you can remove lots
of unsafe casts and use generics (which does not work in 2.9, as it is Java
1.4 only). So this is the good thing when directly moving to 3.0.

But as the release notes for 3.0 denote, for new users that want to start
new projects, 3.0 is the best start because they get a clean generified and
type safe API (whichout old crap). For users porting from older versions,
the move through 2.9.1 is recommended. After the move to 3.0, you can (but
you must not) further update your code to use generics, which is not really
needed but will remove all compiler warnings.

-----
Uwe Schindler
H.-H.-Meier-Allee 63, D-28213 Bremen
http://www.thetaphi.de
eMail: [hidden email]


> -----Original Message-----
> From: Erick Erickson [mailto:[hidden email]]
> Sent: Tuesday, December 08, 2009 2:24 PM
> To: [hidden email]
> Subject: Re: TopFieldDocCollector and v3.0.0
>
> You might want to move to 2.9.1 first, find and fix all the deprecations
> and *then* move to 3.x.
>
> It seems like more work, but it's actually not. Especially if you have
> reasonable
> unit tests. Since lots of effort has been put into maintaining backwards
> compatibility in the 2.X versions, 2.9.1 should "just work" for you. Then
> you can remove the deprecated methods a little bit at a time rather than
> all at once. It's always tempting to do things in "one big edit", but then
> you
> never know which one of the many changes actually broke something. Unless
> you can code perfectly the first time, in which case I'd recommend we hire
> you and pay you a gazillion dollars <G>....
>
> Once all the deprecations are removed from 2.9.1, you shouldn't have to do
> anything to move to 3.x. So you get the best of both worlds....
>
> Best
> Erick
>
>
> On Tue, Dec 8, 2009 at 1:44 AM, Antony Bowesman <[hidden email]> wrote:
>
> > I'm on 2.3.2 and looking to move to 2.9.1 or 3.0.0
> >
> > In 2.9.1 TopFieldDocCollector is
> >
> > "Deprecated. Please use TopFieldCollector instead."
> >
> > in 3.0.0 TopFieldCollector says
> >
> > NOTE: This API is experimental and might change in incompatible ways in
> the
> > next release
> >
> > What is the suggested path for migrating TopFieldDocCollector usage?
> >
> > Antony
> >
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> > For additional commands, e-mail: [hidden email]
> >
> >


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: TopFieldDocCollector and v3.0.0

steve_rowe
Hi Uwe,

On 12/08/2009 at 9:40 AM, Uwe Schindler wrote:
> After the move to 3.0, you can (but you must not) further update
> your code to use generics, which is not really needed but will
> remove all compiler warnings.

This sounds like you're telling people that although they are able to update their code to use generics, it is forbidden.

I'm sure, though, that you mean that they are not required to do so: something like "but you need not" rather than "but you must not".

Steve

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: TopFieldDocCollector and v3.0.0

Uwe Schindler
Sorry wrong word, Germans often have the problem with English "must". It has
to be to be "but you must not".

Uwe

-----
Uwe Schindler
H.-H.-Meier-Allee 63, D-28213 Bremen
http://www.thetaphi.de
eMail: [hidden email]


> -----Original Message-----
> From: Steven A Rowe [mailto:[hidden email]]
> Sent: Tuesday, December 08, 2009 8:42 PM
> To: [hidden email]
> Subject: RE: TopFieldDocCollector and v3.0.0
>
> Hi Uwe,
>
> On 12/08/2009 at 9:40 AM, Uwe Schindler wrote:
> > After the move to 3.0, you can (but you must not) further update
> > your code to use generics, which is not really needed but will
> > remove all compiler warnings.
>
> This sounds like you're telling people that although they are able to
> update their code to use generics, it is forbidden.
>
> I'm sure, though, that you mean that they are not required to do so:
> something like "but you need not" rather than "but you must not".
>
> Steve
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]



---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]