perfsonar-dev - Re: LS questions
Subject: perfsonar development work
List archive
- From: Maciej Glowiak <>
- To: Herbert Souza <>
- Cc: , , Jeff Boote <>, Perfsonar Development List <>
- Subject: Re: LS questions
- Date: Fri, 23 Feb 2007 16:14:53 +0100
- Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAQMAAABtzGvEAAAABlBMVEUAAAD///+l2Z/dAAAA CXBIWXMAAEU1AABFNQF8gVf5AAAAB3RJTUUH1QYQDjo6uEWvwgAAAM5JREFUGNNN0LFqAkEUheGj KRZsfATrvENgYyH4APabxwgWGUUQC99BsNDCInUq7VImbbDZ0kayxBXMuN7jvTuKVh//mZlmQKZ1 EhQ8GAVgZECspEBdWQHRjR70KlgFKkoUaCw3ijSYQ4n5HfBK4a4jDcdDQPol/80Sr9BxZOOL4Fmr Jq8VBx7eopaSPvWGOm67fqol3j1q0XNs7Nk2cs6MU6gPNzf+ZGKQX4Ek8H6rAnFZnXB2vJxJcv8g C2P+WzL4tD+Txc4KydrIkh+eAdo01QbjQ84vAAAAAElFTkSuQmCC
- Organization: Poznan Supercomputing and Networking Center
Herbert Souza wrote:
Hi Andreas, Martin and Maciej
I would like to know the status of the Multi-LS. I have an old file (.doc)
with the definition of the service; are
there new documents?
In “List of Potential Issues” of Brazil meeting you said this: “LS Proxy
service - service that could translate
symbolic queries to pre-defined XQuery”. I didn’t understand what is “symbolic
queries”. What does “symbolic queries” mean? Recently I made a class called
“proxy.java”, to ease the access to LS, Is it same?. In the attachments you can find
one method of this class that find the service by parameter in "psservice"
tag.
Hi Herbert,
LS Proxy service - that's something we (you and me) were writing about a long time ago. As far as I remember you mentioned that a set of pre-defined queries to the LS should be established - in order to avoid making XQuery expressions. Then you wanted to do it inside LS, but it'd limit the functionality of the LS, so I didn't agree.
Then the topic returned during the perfSONAR Meeting in Ann Arbor in April 2006 (it was mentioned and discussed a bit by Jeff, Fausto and me).
Finally, I decided to put it into the agenda, because it could help client developers (and other service programmers) to develop their application in easier way.
"symbolic queries to pre-defined XQuery" means:
Communication
client ----> LS Proxy -----> LS
client <----(LS Proxy)<----- LS
client sends for example:
--------------------------------------------------------
query: give_metadata_for
parameter: serviceType=MA
--------------------------------------------------------
/of course that's an example and the query 'language' may be different but 'give_metadata_for' means predefined query such as:/
which will be translated to:
--------------------------------------------------------
declare namespace nmwg = http://....;
declare namespace psservice = http://....;
for i in /nmwg:store[type='LSStore']/nmwg:metadata
let $s:=$i/nmwg:subject/psservice:service
where $s/psservice:serviceType = 'MA'
return $i;
--------------------------------------------------------
and sent to LS.
Maciej
In attachment you can also find a document
(UDDI_DOC.doc) with my UDDI experience, where I made an adaptation in the use
of the UDDI to interoperate with perfSONAR. This development has an initial
version, but it still with some errors and it isn´t in conformance with the
NMWG
messages at all (like the ID).
I hope
that this work to contribute with the LS or in the development of the
Multi-LS.
I´m also waiting for comments about this document attached.
thanks for all.
public Document find_psservice(String accessPoint, String psservice, String
parameter) throws SystemException{
Document result = null;
try{
String query = "declare namespace nmwg=\"http://ggf.org/ns/nmwg/base/2.0/\";\n"+
"declare namespace
perfsonar=\"http://ggf.org/ns/nmwg/tools/org/perfsonar/1.0/\";\n"+
"declare namespace
psservice=\"http://ggf.org/ns/nmwg/tools/org/perfsonar/service/1.0/\";\n"+
"declare namespace xquery=\"http://ggf.org/ns/nmwg/tools/org/perfsonar/service/lookup/xquery/1.0/\";\n"+
"for $x in
/nmwg:store/nmwg:metadata/perfsonar:subject/psservice:service\n"+
"where contains($x/psservice:"+psservice+",
\""+parameter+"\")\n"+
"return $x\n";
LSQueryRequestGenerator queryRequest = new LSQueryRequestGenerator(query,"service.lookup.xquery");
Service service = new Service(); Call call = (Call)service.createCall();
call.setTargetEndpointAddress(new URL(accessPoint));
call.setOperationName(new
QName("http://soapinterop.org/","submit"));
Message Mem = queryRequest.generateRequest();
//convert response Message into Document
Document responseDocument = XMLUtils.
convertMessageToDOM( Mem );
//build a SOAPBodyElement from the document
//printXML(responseDocument);
SOAPBodyElement requestMessage = new SOAPBodyElement(responseDocument.getDocumentElement());
//call on the end point Object resultObject = call.invoke(new Object[] {requestMessage}); //get the document
SOAPBodyElement resultSBE;
resultSBE = (SOAPBodyElement)((Vector)resultObject).get(0);
//set result
result = resultSBE.getAsDocument();
printXML(result);
}catch(Exception e) {
System.out.println("Proxy " +e);
}
return result;
}
-------------------------------
Herbert Monteiro Souza
Cel Phone: +5571 88029549
Phone: +5571 33304658
-------------------------------
UNIFACS - UNIVERSIDADE SALVADOR
-------------------------------
NUPERC - NÚCLEO DE PESQUISA EM
REDES DE COMPUTADORES
-------------------------------
__________________________________________________
Fale com seus amigos de graça com o novo Yahoo! Messenger http://br.messenger.yahoo.com/
- Re: LS questions, Maciej Glowiak, 02/23/2007
Archive powered by MHonArc 2.6.16.