Is this list functional ? I just got a failure notice.
Sree
Hi. This is the qmail-send program at apache.org.
I'm afraid I wasn't able to deliver your message to the
following addresses.
This is a permanent error; I've given up. Sorry it didn't
work out.
<xmlrpc-user xml.apache.org>:
Sorry, no mailbox here by that name. (#5.1.1)
--- Below this line is a copy of the message.
Return-Path: <sreenath tigr.ORG>
Received: (qmail 29724 invoked by uid 99); 15 Aug 2006
16:06:07 -0000
Received: from asf.osuosl.org (HELO asf.osuosl.org)
(140.211.166.49)
by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Aug
2006 09:06:07 -0700
X-ASF-Spam-Status: No, hits=0.5 required=10.0
tests=DNS_FROM_RFC_ABUSE,SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (asf.osuosl.org: domain of sreenath tigr.org
designates 192.207.234.252 as permitted sender)
Received: from [192.207.234.252] (HELO ranger.tigr.org)
(192.207.234.252)
by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Aug
2006 09:06:06 -0700
Received: from EXCHANGE.TIGR.ORG (exch1n [172.17.5.22])
by ranger.tigr.org (8.13.0/8.13.0/Submit) with ESMTP id
k7FG5jRY005026
for <xmlrpc-user xml.apache.org>; Tue, 15 Aug 2006
12:05:45 -0400 (EDT)
Received: from [172.17.123.45] ([172.17.123.45]) by
EXCHANGE.TIGR.ORG with Microsoft SMTPSVC(6.0.3790.1830);
Tue, 15 Aug 2006 12:05:45 -0400
Message-ID: <44E1F0D9.6080102 tigr.org>
Date: Tue, 15 Aug 2006 12:05:45 -0400
From: Sreenath Nampally <sreenath tigr.ORG>
User-Agent: Mozilla Thunderbird 1.0.7 (X11/20050923)
X-Accept-Language: en-us, en
MIME-Version: 1.0
To: xmlrpc-user xml.apache.org
Subject: 'doPost' implemetation of Servlet for xmlrpcv3.0
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-OriginalArrivalTime: 15 Aug 2006 16:05:45.0450 (UTC)
FILETIME=[AA72BCA0:01C6C084]
X-Scanned-By: MIMEDefang 2.57 on 172.20.5.10
X-Virus-Checked: Checked by ClamAV on apache.org
Hello all,
We were using xmlrpc1.2-b1 but we are planning to use a
'timeout'
when executing the 'executeAsync' methods. To do that we
moved to
the latest xmlrpc-3.0, but I got stuck at implementing the
'doPost' and
'doGet' methods for my servlet class (Which is given
below)
Can somebody tell me how will the 'doPost' method from
v1.2-b1
will transfom into v3.0 ? Seems like the 'execute' method
in
XmlRpcServer class do not accept an InputStream any more.
|*execute
<cid:part1.05030407.06050908 tigr.org>*(java.io.InputStream is)
CHANGED TO |
|*execute <cid:part2.01090201.06050502 tigr.org>*(XmlRpcRequest
<cid:part3.08060002.02000504 tigr.org> pRequest)|
XmlRpcServer class.
A sample 'doPost' imlementation code for this change
will help.
Also, is there a way to implement a timeout mechanism in
1.2-b1 ?
Thanks
Sree
------------------------------------------------------------
------------------
public class CommandServlet extends HttpServlet {
private static final long serialVersionUID =
6449353904844527876L;
private XmlRpcServer xmlRpc;
public void init(ServletConfig config) throws
ServletException {
boolean fileHandlesValid = hasMinimumFilehandles();
if (! fileHandlesValid) {
System.out.println("Warning! Check the
hard ulimit setting
for open filehandles!");
}
try {
int maxThreads =
Integer.parseInt(HTCConfig.getProperty("xml.rpc.max.th
reads"));
System.out.println("Setting max threads in
XMLRPC to " +
maxThreads);
xmlRpc = new XmlRpcServer();
xmlRpc.setMaxThreads(maxThreads);
PropertyHandlerMapping phm = new
PropertyHandlerMapping();
//Provide the handler classes directly,
phm.addHandler("HTCServer",
CommandServer.getInstance().getClass());
phm.addHandler("MWServer",
Server.getInstance().getClass());
xmlRpc.setHandlerMapping(phm);
}
catch (Exception x) {
throw new ServletException("Servlet
initialization error: "
+ x.toString ());
}
}
private boolean hasMinimumFilehandles() {
boolean valid = false;
try {
int maxFileHandles =
Ulimit.getMaxOpenFileHandles();
int minimumFileHandles =
Integer.parseInt(HTCConfig.getProperty("minimum.fileha
ndles"));
if (maxFileHandles >= minimumFileHandles) {
valid = true;
}
} catch (Exception e) {
// Ignored. A problem determining the ulimit
should not
cause the service to fail.
}
return valid;
}
public void doPost(HttpServletRequest req,
HttpServletResponse res)
throws ServletException, IOException
{
// Implementation for the old version
byte[] result = xmlRpc.execute(req.getInputStream
());
res.setContentType("text/xml");
res.setContentLength(result.length);
OutputStream output = res.getOutputStream();
output.write(result);
output.flush();
}
public void doGet(HttpServletRequest req,
HttpServletResponse res)
throws ServletException, IOException
{
// Implementation for the old version
byte[] result = xmlRpc.execute(req.getInputStream
());
res.setContentType("text/xml");
res.setContentLength(result.length);
OutputStream output = res.getOutputStream();
output.write(result);
output.flush();
}
------------------------------------------------------------
---------
To unsubscribe, e-mail: xmlrpc-user-unsubscribe ws.apache.org
For additional commands, e-mail: xmlrpc-user-help ws.apache.org |