Hello,
I'm having problems tring to start my tomcat server when I use
implementation.web.
I'm developing a webapp deployed over Tomcat 5.5 server.
In my eclipse buildpath I have added all jars included in release of
tuscany-sca-1.5/lib.
My composite is similar to the example showed in
http://tuscany.apache.org/sca-java-implementationweb.html (links to examples
not works. ie:
https://svn.apache.org/repos/asf/tuscany/java/sca/samples/helloworld-web-callback/.
Where are the correct links?)
<component name="WebClient">
<implementation.web web-uri=""/>
<reference name="service" target="HelloworldService">
<tuscany:binding.dwr />
<callback>
<tuscany:binding.dwr />
</callback>
</reference>
</component>
and my implementation is:
<html>
<head>
<script type="text/javascript"
src="org.osoa.sca.componentContext.js"></script>
<script language="JavaScript">
componentContext.getService("service").sayHelloCallback =
function(reply) {
document.getElementById('result').innerHTML=reply;
};
function callSayHello() {
componentContext.getService("service").sayHello(document.getElementById('name').value);
}
</script>
</head>
<body >
. . .
<input type="text" id="name" width="10">
<button name="submit" onclick="callSayHello()">Say hello</button>
<div id='result'></div>
. . .
</body>
</html>
The problems are:
*Problem 1) *When I start tomcat the log shows:
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
read
ADVERTENCIA: Element
{http://www.osoa.org/xmlns/sca/1.0}implementation.webcannot be
processed. ([row,col {unknown-source}]: [3,5])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
ADVERTENCIA: Element
{http://www.osoa.org/xmlns/sca/1.0}implementation.webcannot be
processed. ([row,col {unknown-source}]: [3,5])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ValidatingXMLStreamReader
GRAVE: XMLSchema validation error occured in: null ,line = 6, column = 5,
Message = cvc-complex-type.2.4.a: Invalid content was found starting with
element 'sca:binding.dwr'. One of
'{"http://www.osoa.org/xmlns/sca/1.0":interface,
"http://www.osoa.org/xmlns/sca/1.0":operation, "
http://www.osoa.org/xmlns/sca/1.0":binding, WC[##other:"
http://www.osoa.org/xmlns/sca/1.0"],
"http://www.osoa.org/xmlns/sca/1.0":callback}'
is expected.
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
read
ADVERTENCIA: Element {http://www.osoa.org/xmlns/sca/1.0}binding.dwr cannot
be processed. ([row,col {unknown-source}]: [6,5])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
ADVERTENCIA: Element {http://www.osoa.org/xmlns/sca/1.0}binding.dwr cannot
be processed. ([row,col {unknown-source}]: [6,5])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
read
ADVERTENCIA: Element callback cannot be processed. ([row,col
{unknown-source}]: [7,9])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
ADVERTENCIA: Element callback cannot be processed. ([row,col
{unknown-source}]: [7,9])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ValidatingXMLStreamReader
GRAVE: XMLSchema validation error occured in: null ,line = 18, column = 5,
Message = UndeclaredPrefix: Cannot resolve 'federation:federacion' as a
QName: the prefix 'federation' is not declared.
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ValidatingXMLStreamReader
GRAVE: XMLSchema validation error occured in: null ,line = 18, column = 5,
Message = cvc-attribute.3: The value 'federation:federacion' of attribute
'name' on element 'sca:implementation.composite' is not valid with respect
to its type, 'QName'.
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
read
ADVERTENCIA: Element
{http://www.osoa.org/xmlns/sca/1.0}implementation.webcannot be
processed. ([row,col {unknown-source}]: [3,5])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
ADVERTENCIA: Element
{http://www.osoa.org/xmlns/sca/1.0}implementation.webcannot be
processed. ([row,col {unknown-source}]: [3,5])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ValidatingXMLStreamReader
GRAVE: XMLSchema validation error occured in: null ,line = 6, column = 5,
Message = cvc-complex-type.2.4.a: Invalid content was found starting with
element 'sca:binding.dwr'. One of
'{"http://www.osoa.org/xmlns/sca/1.0":interface,
"http://www.osoa.org/xmlns/sca/1.0":operation, "
http://www.osoa.org/xmlns/sca/1.0":binding, WC[##other:"
http://www.osoa.org/xmlns/sca/1.0"],
"http://www.osoa.org/xmlns/sca/1.0":callback}'
is expected.
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
read
ADVERTENCIA: Element {http://www.osoa.org/xmlns/sca/1.0}binding.dwr cannot
be processed. ([row,col {unknown-source}]: [6,5])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
ADVERTENCIA: Element {http://www.osoa.org/xmlns/sca/1.0}binding.dwr cannot
be processed. ([row,col {unknown-source}]: [6,5])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
read
ADVERTENCIA: Element callback cannot be processed. ([row,col
{unknown-source}]: [7,9])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor
ADVERTENCIA: Element callback cannot be processed. ([row,col
{unknown-source}]: [7,9])
22/10/2009 23:21:05
org.apache.tuscany.sca.contribution.processor.ValidatingXMLStreamReader
.
.
.
*Problem 2)*
When the page is loaded in the browser and the onclick fires the event I'm
having the error (In error console):
Error: componentContext is not defined
This can be solved resolving problem 1?
Any in this list solved this problems?
Regards,
Sebastián