tuscany-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antonio De Berardis <antonio.de-berar...@aps-prevoyance.fr>
Subject Re: Default WS port - Tuscany 2 runtime
Date Thu, 24 Nov 2011 15:22:30 GMT
Le 24/11/2011 15:28, Simon Laws a écrit :
> On Thu, Nov 24, 2011 at 10:57 AM, Antonio De Berardis
> <antonio.de-berardis@aps-prevoyance.fr>  wrote:
>> Hi,
>>
>> I have a question about web service binding, for example:
>>
>> <component name="HelloworldComponent">
>>      <implementation.java class="sample.HelloworldImpl"/>
>>      <service name="Helloworld">
>>          <binding.ws/>
>>      </service>
>> </component>
>>
>> When I deploy this component in a webapp on Tomcat, It publishes a service
>> at http://localhost:8085/HelloworldComponent/Helloworld. The
>> “localhost:8085” seems to be a default value.
>>
>> I actually have lots of Tuscany based webapps with many components in them,
>> therefore all publishing their webservices at http://localhost:8085/...
>>
>> One way to change that is to set the uri attribute in binding.ws. , which
>> means that if I want to relocate my webservices in the future I will have to
>> change the URI in each and every one of my webapps.
>>
>> Is there a way to set a default "Host:Port"? I'm using the tuscany.war
>> deployed on Tomcat, is there may be a way to do this in the Tomcat’s conf or
>> in Tuscany.war?
>> Or if not, what do you think is better to do? Let binding.ws with no URI or
>> define it in each WS? Am I missing something? Are you planning to change
>> this behavior?
>>
>> Best Regards.
>>
>> Antonio
>>
> Hi Antonio
>
> I assume that you're embedding Tuscany in the WAR and configuring the
> TuscanyServletFilter.
>
> I think in a webapp Tuscany just adopts the host:port configuration of
> the host Tomcat installation.
>
> If you're running outside of Tomcat from a Tuscany launcher you can
> configure the default port that gets used when fluffing up Tomcat or
> Jetty etc instances by providing default binding configuration to the
> node. But I don't think that's what you're doing.
>
> Regards
>
> Simon
>
Hi Simon,

I'm using the tuscany-war-2.0-Beta3.war deployed in Tomcat; It's this 
war that configures the TuscanyServletFilter for each webapp.

Here is my log when I start Tomcat:

WARN: [SetPropertiesRule]{Server/Service/Engine/Host} Setting property 
'hostConfigClass' to 'org.apache.tuscany.sca.tomcat.TuscanyHostConfig' 
did not find a matching property.
24 nov. 2011 15:49:52 
org.apache.tuscany.sca.tomcat.TuscanyLifecycleListener lifecycleEvent
INFO: Using Tuscany webapp: 
/test/tuscany-tomcat-6.0.32/webapps/tuscany-war-2.0-Beta3
24 nov. 2011 15:49:52 
org.apache.tuscany.sca.tomcat.TuscanyLifecycleListener lifecycleEvent
INFO: Tuscany enabled on connector: localhost:8080
24 nov. 2011 15:49:52 
org.apache.tuscany.sca.tomcat.TuscanyLifecycleListener lifecycleEvent
INFO: Tuscany enabled on connector: localhost:8009
24 nov. 2011 15:49:52 org.apache.coyote.http11.Http11Protocol init
INFO: Initialisation de Coyote HTTP/1.1 sur http-8080
24 nov. 2011 15:49:52 org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 417 ms
24 nov. 2011 15:49:52 org.apache.catalina.core.StandardService start
INFO: Démarrage du service Catalina
24 nov. 2011 15:49:52 org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.32
24 nov. 2011 15:49:52 org.apache.catalina.startup.HostConfig 
deployDescriptor
INFO: Déploiement du descripteur de configuration manager.xml
24 nov. 2011 15:49:53 org.apache.catalina.startup.HostConfig 
deployDescriptor
INFO: Déploiement du descripteur de configuration host-manager.xml
24 nov. 2011 15:49:53 org.apache.catalina.startup.HostConfig deployWAR

INFO: Déploiement de l'archive tuscany-war-2.0-Beta3.war de 
l'application web
24 nov. 2011 15:49:53 org.apache.catalina.startup.HostConfig 
deployDirectory
INFO: Déploiement du répertoire ROOT de l'application web
24 nov. 2011 15:49:53 org.apache.catalina.startup.HostConfig 
deployDirectory
INFO: Déploiement du répertoire docs de l'application web
24 nov. 2011 15:49:53 org.apache.catalina.startup.HostConfig 
deployDirectory
INFO: Déploiement du répertoire examples de l'application web
24 nov. 2011 15:49:53 org.apache.coyote.http11.Http11Protocol start
INFO: Démarrage de Coyote HTTP/1.1 sur http-8080
24 nov. 2011 15:49:53 org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8009
24 nov. 2011 15:49:53 org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=1/15  config=null
24 nov. 2011 15:49:53 org.apache.catalina.startup.Catalina start
INFO: Server startup in 576 ms
24 nov. 2011 15:50:13 org.apache.catalina.startup.HostConfig deployWAR
INFO: Déploiement de l'archive _TestSCA.war de l'application web
24 nov. 2011 15:50:13 org.apache.tuscany.sca.node.impl.NodeImpl start
INFO: Starting node: http://tuscany.apache.org/sca/1.1/nodes/default0 
domain: default
24 nov. 2011 15:50:14 
org.apache.tuscany.sca.tomcat.TuscanyStandardContext enableTuscany
INFO: Tuscany SCA is enabled for: /_TestSCA
24 nov. 2011 15:50:14 
org.apache.tuscany.sca.host.webapp.TuscanyContextListener 
contextInitialized
INFO: _TestSCA is starting.
24 nov. 2011 15:50:14 
org.apache.tuscany.sca.host.webapp.WebAppServletHost initContextPath
INFO: ContextPath: /_TestSCA
24 nov. 2011 15:50:14 org.apache.tuscany.sca.node.impl.NodeImpl start
INFO: Starting node: /test/tuscany-tomcat-6.0.32/webapps/_TestSCA/ 
domain: default
24 nov. 2011 15:50:14 org.apache.tuscany.sca.node.impl.NodeFactoryImpl 
loadContributions
INFO: Loading contribution: 
file:/test/tuscany-tomcat-6.0.32/webapps/_TestSCA/
Binding.ws JAXWS provider - Service URI: 
http://localhost:8085/TestComponent/TestService
Binding.ws JAXWS provider - Service URI: 
http://localhost:8085/Test2Component/Test2Service
24 nov. 2011 15:50:15 
org.apache.tuscany.sca.core.assembly.impl.DomainRegistryImpl addEndpoint
INFO: Add endpoint - binding.ws - 
http://localhost:8085/TestComponent/TestService
24 nov. 2011 15:50:15 
org.apache.tuscany.sca.core.assembly.impl.DomainRegistryImpl addEndpoint
INFO: Add endpoint - binding.ws - 
http://localhost:8085/Test2Component/Test2Service

Mime
View raw message