attachment-0001

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">


<META content="MSHTML 5.50.4807.2300" name=GENERATOR></HEAD>
<BODY>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff size=2>Hey 
Harry...</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff size=2>I 
believe that the polling scenario is indeed the correct model.&nbsp; For this 
particular method, we may not have it exactly right.&nbsp; We could overload the 
JobID == 0 to mean that no job is available, but that doesn't quite feel 
right.</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2>Throwing an exception in this case is really our way of informing the 
client (targetdevice) that no job is available for it yet.</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2>Dave</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff size=2>Pseudo 
code:</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2>Boolean bJobAvailable = false;</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff size=2>String 
JobID = "";</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff size=2>while 
(!bJobAvailable)</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2>{</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp; <FONT face=Arial 
color=#0000ff size=2>try</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp; <FONT face=Arial 
color=#0000ff size=2>{</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>JobID = 
PrintService.TargetDeviceSupportInterface.GetNextJob("myTargetDeviceIdentifier");</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>bJobAvailable = true;</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp; <FONT face=Arial 
color=#0000ff size=2>}</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp; <FONT face=Arial 
color=#0000ff size=2>catch (Exception e)</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp; <FONT face=Arial 
color=#0000ff size=2>{</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>if (e == 
InvalidTargetDeviceIdentifier)</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>{</FONT></SPAN></DIV>
<DIV><SPAN 
class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff 
size=2>exit(InvalidTargetDeviceIdentifier);</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>}</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>elseif (e == 
TargetDeviceNotSupported)</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>{</FONT></SPAN></DIV>
<DIV><SPAN 
class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff 
size=2>exit(TargetDeviceNotSupported);</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>}</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>elseif (e == 
NoJobAvaliable)</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>{</FONT></SPAN></DIV>
<DIV><SPAN 
class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>// OK, keep polling</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<FONT face=Arial color=#0000ff size=2>}</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2>&nbsp;&nbsp;&nbsp; }</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2>}</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff size=2>// Now 
we have a JobID, continue processing...</FONT></SPAN></DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=245130521-19092002><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<BLOCKQUOTE>
  <DIV class=OutlookMessageHeader dir=ltr align=left><FONT face=Tahoma 
  size=2>-----Original Message-----<BR><B>From:</B> Harry Lewis 
  [mailto:harryl@us.ibm.com]<BR><B>Sent:</B> Thursday, September 19, 2002 1:48 
  PM<BR><B>To:</B> HALL,DAVID (HP-Vancouver,ex1)<BR><B>Cc:</B> BERKEMA,ALAN C 
  (HP-Roseville,ex1); HALL,DAVID (HP-Vancouver,ex1); 
  ps@pwg.org<BR><B>Subject:</B> RE: Throwing 
  exceptions<BR><BR></FONT></DIV><BR><FONT face=sans-serif size=2>OK, thanks for 
  that clarification. Related question...</FONT> <BR><BR><FONT face=sans-serif 
  size=2>In the TargetDeviceSupportInterface the operation GetNextJob "throws 
  and exception" if no job is available for the target device. I assume, then, 
  this is a SOAP "fault"? If so, is this really what we want? The design is 
  polling from target device to print service. In this case won't "no job 
  available" be the more likely case? Or, are we suggesting (via the scenarios) 
  that the target device isn't expected to poll unless having been asked to out 
  of band by a client (implying there SHOULD be a job present... thus the 
  "fault")?<BR>---------------------------------------------- <BR>Harry Lewis 
  <BR>IBM Printing Systems <BR>---------------------------------------------- 
  </FONT><BR><BR><BR>
  <TABLE width="100%">
    <TBODY>
    <TR vAlign=top>
      <TD>
      <TD><FONT face=sans-serif size=1><B>"HALL,DAVID (HP-Vancouver,ex1)" 
        &lt;dhall@hp.com&gt;</B></FONT> 
        <P><FONT face=sans-serif size=1>09/19/2002 10:33 AM</FONT> <BR></P>
      <TD><FONT face=Arial size=1>&nbsp; &nbsp; &nbsp; &nbsp; </FONT><BR><FONT 
        face=sans-serif size=1>&nbsp; &nbsp; &nbsp; &nbsp; To: &nbsp; &nbsp; 
        &nbsp; &nbsp;Harry Lewis/Boulder/IBM@IBMUS, "HALL,DAVID 
        (HP-Vancouver,ex1)" &lt;dhall@hp.com&gt;</FONT> <BR><FONT 
        face=sans-serif size=1>&nbsp; &nbsp; &nbsp; &nbsp; cc: &nbsp; &nbsp; 
        &nbsp; &nbsp;ps@pwg.org, "BERKEMA,ALAN C (HP-Roseville,ex1)" 
        &lt;alan_berkema@hp.com&gt;</FONT> <BR><FONT face=sans-serif 
        size=1>&nbsp; &nbsp; &nbsp; &nbsp; Subject: &nbsp; &nbsp; &nbsp; 
        &nbsp;RE: Throwing exceptions</FONT> <BR><BR><FONT face=Arial 
        size=1>&nbsp; &nbsp; &nbsp; &nbsp;</FONT></TR></TBODY></TABLE><BR><BR><FONT 
  face=Arial color=blue size=2>We are rapidly approaching a working PSI 
  prototype that will be able to "throw exceptions" from the method calls. 
  &nbsp;They are known as "soap faults"...</FONT> <BR><FONT 
  face="Times New Roman" size=3>&nbsp;</FONT> <BR><FONT face=Arial color=blue 
  size=2>Our current methods don't "throw exceptions" in the XML string 
  parameters that are returned, it was an unfortunate naming of the return 
  paramater - "ExceptionAttributes" that is now named "UnsupportedAttributes". 
  &nbsp;Returning "UnsupportedAttributes" does not mean that an error has 
  occured, rather that some requested attributes are not supported by the 
  service.</FONT> <BR><FONT face="Times New Roman" size=3>&nbsp;</FONT> 
  <BR><FONT face=Arial color=blue size=2>We will be throwing "faults" from the 
  soap calls...</FONT> <BR><FONT face="Times New Roman" size=3>&nbsp;</FONT> 
  <BR><FONT face=Arial color=blue size=2>Hopefully this is clearer now..</FONT> 
  <BR><FONT face="Times New Roman" size=3>&nbsp;</FONT> <BR><FONT face=Arial 
  color=blue size=2>:)</FONT> <BR><FONT face="Times New Roman" 
  size=3>&nbsp;</FONT> <BR><FONT face=Arial color=blue size=2>Dave</FONT> 
  <BR><FONT face=Tahoma size=2>-----Original Message-----<B><BR>From:</B> Harry 
  Lewis [mailto:harryl@us.ibm.com]<B><BR>Sent:</B> Thursday, September 19, 2002 
  9:22 AM<B><BR>To:</B> HALL,DAVID (HP-Vancouver,ex1)<B><BR>Cc:</B> ps@pwg.org; 
  alan_berkema@hp.com<B><BR>Subject:</B> Throwing exceptions<BR></FONT><BR><FONT 
  face=sans-serif size=2><BR>How to throw an exception form a SOAP method. <BR>I 
  see this in the spec as a question ... "DHall - define exactly how to throw an 
  exception from a SOAP method" section 5.3.1.</FONT><FONT 
  face="Times New Roman" size=3> </FONT><FONT face=sans-serif size=2><BR>Our 
  current definition packages exceptions as a multi XML string parm set in the 
  return. Is this our conscious resolution to PSI exceptions? Have we considered 
  throwing exceptions, independently, across the web services interface? 
  <BR>---------------------------------------------- <BR>Harry Lewis <BR>IBM 
  Printing Systems <BR>---------------------------------------------- 
  </FONT><BR><BR></BLOCKQUOTE></BODY></HTML>