Return-Path: Delivered-To: apmail-xml-axis-dev-archive@xml.apache.org Received: (qmail 60755 invoked by uid 500); 26 Sep 2002 15:32:16 -0000 Mailing-List: contact axis-dev-help@xml.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-dev@xml.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list axis-dev@xml.apache.org Received: (qmail 60739 invoked from network); 26 Sep 2002 15:32:15 -0000 To: axis-dev@xml.apache.org MIME-Version: 1.0 Subject: [axis] Smart(er) Handlers X-Mailer: Lotus Notes Build V60_M14_08012002 Release Candidate August 01, 2002 From: Richard Sitze Message-ID: Date: Thu, 26 Sep 2002 10:32:13 -0500 X-MIMETrack: Serialize by Router on D03NM145/03/M/IBM(Build V60_09122002|September 12, 2002) at 09/26/2002 09:32:16, Serialize complete at 09/26/2002 09:32:16 Content-Type: text/plain; charset="US-ASCII" X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Given a list of handlers to load: H1, H2, H3 in WSDD, what I'm proposing is that the runtime query each handler as it identifies it in a service configuration and *ask* the handler if it wants to be loaded in the current environment: if (handler->isEnvironmentallyFriendly()) put handler in chain... Semantically, we can do the same thing by letting the handler (when called) return immediately IF it doesn't have anything to do. Why: - I'm a performance bigot, and if the handler isn't going to *do* anything, then I don't want it called. - It's easy to code. Example 1: A Service Handler: verify that required service/classes are (loadable) and disable handler if not. Example 2: Debug Handler: enable only if debug-mode ON **** So, having put some effort into trying to give you an example (I can't really SAY what my internal requirements are, now can I :-), it stricks me that a reasonable and cool alternate might be: realHandler = configuredHandler->getRealHandler(); if (realHanderl != null) put realHandler in chain... [names should be changed to protect the innocent..] Default behaviour is getRealHandler() { return this; } So, the method getRealHandler can act as a factory... a security handler could return a 64 or 128 bit security scheme. ******************************************* Richard A. Sitze IBM WebSphere WebServices Development