Hi,
I have made a first round through Hunchentoot with the goals being:
- Remove system specific code, relying on common compatibility libraries instead - Make single threaded operation a run-time option - Add timeout support for more platforms - Factor out SSL specific code so that conditional code is reduced - Remove mod_lisp support to ease refactoring and simplify the code
I met most of these goals:
- Instead of using functions from port-*.lisp, Hunchentoot now depends on bordeaux-threads for multiple thread support and on usocket for socket i/o. The GET-BACKTRACE function still remains as being non-portable.
- Threading behavior is now controller by a CONNECTION-MANAGER. Every SERVER object has one CONNECTION-MANAGER and delegates listening and connection processing to that instance. Currently, there exist two CONNECTION-MANAGER classes: SINGLE-THREADED-CONNECTION-MANAGER listens and processes connections synchronously, ONE-THREAD-PER-CONNECTION-MANAGER listens in a separate thread and processes each connection in a new thread, as Hunchentoot did on multi-threaded platforms until now. The API for START-SERVER supports a THREADED keyword argument for simplicity, but it may be desirable to implement other CONNECTION-MANAGER classes in the future (for example to pool threads and/or separate connection management from request execution).
Timeouts which are really an issue that is hard to solve, as there is no cross-implementation agreement on what timeouts are and how they should be implemented. As I need to make progress, I have added a platform specific SET-TIMEOUTS function which uses whatever mechanism the Lisp platform offers. I have removed the setting for separate read and write timeouts as I don't think that it is really useful make the distinction, but if someone has a really good use case, I may be adding them.
I am currently testing my changes on more platforms and compilers. CCL and SBCL work fine, Lispworks is under investigation, I'll also look at CLISP later on. If there are other platforms that you'd like to see supported in the future, please check out the branch and send me patches.
Branch SVN URL:
http://common-lisp.net/project/tbnl/svn/branches/hans
Trac URL for browsing:
http://trac.common-lisp.net/tbnl/browser/branches/hans
RSS URL for commits:
http://trac.common-lisp.net/tbnl/timeline?changeset=on&max=50&daysba...
� wrote:
The GET-BACKTRACE function still remains as being non-portable.
Is there a possibility of splitting it off to a separate library too? It'll be just the thin portability layer, of course, but I can see some other possible uses for a hypothetical, well, say, chardonnay-backtraces library. For example some (non-web) delivered applications that could write backtraces to a log file to be examined by the author later, or to be emailed to the author.
Cheers, Ury
On Tue, 29 Apr 2008 03:21:39 +0300, Ury Marshak urym@two-bytes.com wrote:
Is there a possibility of splitting it off to a separate library too?
Sure there is. I think the main problem is to find someone who packages, documents, and maintains it.
I'll volunteer.
On Apr 29, 2008, at 2:18 AM, Edi Weitz wrote:
On Tue, 29 Apr 2008 03:21:39 +0300, Ury Marshak urym@two-bytes.com wrote:
Is there a possibility of splitting it off to a separate library too?
Sure there is. I think the main problem is to find someone who packages, documents, and maintains it. _______________________________________________ tbnl-devel site list tbnl-devel@common-lisp.net http://common-lisp.net/mailman/listinfo/tbnl-devel
-- Gary Warren King, metabang.com Cell: (413) 559 8738 Fax: (206) 338-4052 gwkkwg on Skype * garethsan on AIM
On Tue, Apr 29, 2008 at 1:04 PM, Gary King gwking@metabang.com wrote:
I'll volunteer.
Great, keep us posted! I'll integrate the trivial-backtrace package into my Hunchentoot branch once it exists. It'll be some more weeks before I can think about getting a Hunchentoot release done from the branch anyway.
-Hans