Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-dev] Possible typo in MongoSessionManager

Hi Jan,

Thanks for update. Yes now this place looks right.
Do you know if test-sessions-common project contains some test for this thing?

Thanks, Denis

На 19 февраля 2014 г. в 8:07:45, Jan Bartel (janb@xxxxxxxxxxx) написал:

Hi Denis,

Your email prompted me to look back at the issue where that region of
code was touched last:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=373952

It seems to me that the original bug raiser's concerns weren't
addressed, and are in the same region of code as you point out. So I
reopened the original issue, and took another stab at fixing it.

I've attached the diff of the change I made here - could you take a
look at it and tell me if you think it's good? Note that the biggest
change is that unbind will not be called automatically for all
attributes if a session needs to be refreshed; if an attribute is
present in both the original session, and the update from disk, then
the value of the existing one is replaced with the one from the update
but bind will *NOT* be called - I think this is the crux of the
original bug.

thanks
Jan

On 15 February 2014 04:17, Denis Bardadym <bardadymchik@xxxxxxxxx> wrote:
> Hello.
>
> I am sorry if i wrote to wrong mailing list. I am porting nosql sessions to
> redis, and while looking sources for mongo, i found:
>
> On line 375
> (http://git.eclipse.org/c/jetty/org.eclipse.jetty.project.git/tree/jetty-nosql/src/main/java/org/eclipse/jetty/nosql/mongodb/MongoSessionManager.java#n375)
> it traverse by attribute keys that we load from mongo,
>
> for (String name : attrs.keySet())
>
>
> then on line 384
> (http://git.eclipse.org/c/jetty/org.eclipse.jetty.project.git/tree/jetty-nosql/src/main/java/org/eclipse/jetty/nosql/mongodb/MongoSessionManager.java#n384)
>
> if (attrs.keySet().contains(name))
>
> which inside this cycle always true. It looks like there is a typo, and
> really should be session.getNames(). I am understand this right?
>
> Thanks, Denis Bardadym
>
>
> _______________________________________________
> jetty-dev mailing list
> jetty-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/jetty-dev
>



--
Jan Bartel <janb@xxxxxxxxxxx>
www.webtide.com
'Expert Jetty/CometD developer,production,operations advice'

_______________________________________________
jetty-dev mailing list
jetty-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jetty-dev

Back to the top