From: poy <po...@12...> - 2009-08-01 12:09:37
|
i would like the following param be added to the MSG command of ADC: TS | Timestamp of the moment when the message was sent, expressed in seconds since the Unix Epoch (January 1 1970 00:00:00 GMT). it would be optional, and when absent, clients would assume as they currently do that the message was sent at the same time it was received. poy |
From: Fredrik U. <ul...@gm...> - 2009-08-01 16:32:00
|
How often would this feature be used? I.e., would (should) clients add that every X message to ensure that they are not lagging (or every X seconds etc)? While I can admit that it might be interesting to have real timestamps (if not simply for the fact that it'd be similar to other protocols), I fail to see the usefullness for normal clients. (How would the client know when it should send with timestamp and when it shouldn't?) At most, though, it seems this feature would only be really useful in a debugging environment. Also, it might be worthwhile introducing similar functionality in SCH - though using timestamp as a "I don't care about search results after X time", but I suppose that might be another whole discussion. On Sat, Aug 1, 2009 at 2:09 PM, poy <po...@12...> wrote: > i would like the following param be added to the MSG command of ADC: > > TS | Timestamp of the moment when the message was sent, expressed in > seconds > since the Unix Epoch (January 1 1970 00:00:00 GMT). > > it would be optional, and when absent, clients would assume as they > currently do that the message was sent at the same time it was received. > > poy > > > > ------------------------------------------------------------------------------ > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day > trial. Simplify your report design, integration and deployment - and focus > on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > dcplusplus-devel mailing list > dcp...@li... > https://lists.sourceforge.net/lists/listinfo/dcplusplus-devel > -- Fredrik Ullner |
From: poy <po...@12...> - 2009-08-01 17:06:02
|
> How often would this feature be used? I.e., would (should) clients add > that > every X message to ensure that they are not lagging (or every X seconds > etc)? clients supporting the version of ADC that has this MSG field should be able to understand such a MSG and display the timestamp they were given instead of making up their own. the field is optional, so they don't have to add it to every outgoing message; they can choose to if they want to get fancy. also, using this to measure the lag isn't what this was intended for, but if a client wants to use it for that purpose, no problem... > > While I can admit that it might be interesting to have real timestamps (if > not simply for the fact that it'd be similar to other protocols), I fail > to > see the usefullness for normal clients. (How would the client know when it > should send with timestamp and when it shouldn't?) At most, though, it > seems > this feature would only be really useful in a debugging environment. indeed, normal clients won't add this field to any of their messages; they should simply be able to treat incoming messages that have a TS param accordingly. as for the use case, i have a bot that logs messages for me when i am not online, and when that bot forwards messages it has been logging back to me, i receive all messages as though they just got written, although some might be dating from a week ago. therefore, i want my bot to add a TS field to each message specifying when it was sent, so that when DC++ receives it, it displays it with its original timestamp. another similar example would be a hub that offers an "offline PM" functionality: send a message to a regged user, and if that user is not online, the hub logs it and wait for that user to come back to send her your message. in this case too, the lag is not negligible anymore and there needs to be a way for the sender of the logged message (be it a hub or a bot) to tell when the message was originally sent. poy |
From: Fredrik U. <ul...@gm...> - 2009-08-01 19:14:29
|
> > as for the use case, i have a bot that logs messages for me when i am not > online, and when that bot forwards messages it has been logging back to me, > i receive all messages as though they just got written, although some might > be dating from a week ago. therefore, i want my bot to add a TS field to > each message specifying when it was sent, so that when DC++ receives it, it > displays it with its original timestamp. > Could you not modify your bot to actually store the time, too? So it'd report the time it got the message... (Time would probably enlarge the entirety of messages compared to the TS param, but still.) > another similar example would be a hub that offers an "offline PM" > functionality: send a message to a regged user, and if that user is not > online, the hub logs it and wait for that user to come back to send her your > message. in this case too, the lag is not negligible anymore and there needs > to be a way for the sender of the logged message (be it a hub or a bot) to > tell when the message was originally sent. Actually, I've been using a hub that have that exact functionality. "You have the following messages: 1) PM from <nick>: <msg>, <date/time of message>" -- i.e., it displays the date/time the message was sent (well, obviously received by the hub). Granted, having *exact* time in terms of message sent by client might be useful, but I think the (potential) lag is negligible. (Indeed, the hub is NMDC even...) -- Fredrik Ullner |
From: poy <po...@12...> - 2009-08-01 21:34:27
|
> Could you not modify your bot to actually store the time, too? So it'd > report the time it got the message... (Time would probably enlarge the > entirety of messages compared to the TS param, but still.) sure, my bot has to store a timestamp along with each message, that's not a problem. the question is: when i connect, and my bot sends me the messages it has been logging, how does it tell DC++ when each message was sent? > Actually, I've been using a hub that have that exact functionality. "You > have the following messages: 1) PM from <nick>: <msg>, <date/time of > message>" -- i.e., it displays the date/time the message was sent (well, > obviously received by the hub). Granted, having *exact* time in terms of > message sent by client might be useful, but I think the (potential) lag is > negligible. (Indeed, the hub is NMDC even...) including the timestamp of the message in the message string is indeed the only possibility i have for the moment and it is an ugly hack, which might be acceptable on NMDC, but please allow for something more correct in ADC. that would be like saying "yeah, just send your message with /me in front of it, and the other client will assume it's 3rd-person" when in fact having a separate param to specify this is far more correct. moreover, sending the timestamp separately lets the client format it the way it wants to. poy |
From: Fredrik U. <ul...@gm...> - 2009-08-01 22:35:19
|
> > including the timestamp of the message in the message string is indeed the > only possibility i have for the moment and it is an ugly hack, which might > be acceptable on NMDC, but please allow for something more correct in ADC. > that would be like saying "yeah, just send your message with /me in front of > it, and the other client will assume it's 3rd-person" when in fact having a > separate param to specify this is far more correct. > moreover, sending the timestamp separately lets the client format it the > way it wants to. > Bah. You just can't do that. You can't similize that to ME since I'd have to agree with you. :) -- Fredrik Ullner |
From: poy <po...@12...> - 2009-08-04 18:57:19
Attachments:
patch-adc.patch
patch-dcpp.patch
|
attached; a patch that adds the "TS" line to the ADC doc; and one that makes DC++ aware of messages that contain a "TS" param. if anyone wants to test it out, my bouncer on <https://launchpad.net/dcbouncer> adds the param to ADC messages it logs. poy |
From: Fredrik U. <ul...@gm...> - 2009-08-04 20:25:07
|
Actually, I think a better venue is adcportal.com, as I don't know if others read this fora. On Tue, Aug 4, 2009 at 8:56 PM, poy <po...@12...> wrote: > attached; a patch that adds the "TS" line to the ADC doc; and one that > makes DC++ aware of messages that contain a "TS" param. > > if anyone wants to test it out, my bouncer on < > https://launchpad.net/dcbouncer> adds the param to ADC messages it logs. > > poy > > > ------------------------------------------------------------------------------ > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day > trial. Simplify your report design, integration and deployment - and focus > on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > dcplusplus-devel mailing list > dcp...@li... > https://lists.sourceforge.net/lists/listinfo/dcplusplus-devel > > -- Fredrik Ullner |