Summary: | change jabber priority when away | ||
---|---|---|---|
Product: | [Applications] kopete | Reporter: | Andy Parkins <andyparkins> |
Component: | Jabber Plugin | Assignee: | Kopete Developers <kopete-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | wishlist | CC: | denilsonsa, scherer.michael |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Debian testing | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: |
Description
Andy Parkins
2005-01-27 14:10:41 UTC
jabberresourcepool.cpp shows that in the case of identical priorities the resource with the latest status().timestamp() will be used - this would address my above requirement perfectly. However, I've just run tests where I had both running on one screen (one over an SSH tunnelled X connection) and all messages where going to the one that logged in most recently - regardless of away settings of either of them. Using the resource list available in the tooltip shows that the timestamp is being updated correctly when i change online status. Additionally, the resource selection is set to automatic in the sending client. I'm very confused then as to why messages aren't going to the correct client. Is this only affecting me? Kopete locks you to a certain resource of a contact as soon as you received a message from it. Did you make sure that you were sending a message to the contact without having selected a resource? You can see the packet output on the console if you have debugging enabled. Apart from that, the server is responsible for routing the message. Kopete can try to change the resource priority when going away of course. Does priority have preference over status or the other way around? I'm not sure right now. Till: I'm not sure that's true. For a number of reasons; the first of which is that I was doing these test using an client that had just signed in; ergo it had received no messages from either of the resources. Secondly (and I may be wrong, I've only looked briefly at the source) jabberbasecontact.cpp uses bestResource() when evaluating the status of the remote and bestResource() when finding the fullAdress() for a contact. Thirdly, my (again brief) reading of the rfc suggests that the client is responsible for routing to a particular resource. From section 4.1 of rfc3921: "value of the 'to' address SHOULD be of the form <user@domain/resource> rather than of the form <user@domain> unless the sender has knowledge (via presence) that the intended recipient's resource is no longer available". In any case, it's not prohibited that the client does routing. Conversely, I can't see anything in the code that would explain why it's not behaving how I think it should - so I am most likely insane, stupid or both :-) Some jabber clients ( gossip, gajim ) do not let the user directly specify the priority but use it to make sure people do not get message when they are away on on client and not on another one. I have three coworkers that use kopete, and they both let the client run at home when they are at work. So regulary, messages got routed to the wrong client, because they have placed a priority of 5 on their home ressource and 4 on their work ressource. If kopete was able to change the priority based on the presence ( ie if the client is away, set a priority of 10, if he is avaliable, place a priority of 20 ), this would not ahappens. I think this is the sensible thing to do, and this what most, if not all, people expect. I agree with Michael Scherer. Pidgin currently sets priority 1 when online and 0 when away. Those are stupid priorities, too low to be useful. However, changing priorities based on online status is a great feature, specially when the user is able to configure the priorities (and, of course, having sensible default priorities, like maybe 10 for online and 1 for away). (slightly off-topic: I'm not sure if zero is a valid priority, I remember reading somewhere else that it must be a positive number, greater than zero, but not zero) *** This bug has been confirmed by popular vote. *** SVN commit 1145738 by rkcosta: Automatically adjust Jabber priority based on the presence state. From the original patch description: "This patch adds the ability to adjust the priority of a jabber resource when going to an "away" state. This can be used to "redirect" messages to a different resource (e.g an IM client on a mobile device) base on the presence state of kopete." See http://reviewboard.kde.org/r/4274/ Patch from Ralf Haferkamp, thanks! FEATURE: 97998 GUI: CCMAIL: rhafer@suse.de M +7 -1 jabberaccount.cpp M +56 -0 ui/dlgjabbereditaccountwidget.ui M +28 -0 ui/jabbereditaccountwidget.cpp M +1 -0 ui/jabbereditaccountwidget.h WebSVN link: http://websvn.kde.org/?view=rev&revision=1145738 |