You can subscribe to this list here.
2005 |
Jan
|
Feb
(53) |
Mar
(62) |
Apr
(88) |
May
(55) |
Jun
(204) |
Jul
(52) |
Aug
|
Sep
(1) |
Oct
(94) |
Nov
(15) |
Dec
(68) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(130) |
Feb
(105) |
Mar
(34) |
Apr
(61) |
May
(41) |
Jun
(92) |
Jul
(176) |
Aug
(102) |
Sep
(247) |
Oct
(69) |
Nov
(32) |
Dec
(140) |
2007 |
Jan
(58) |
Feb
(51) |
Mar
(11) |
Apr
(20) |
May
(34) |
Jun
(37) |
Jul
(18) |
Aug
(60) |
Sep
(41) |
Oct
(105) |
Nov
(19) |
Dec
(14) |
2008 |
Jan
(3) |
Feb
|
Mar
(7) |
Apr
(5) |
May
(123) |
Jun
(5) |
Jul
(1) |
Aug
(29) |
Sep
(15) |
Oct
(21) |
Nov
(51) |
Dec
(3) |
2009 |
Jan
|
Feb
(36) |
Mar
(29) |
Apr
|
May
|
Jun
(7) |
Jul
(4) |
Aug
|
Sep
(4) |
Oct
|
Nov
(13) |
Dec
|
2010 |
Jan
|
Feb
|
Mar
(9) |
Apr
(11) |
May
(16) |
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
2011 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2012 |
Jan
(7) |
Feb
(3) |
Mar
|
Apr
|
May
|
Jun
(3) |
Jul
|
Aug
|
Sep
|
Oct
(92) |
Nov
(28) |
Dec
(16) |
2013 |
Jan
(9) |
Feb
(2) |
Mar
|
Apr
(4) |
May
(4) |
Jun
(6) |
Jul
(14) |
Aug
(12) |
Sep
(4) |
Oct
(13) |
Nov
(1) |
Dec
(6) |
2014 |
Jan
(23) |
Feb
(19) |
Mar
(10) |
Apr
(14) |
May
(11) |
Jun
(6) |
Jul
(11) |
Aug
(15) |
Sep
(41) |
Oct
(95) |
Nov
(23) |
Dec
(11) |
2015 |
Jan
(3) |
Feb
(9) |
Mar
(19) |
Apr
(3) |
May
(1) |
Jun
(3) |
Jul
(11) |
Aug
(1) |
Sep
(15) |
Oct
(5) |
Nov
(2) |
Dec
|
2016 |
Jan
(7) |
Feb
(11) |
Mar
(8) |
Apr
(1) |
May
(3) |
Jun
(17) |
Jul
(12) |
Aug
(3) |
Sep
(5) |
Oct
(19) |
Nov
(12) |
Dec
(6) |
2017 |
Jan
(30) |
Feb
(23) |
Mar
(12) |
Apr
(32) |
May
(27) |
Jun
(7) |
Jul
(13) |
Aug
(16) |
Sep
(6) |
Oct
(11) |
Nov
|
Dec
(12) |
2018 |
Jan
(1) |
Feb
(5) |
Mar
(6) |
Apr
(7) |
May
(23) |
Jun
(3) |
Jul
(2) |
Aug
(1) |
Sep
(6) |
Oct
(6) |
Nov
(10) |
Dec
(3) |
2019 |
Jan
(26) |
Feb
(15) |
Mar
(9) |
Apr
|
May
(8) |
Jun
(14) |
Jul
(10) |
Aug
(10) |
Sep
(4) |
Oct
(2) |
Nov
(20) |
Dec
(10) |
2020 |
Jan
(10) |
Feb
(14) |
Mar
(29) |
Apr
(11) |
May
(25) |
Jun
(21) |
Jul
(23) |
Aug
(12) |
Sep
(19) |
Oct
(6) |
Nov
(8) |
Dec
(12) |
2021 |
Jan
(29) |
Feb
(9) |
Mar
(8) |
Apr
(8) |
May
(2) |
Jun
(2) |
Jul
(9) |
Aug
(9) |
Sep
(3) |
Oct
(4) |
Nov
(12) |
Dec
(13) |
2022 |
Jan
(4) |
Feb
|
Mar
(4) |
Apr
(12) |
May
(15) |
Jun
(7) |
Jul
(10) |
Aug
(2) |
Sep
|
Oct
(1) |
Nov
(8) |
Dec
|
2023 |
Jan
(15) |
Feb
|
Mar
(23) |
Apr
(1) |
May
(2) |
Jun
(10) |
Jul
|
Aug
(22) |
Sep
(19) |
Oct
(2) |
Nov
(20) |
Dec
|
2024 |
Jan
(1) |
Feb
|
Mar
(16) |
Apr
(15) |
May
(6) |
Jun
(4) |
Jul
(1) |
Aug
(1) |
Sep
|
Oct
(13) |
Nov
(18) |
Dec
(6) |
2025 |
Jan
(12) |
Feb
|
Mar
(2) |
Apr
(1) |
May
(11) |
Jun
(5) |
Jul
(4) |
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
From: Vlad S. <vl...@cr...> - 2006-11-15 15:34:53
|
[Switching to thread 5 (Thread -1471153248 (LWP 22074))]#0 0xb7f21410 in ?? () (gdb) bt #0 0xb7f21410 in ?? () #1 0xa84fd3c8 in ?? () #2 0xb7d60ff4 in ?? () from /lib/libc.so.6 #3 0xa84fd3b4 in ?? () #4 0xb7ccf756 in __nanosleep_nocancel () from /lib/libc.so.6 #5 0xb7ccf548 in sleep () from /lib/libc.so.6 #6 0xb5752d5d in DnsPanic (fmt=0xb7f182f0 "SetTimeInternalRep called with shared object") at nsdns.c:237 #7 0xb7e680ae in Tcl_PanicVA () from /usr/lib/libtcl8.4.so #8 0xb7e68147 in Tcl_Panic () from /usr/lib/libtcl8.4.so #9 0xb7f03481 in SetTimeInternalRep (objPtr=0x9be1ea0, timePtr=0xa84fd4c0) at tcltime.c:600 #10 0xb7f03447 in SetTimeFromAny (interp=0xa880a360, objPtr=0x9be1ea0) at tcltime.c:573 #11 0xb7e65f00 in Tcl_ConvertToType () from /usr/lib/libtcl8.4.so #12 0xb7f029bc in Ns_TclGetTimeFromObj (interp=0xa880a360, objPtr=0x9be1ea0, timePtr=0xa84fd57c) at tcltime.c:181 #13 0xb7f00022 in NsTclSockOpenObjCmd (arg=0x97c29e8, interp=0xa880a360, objc=5, objv=0x979f868) at tclsock.c:447 #14 0xb7e14aab in TclEvalObjvInternal () from /usr/lib/libtcl8.4.so #15 0xb7e406dd in TclExecuteByteCode () from /usr/lib/libtcl8.4.so #16 0xb7e44278 in TclCompEvalObj () from /usr/lib/libtcl8.4.so #17 0xb7e6ff65 in TclObjInterpProc () from /usr/lib/libtcl8.4.so #18 0xb7e14aab in TclEvalObjvInternal () from /usr/lib/libtcl8.4.so #19 0xb7e406dd in TclExecuteByteCode () from /usr/lib/libtcl8.4.so #20 0xb7e44278 in TclCompEvalObj () from /usr/lib/libtcl8.4.so #21 0xb7e15b18 in Tcl_EvalObjEx () from /usr/lib/libtcl8.4.so #22 0xb7e1cbab in Tcl_CatchObjCmd () from /usr/lib/libtcl8.4.so #23 0xb7e14aab in TclEvalObjvInternal () from /usr/lib/libtcl8.4.so #24 0xb7e406dd in TclExecuteByteCode () from /usr/lib/libtcl8.4.so #25 0xb7e44278 in TclCompEvalObj () from /usr/lib/libtcl8.4.so #26 0xb7e15b18 in Tcl_EvalObjEx () from /usr/lib/libtcl8.4.so #27 0xb7e24b3e in Tcl_SwitchObjCmd () from /usr/lib/libtcl8.4.so #28 0xb7e14aab in TclEvalObjvInternal () from /usr/lib/libtcl8.4.so #29 0xb7e406dd in TclExecuteByteCode () from /usr/lib/libtcl8.4.so #30 0xb7e44278 in TclCompEvalObj () from /usr/lib/libtcl8.4.so #31 0xb7e15b18 in Tcl_EvalObjEx () from /usr/lib/libtcl8.4.so #32 0xb7e24b3e in Tcl_SwitchObjCmd () from /usr/lib/libtcl8.4.so #33 0xb7e14aab in TclEvalObjvInternal () from /usr/lib/libtcl8.4.so #34 0xb7e406dd in TclExecuteByteCode () from /usr/lib/libtcl8.4.so #35 0xb7e44278 in TclCompEvalObj () from /usr/lib/libtcl8.4.so #36 0xb7e6ff65 in TclObjInterpProc () from /usr/lib/libtcl8.4.so #37 0xb7e14aab in TclEvalObjvInternal () from /usr/lib/libtcl8.4.so #38 0xb7e1502d in Tcl_EvalEx () from /usr/lib/libtcl8.4.so #39 0xb7eeca18 in Ns_TclEvalCallback (interp=0xa880a360, cbPtr=0xb1eb7f28, result=0x0) at tclcallbacks.c:170 #40 0xb7efcf75 in NsTclSchedProc (arg=0xb1eb7f28, id=21) at tclsched.c:383 #41 0xb7ee5209 in EventThread (arg=0x0) at sched.c:681 #42 0xb7ea628b in NsThreadMain (arg=0xb1e68570) at thread.c:211 #43 0xb7ea731a in ThreadMain (arg=0xb1e68570) at pthread.c:752 #44 0xb7c3627b in start_thread () from /lib/libpthread.so.0 #45 0xb7d0208e in clone () from /lib/libc.so.6 -- Vlad Seryakov 571 262-8608 office vl...@cr... http://www.crystalballinc.com/vlad/ |
From: Stephen D. <sd...@gm...> - 2006-11-13 19:22:10
|
http://sourceforge.net/mailarchive/forum.php?thread_id=30614948&forum_id=43966 On 11/13/06, Vlad Seryakov <vl...@cr...> wrote: > > I wonder why ns_sls.man is under src/mann and not under src/ where all > Tcl API commands are? > > Stephen Deasey wrote: > > > > Update of /cvsroot/naviserver/naviserver/doc/src/mann > > In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv28169/doc/src/mann > > |
From: Zoran V. <zv...@ar...> - 2006-11-13 18:23:53
|
On 13.11.2006, at 19:12, Stephen Deasey wrote: > > Should I use 'fun' for C instead of 'cmd'? I think this is ok. > > What's the deal with 'cmd_def' and 'arg_def' rather than 'cmd' and > 'arg'? The former are used in list definitions (list_begin/list_end) > > What's an i/o-mode? in/out? Yes. Input or output argument. I guess this is ment to be defined for function arguments that pass the value and at the same time hold the return value(s). > > How do I document a structure? He... a good question.... I do not know. |
From: Vlad S. <vl...@cr...> - 2006-11-13 18:22:09
|
I wonder why ns_sls.man is under src/mann and not under src/ where all Tcl API commands are? Stephen Deasey wrote: > Update of /cvsroot/naviserver/naviserver/doc/src/mann > In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv28169/doc/src/mann > > Added Files: > ns_sls.man > Log Message: > * include/ns.h: > * nsd/nsd.h > * nsd/sls.c: > * nsd/tclcmds.c: > * nsd/driver.c: > * nsd/init.c: > * nsd/Makefile: > * doc/src/mann/ns_sls.man: > * tests/ns_sls.test: Add Ns_Sls* and ns_sls commands supporting > socket-local-storage (data which persists for the lifetime of an > open TCP connection). Fixes Bug #1522162. > > > --- NEW FILE: ns_sls.man --- > [include ../version_include] > > [manpage_begin ns_sls n [vset version]] > [moddesc {NaviServer Built-In Commands}] > [titledesc {socket local storage for connections}] > > [description] > > The underlying TCP socket used by a NaviServer connection may be kept open and > reused for further connections, e.g. during HTTP keep-alive . The [cmd ns_sls] > commands associate data with the socket, which will be available to future > connections on that socket. The data is freed automatically when the socket > closes. > > [para] > The data is saved as a string, both for thread safety and to allow easy > sharing with C code using the [cmd Ns_SlsGetKeyed] and [cmd Ns_SlsSetKeyed] > API. > > [para] > Per-socket data is often used by socket drivers and protocol > drivers. It may be tempting to save HTTP session data here, but beware: > intermediate HTTP proxies may send multiple, unrelated requests using a single > TCP socket. You may be looking for [cmd Ns_Cls] -- connection local storage. > > [para] > All the [cmd ns_sls] commands require an active connection. > > > [section COMMANDS] > [list_begin definitions] > > > [call [cmd "ns_sls set"] [arg key] [arg value]] > > Set the string value of an sls key. Any old value will be freed. The new value > will be freed automatically when the socket is closed. > > > [call [cmd "ns_sls get"] [arg key] [opt [arg default]]] > > Get the current string value of an sls key. If the key does not exist and no > default was given an error is raised, otherwise the default is returned. > > > [call [cmd "ns_sls unset"] [arg key]] > > Free the data associated with the given key. A key which doesn't exist is > ignored. > > > [call [cmd "ns_sls array"]] > > Return a list of sls keys and values in array-get format. > > > [list_end] > > > > [section EXAMPLES] > > Log the number of connections handled by a single TCP socket: > > [example_begin] > set n [lb][cmd "ns_sls get"] connections 0[rb] > incr n > ns_sls set connections $n > > if {$n > 1} { > ns_log notice connections: $n > } > [example_end] > > > Log all the keys and data stored for the socket of the currently active > connection: > > [para] > (NB: Does not include C module data set via the [cmd Ns_SlsSet] API) > > [example_begin] > foreach {k v} [lb][cmd "ns_sls array"][rb] { > ns_log notice sls: $k: $v > } > [example_end] > > > [see_also Ns_Sls Ns_Cls] > [keywords sls storage data] > [manpage_end] > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > naviserver-commits mailing list > nav...@li... > https://lists.sourceforge.net/lists/listinfo/naviserver-commits > -- Vlad Seryakov 571 262-8608 office vl...@cr... http://www.crystalballinc.com/vlad/ |
From: Stephen D. <sd...@gm...> - 2006-11-13 18:13:04
|
On 11/13/06, Zoran Vasiljevic <zv...@ar...> wrote: > > On 13.11.2006, at 18:25, Vlad Seryakov wrote: > > > But why our current template will not work for C API? It can describe > > functions and arguments same way? > > It can, this is no problem. You will get a page-per-api-call. > Under man pages it is common to have one man page describing > many related api calls. It is this that does not work (yet) > in doctools. Should I use 'fun' for C instead of 'cmd'? What's the deal with 'cmd_def' and 'arg_def' rather than 'cmd' and 'arg'? What's an i/o-mode? in/out? How do I document a structure? http://tcllib.sourceforge.net/doc/doctools_fmt.html |
From: Zoran V. <zv...@ar...> - 2006-11-13 17:50:39
|
On 13.11.2006, at 18:25, Vlad Seryakov wrote: > But why our current template will not work for C API? It can describe > functions and arguments same way? It can, this is no problem. You will get a page-per-api-call. Under man pages it is common to have one man page describing many related api calls. It is this that does not work (yet) in doctools. Zoran |
From: Vlad S. <vl...@cr...> - 2006-11-13 17:28:12
|
But why our current template will not work for C API? It can describe functions and arguments same way? Zoran Vasiljevic wrote: > On 13.11.2006, at 18:18, Vlad Seryakov wrote: > >> why it is not possible? > > Good question! I have never find a way to do so > in the doctools. And I did experiment some time > with it... > I guess Andreas will know more. I recall discussing > this with him some time ago... As for now, the Tcl > code (all in tcllib) is pretty good covered with the > doctools. AFAIK, there is no attempt to apply it to > C-API so far. > > Zoran > > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > naviserver-devel mailing list > nav...@li... > https://lists.sourceforge.net/lists/listinfo/naviserver-devel > -- Vlad Seryakov 571 262-8608 office vl...@cr... http://www.crystalballinc.com/vlad/ |
From: Zoran V. <zv...@ar...> - 2006-11-13 17:25:52
|
On 13.11.2006, at 18:18, Vlad Seryakov wrote: > why it is not possible? Good question! I have never find a way to do so in the doctools. And I did experiment some time with it... I guess Andreas will know more. I recall discussing this with him some time ago... As for now, the Tcl code (all in tcllib) is pretty good covered with the doctools. AFAIK, there is no attempt to apply it to C-API so far. Zoran |
From: Vlad S. <vl...@cr...> - 2006-11-13 17:21:01
|
why it is not possible? Zoran Vasiljevic wrote: > On 13.11.2006, at 17:59, Stephen Deasey wrote: > >> Anyone got an example of a C API documented using doctools? > > Well, my fault... AFAIK, the way of documenting C-API to be > close to what we can normally see under "man strstr" for > example (i.e. many calls documented under one manpage) is > not possible to implement in doctools. That is, in the > doctools as-is. I yet have to speak with Andreas from the > Activestate (the author of the doctools) to see how this > would be possible and what needs to be done for that. > > Zoran > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > naviserver-devel mailing list > nav...@li... > https://lists.sourceforge.net/lists/listinfo/naviserver-devel > -- Vlad Seryakov 571 262-8608 office vl...@cr... http://www.crystalballinc.com/vlad/ |
From: Zoran V. <zv...@ar...> - 2006-11-13 17:17:09
|
On 13.11.2006, at 17:59, Stephen Deasey wrote: > Anyone got an example of a C API documented using doctools? Well, my fault... AFAIK, the way of documenting C-API to be close to what we can normally see under "man strstr" for example (i.e. many calls documented under one manpage) is not possible to implement in doctools. That is, in the doctools as-is. I yet have to speak with Andreas from the Activestate (the author of the doctools) to see how this would be possible and what needs to be done for that. Zoran |
From: Vlad S. <vl...@cr...> - 2006-11-13 17:05:18
|
I guess it should have the same format as for Tcl API, we just do not have anything yet in the docs repository. Stephen Deasey wrote: > Anyone got an example of a C API documented using doctools? > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > naviserver-devel mailing list > nav...@li... > https://lists.sourceforge.net/lists/listinfo/naviserver-devel > -- Vlad Seryakov 571 262-8608 office vl...@cr... http://www.crystalballinc.com/vlad/ |
From: Stephen D. <sd...@gm...> - 2006-11-13 16:59:23
|
Anyone got an example of a C API documented using doctools? |
From: Bernd E. <eid...@we...> - 2006-11-08 07:52:18
|
> Ns_SockSendBufs() is not supposed to send all at once, that is the > problem. That's why small change i sent to Bernd should fix it, i just > do not want to commit it before the test. Looks good, I changed the driver.c line, replaced nsd and libnsd.so and changed writerbufsize in config to 8192: [-conn:server1:6] Notice: starting download [-conn:server1:6] Notice: Writer: 4: started sock=5, fd=7: size=24445108, flags=10: /download/ [-conn:server1:6] Notice: finished download in 0 seconds [-writer4-] Notice: Writer: closed sock=5, fd=7, error=0/0, sent=24445108, flags=10 I can stop the download and resume/restart it without errors. One note: I tested older code that does not make use of ns_writer commands, it still runs ns_returnfile. I set outputheaders to prepare for a PDF download, computed and logged duration and success or failure (both obsolete with writerthreads). When I naively replace the ns_returnfile line with a ns_writer submitfile $download_path I immediately receive an empty page (no log statements indicating some error, btw). Not that I feel the urge to replace ns_returnfile if it works... Bernd. |
From: Vlad S. <vl...@cr...> - 2006-11-07 18:45:01
|
Ns_SockSendBufs() is not supposed to send all at once, that is the problem. That's why small change i sent to Bernd should fix it, i just do not want to commit it before the test. Stephen Deasey wrote: > On 11/7/06, Zoran Vasiljevic <zv...@ar...> wrote: >> On 07.11.2006, at 17:02, Bernd Eidenschink wrote: >> >>> I set logmaxlevel to 6 (dev) and I sometimes see lines like: >>> >>> Debug: SockSend: Resource temporarily unavailable >>> Debug: SockSend: Resource temporarily unavailable >>> (...) >> Out of the blue, I would not consider this a problem. >> This is reading on an non-blocking socket that has no >> bytes in the buffer. Some OS'es emit EAGAIN some >> EWOULDBLOCK on that place (aparently this OS does EAGAIN). > > > It's writing, not reading... :-) > > Anyway, this is actually an error, in the case of the writer thread at > least. In nsd/driver.c the writer thread calls Ns_SockSendBufs() and > if the return value is not the full amount, an error condition is > signalled. > > I added the debug message because looking at the way code was calling > Ns_SockSendBufs() (or Ns_SockSend(), which actually doesn't have this > logging message, oops), it was expecting the call to succeed. This > wrapper function actually retries to send the data if the first > attempt fails, but it only retries *once*, and then it gives up. > > If you see the above message then I believe the writer thread failed > to send all it's data and gave up. > > I don't think the API is great. It confuses the issue of who's > responsible for ensuring data gets written. Is Ns_SockSend* supposed > to send all the data or not? I guess the issue is fudged because all > the socket is in non-blocking mode, because the read-side does in fact > do non blocking reads, the write side was always called by a conn > thread and was expecting to write everything before returning. > > That isn't the case now that there is the writer thread stuff. But > either way it's still broken. It sort of half promises to send stuff. > Two attempts and then it gives up... > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > naviserver-devel mailing list > nav...@li... > https://lists.sourceforge.net/lists/listinfo/naviserver-devel > -- Vlad Seryakov 571 262-8608 office vl...@cr... http://www.crystalballinc.com/vlad/ |
From: Stephen D. <sd...@gm...> - 2006-11-07 18:36:54
|
On 11/7/06, Zoran Vasiljevic <zv...@ar...> wrote: > > On 07.11.2006, at 17:02, Bernd Eidenschink wrote: > > > > > I set logmaxlevel to 6 (dev) and I sometimes see lines like: > > > > Debug: SockSend: Resource temporarily unavailable > > Debug: SockSend: Resource temporarily unavailable > > (...) > > Out of the blue, I would not consider this a problem. > This is reading on an non-blocking socket that has no > bytes in the buffer. Some OS'es emit EAGAIN some > EWOULDBLOCK on that place (aparently this OS does EAGAIN). It's writing, not reading... :-) Anyway, this is actually an error, in the case of the writer thread at least. In nsd/driver.c the writer thread calls Ns_SockSendBufs() and if the return value is not the full amount, an error condition is signalled. I added the debug message because looking at the way code was calling Ns_SockSendBufs() (or Ns_SockSend(), which actually doesn't have this logging message, oops), it was expecting the call to succeed. This wrapper function actually retries to send the data if the first attempt fails, but it only retries *once*, and then it gives up. If you see the above message then I believe the writer thread failed to send all it's data and gave up. I don't think the API is great. It confuses the issue of who's responsible for ensuring data gets written. Is Ns_SockSend* supposed to send all the data or not? I guess the issue is fudged because all the socket is in non-blocking mode, because the read-side does in fact do non blocking reads, the write side was always called by a conn thread and was expecting to write everything before returning. That isn't the case now that there is the writer thread stuff. But either way it's still broken. It sort of half promises to send stuff. Two attempts and then it gives up... |
From: Zoran V. <zv...@ar...> - 2006-11-07 16:51:29
|
On 07.11.2006, at 17:02, Bernd Eidenschink wrote: > > I set logmaxlevel to 6 (dev) and I sometimes see lines like: > > Debug: SockSend: Resource temporarily unavailable > Debug: SockSend: Resource temporarily unavailable > (...) Out of the blue, I would not consider this a problem. This is reading on an non-blocking socket that has no bytes in the buffer. Some OS'es emit EAGAIN some EWOULDBLOCK on that place (aparently this OS does EAGAIN). Cheers Zoran |
From: Bernd E. <eid...@we...> - 2006-11-07 16:01:03
|
Hi Vlad, > Looks like in your environment, writer cannot send buffers greater than > 512, not sure why yep, I have many directions to look for... It's NaviServer in a chroot, on a SUSE LINUX Enterprise Server 9. I set logmaxlevel to 6 (dev) and I sometimes see lines like: Debug: SockSend: Resource temporarily unavailable Debug: SockSend: Resource temporarily unavailable (...) when the page (with lots of images) gets rendered and I follow some links/images. This is not writer-thread related, but adds to the socket "thing". I'll give the driver.c change a try, thanks. Bernd. |
From: Vlad S. <vl...@cr...> - 2006-11-07 15:12:40
|
Also, for test sake, can you change driver.c:2777 from if (n < curPtr->bufsize) { to if (n < 0) { and see if it will work, Ns_SockSend may send less bytes which is not an error condition Vlad Seryakov wrote: > in my config it works fine with bufsize 8192. This parameter tells the > writer size of the buffer and size of the chunk to sent on each > iteration. Minimum is 512, so when you set it to 1 actually it is 512. > Looks like in your environment, writer cannot send buffers greater than > 512, not sure why > > ns_param writerthreads 1 > ns_param writersize [expr 1024*1024] > > > [07/Nov/2006:10:01:06][17239.3055905696][-conn:oss2:0] Notice: Writer: > 0: started sock=6, fd=8: size=1125737214, flags=10: /.Movies/AeonFlux.avi > [07/Nov/2006:10:01:39][17239.3000527776][-writer0-] Notice: Writer: > closed sock=6, fd=8, error=0/0, sent=1125737214, flags=10 > > > Bernd Eidenschink wrote: >> Hi, >> >> with the default config (writerbufsize 8192) I immediately get this error >> (probably SOCK_WRITEERROR) when trying to download the testfile on my server: >> >> [-writer0-] Notice: Writer: closed sock=5, fd=7, error=-8/0, sent=8192, >> flags=10 >> >> When I set writerbufsize to something very small, let's say "1", it works. >> >> Do you have a tip in what direction to look for the cause? >> >> Bernd. >> >> ------------------------------------------------------------------------- >> Using Tomcat but need to do more? Need to support web services, security? >> Get stuff done quickly with pre-integrated technology to make your job easier >> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo >> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >> _______________________________________________ >> naviserver-devel mailing list >> nav...@li... >> https://lists.sourceforge.net/lists/listinfo/naviserver-devel >> > -- Vlad Seryakov 571 262-8608 office vl...@cr... http://www.crystalballinc.com/vlad/ |
From: Vlad S. <vl...@cr...> - 2006-11-07 15:06:19
|
in my config it works fine with bufsize 8192. This parameter tells the writer size of the buffer and size of the chunk to sent on each iteration. Minimum is 512, so when you set it to 1 actually it is 512. Looks like in your environment, writer cannot send buffers greater than 512, not sure why ns_param writerthreads 1 ns_param writersize [expr 1024*1024] [07/Nov/2006:10:01:06][17239.3055905696][-conn:oss2:0] Notice: Writer: 0: started sock=6, fd=8: size=1125737214, flags=10: /.Movies/AeonFlux.avi [07/Nov/2006:10:01:39][17239.3000527776][-writer0-] Notice: Writer: closed sock=6, fd=8, error=0/0, sent=1125737214, flags=10 Bernd Eidenschink wrote: > Hi, > > with the default config (writerbufsize 8192) I immediately get this error > (probably SOCK_WRITEERROR) when trying to download the testfile on my server: > > [-writer0-] Notice: Writer: closed sock=5, fd=7, error=-8/0, sent=8192, > flags=10 > > When I set writerbufsize to something very small, let's say "1", it works. > > Do you have a tip in what direction to look for the cause? > > Bernd. > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > naviserver-devel mailing list > nav...@li... > https://lists.sourceforge.net/lists/listinfo/naviserver-devel > -- Vlad Seryakov 571 262-8608 office vl...@cr... http://www.crystalballinc.com/vlad/ |
From: Bernd E. <eid...@we...> - 2006-11-07 12:31:43
|
Hi, with the default config (writerbufsize 8192) I immediately get this error (probably SOCK_WRITEERROR) when trying to download the testfile on my server: [-writer0-] Notice: Writer: closed sock=5, fd=7, error=-8/0, sent=8192, flags=10 When I set writerbufsize to something very small, let's say "1", it works. Do you have a tip in what direction to look for the cause? Bernd. |
From: Zoran V. <zv...@ar...> - 2006-10-09 12:55:48
|
On 09.10.2006, at 14:48, Zoran Vasiljevic wrote: > timeout.test > [09/Oct/2006:14:46:38][3371.41972224][-conn:test:0] Error: GET / > timeout.tcl, PeerAddress: 127.0.0.1 > can't read "path": no such variable > while executing > "proc ns:tclcache_$path {} {}" > (procedure "ns_sourceproc" line 14) > invoked from within > "ns_sourceproc" > while executing callback > ns:tclrequest ns_sourceproc > fixed (tcl/file.tcl was busted). |
From: Zoran V. <zv...@ar...> - 2006-10-09 12:48:55
|
timeout.test [09/Oct/2006:14:46:38][3371.41972224][-conn:test:0] Error: GET / timeout.tcl, PeerAddress: 127.0.0.1 can't read "path": no such variable while executing "proc ns:tclcache_$path {} {}" (procedure "ns_sourceproc" line 14) invoked from within "ns_sourceproc" while executing callback ns:tclrequest ns_sourceproc |
From: Zoran V. <zv...@ar...> - 2006-10-08 19:10:41
|
On 07.10.2006, at 19:37, Stephen Deasey wrote: > > This seems completely broken. What am I missing? Why don't you go to tcl core list with this? |
From: Stephen D. <sd...@gm...> - 2006-10-07 17:37:13
|
On 10/7/06, Zoran Vasiljevic <zv...@ar...> wrote: > Stephen, this is what I got on Tcl core: > > Begin forwarded message: > > > From: miguel sofer <mi...@ut...> > > Date: 7. Oktober 2006 16:30:05 MESZ > > To: Zoran Vasiljevic <zv...@ar...> > > Cc: miguel <ms...@us...>, Tcl List Core <tcl- > > co...@li...> > > Subject: Re: [TCLCORE] Lifetime of a literal object > > Reply-To: mi...@ut... > > > > Zoran Vasiljevic wrote: > >> On 07.10.2006, at 16:05, Zoran Vasiljevic wrote: > >> > >>> Ah... that's what I was afaid of... > >>> Actually, I wanted to use tne internal rep of that object to > >>> store (or better cache) some expensivley calculated value. > >>> I was hoping to have this object "alive" for the time my > >>> predure is defined at least or (better) until the interp > >>> which house it is destroyed. > >> > >> To be more precise, I wanted to cheat... > >> > >> Consider: > >> > >> proc foo args { > >> puts baz > >> cache baz > >> return > >> } > >> proc humpty args { > >> puts dumpty > >> cache dumpty > >> return > >> } > >> > >> Now the [cache] above is my hypothetical command > >> which calculates some arbitrary value and splices > >> it in the object internal rep but w/o invalidating > >> its string rep. > >> It does that ONLY if the current internal rep of the > >> (literal) object does not already contain precalculated > >> value. > >> > >> What I hope to achieve with that is: only the first time > >> when I call the procedure my [cache] will actually have > >> to do the calculation. All other invocations will use > >> pre-calculated value stored in the "baz" or "dumpty" > >> literals. > >> So this way I could "re-use" literals as poor man's cache. > >> > >> Would that work? > > > > For a while ... but I wouldn't. Such a misuse of Tcl_Objs and EIAS may > > lead to weird bugs. > > > > I encourage you to talk with Jean-Claude Wippler about these issues; > > he's been looking for workarounds for ages. If you guys do find a good > > way to do things, share it! > > > > Refs that may be interesting: > > http://aspn.activestate.com/ASPN/Mail/Message/3168511 > > https://sourceforge.net/tracker/index.php? > > func=detail&aid=1512138&group_id=10894&atid=360894 > > http://aspn.activestate.com/ASPN/Mail/Message/tcl-core/3168677 > > Thanks for looking into this! I think Miguel has the wrong end of the stick. Jean Claude is trying to do the opposite of what I am -- he wants to change the string representation without changing the internal rep. That's weird because the string rep is the canonical rep. "1" can be a string, or it can be an int. The string rep is the same, but depending on which command you pass it to, the internal rep can change. The internal rep is a private implementation detail of each command. What I'm trying to do is change the internal rep without invalidating the string rep. That's slightly weird as the usual reason for changing the internal rep is because the notion of the object value has changed, such as from 1 to 2, and therefore the string rep also needs to change (although lazily, so we just invalidate it). However, it's not *that* weird. I copied the idea straight from the Tcl core! Consider the Tcl_GetIndexFromObj() function: /* *---------------------------------------------------------------------- * * Tcl_GetIndexFromObj -- * * This function looks up an object's value in a table of strings and * returns the index of the matching string, if any. * * Results: * ... * * Side effects: * The result of the lookup is cached as the internal rep of objPtr, so * that repeated lookups can be done quickly. * *---------------------------------------------------------------------- */ the result of the lookup is cached in the internal rep. That's exactly what I'm doing. Here's how it happens (Tcl_GetIndexFromObjStruct): done: /* * Cache the found representation. Note that we want to avoid allocating a * new internal-rep if at all possible since that is potentially a slow * operation. */ if (objPtr->typePtr == &indexType) { indexRep = (IndexRep *) objPtr->internalRep.otherValuePtr; } else { TclFreeIntRep(objPtr); indexRep = (IndexRep *) ckalloc(sizeof(IndexRep)); objPtr->internalRep.otherValuePtr = (void *) indexRep; objPtr->typePtr = &indexType; } The important bit is the 'else' arm. Notice how the internal rep of the object is changed, but the string rep is not invalidated. (Neither is it's ref count checked.) This is all fine as far as I can see. It doesn't break Tcl's COW semantics for objects, which is concerned with the *value* of the object, not the implementation details of how that is stored. But we've learnt that Tcl likes to put literals in an object cache and pass around a single, shared object. So what happens in the following case? proc foo args { ns_job eval -timeout 5 -- ... ns_proxy eval -timeout 5 -- ... } Both '-timeout' and 'eval' are literals and will end up in the literal cache when the foo proc is byte code compiled. The recommended way to parse sub-commands is with Tcl_GetIndexFromObj(). The first time it is called for the ns_job command it will cache the result of it's lookup in the 'eval' literal. The next lookup should be fast. But the shared 'eval' object is than passed to ns_proxy and when it runs Tcl_TclGetIndexFromObj() a new result will be cached as the internal rep. Decoding sub-commands will never be quick as shared literals will be shimmering back and forth between one cached value and another. It will be extremely common to have sub commands and switches with the same name. This seems completely broken. What am I missing? |
From: Zoran V. <zv...@ar...> - 2006-10-07 17:26:10
|
On 07.10.2006, at 19:00, Stephen Deasey wrote: > But the case where you need to serially execute jobs in the slave can > be handled by either passing them all at once, or by using a > 'withhandle' command. > > What do you think of the withhandle command? Can you get away with > passing everything to the slave at once, and if not, does the > withhandle command cover this? On the first glance, I'd say yes. But you know me... It may change the next second. So, let me think this over again... |