You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Saminda Abeyruwan <sa...@gmail.com> on 2007/03/30 18:04:00 UTC

[Axis2] using policy references in services.xml

Forwared with Axis2 prefix


Hi All,
I need to use policy references in services.xml,
meaning that i do not need the actual policy info but a reference to it,
so if i want to change the policy, i should not deal with services.xml but
rather with the resource behind that uri, for example:

<service >
<operation name="echo">
  <messageReceiver class="org.apache.axis2.rpc.receivers.RPCMessageReceiver
"/>
</operation>
<parameter name="ServiceClass" locked="false">
org.apache.rampart.samples.policy.sample01.SimpleService</parameter>

<module ref="rampart" />
<module ref="addressing" />

<wsp:PolicyReference wsu:Id="UTOverTransport"
                xmlns:wsu="
http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
"
                xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"
                URI="http://localhost:53307/policy.xml#UTOverTransport" />
</service>

Is that achievable in axis2 ?
Thanks.

-

-- 
Saminda Abeyruwan

Software Engineer
WSO2 Inc. - www.wso2.org

Re: [Axis2] using policy references in services.xml

Posted by Ruchith Fernando <ru...@gmail.com>.
Hi,

Right now rampart policy samples demonstrates the case where policy it
self is specified in the services.xml file. However rampart simply
picks up the effective policy from the message context using
getEffectivePolicy(). Therefore once we have this mechanism
implemented we should be able to add such a sample where we just have
a reference to the policy in the services.xml rather than the policy
itself.

Thanks,
Ruchith

On 4/2/07, Davanum Srinivas <da...@gmail.com> wrote:
> Sanka, Ruchith,
>
> Does rampart pick it up as well? We should definitely have a
> (rampart?) sample where one writes a pojo and adds a policy in the
> services.xml (if we don't have one already).
>
> thanks,
> dims
>
> On 4/2/07, Sanka Samaranayake <ss...@gmail.com> wrote:
> >
> >
> > On 4/2/07, Nencho Lupanov <ne...@googlemail.com> wrote:
> > >
> > > Hi Sanka, can i use a statement like this in services.xml :
> > >
> > >
> > >
> > > <wsp:PolicyReference URI=
> > http://localhost/policy.xml#UTOverTransport />
> > >
> > > ,meaning that my actual policy expression resides in the policy.xml file
> > referenced in the URI attribute.
> > >
> > > Can you deliver a working example of services.xml using policy references
> > wheater at service or operation scope, since this does not work for me ?
> >
> >
> >  Yes ..  Will do prior to Axis1.2 release.
> >
> >  Please Log a JIRA so that I can follow.
> >
> >  Thanks,
> >  Sanka
> >
> > >
> > >
> > >
> > > Thanks.
> > >
> > >
> > >
> > >
> > > 2007/4/2, Sanka Samaranayake <ss...@gmail.com>:
> > >
> > > > This is available at the moment. AxisService should contain those
> > policies that are declared at the service scope in the services.xml ( in the
> > AxisOperation if the policy is declared in the operation scope .. etc.)
> > > >
> > > > Thanks,
> > > > Sanka
> > > >
> > > >
> > > >
> > > > On 4/2/07, Sanjiva Weerawarana <sanjiva@opensource.lk > wrote:
> > > > > I think we need to do the attachment work for services.xml too ... I'm
> > > > > definitely +1 for it.
> > > > >
> > > > > Sanka?
> > > > >
> > > > > Sanjiva.
> > > > >
> > > > > Saminda Abeyruwan wrote:
> > > > > > Forwared with Axis2 prefix
> > > > > >
> > > > > >
> > > > > > Hi All,
> > > > > > I need to use policy references in services.xml,
> > > > > > meaning that i do not need the actual policy info but a reference to
> > it,
> > > > > > so if i want to change the policy, i should not deal with
> > services.xml but
> > > > > > rather with the resource behind that uri, for example:
> > > > > >
> > > > > > <service >
> > > > > > <operation name="echo">
> > > > > >   <messageReceiver
> > > > > >
> > class="org.apache.axis2.rpc.receivers.RPCMessageReceiver
> > "/>
> > > > > > </operation>
> > > > > > <parameter name="ServiceClass"
> > > > > > locked="false">
> > org.apache.rampart.samples.policy.sample01.SimpleService</parameter>
> > > > > >
> > > > > > <module ref="rampart" />
> > > > > > <module ref="addressing" />
> > > > > >
> > > > > > <wsp:PolicyReference wsu:Id="UTOverTransport"
> > > > > >                 xmlns:wsu="
> > > > > >
> > http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
> > "
> > > > > >
> > xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy
> > > > > > <http://schemas.xmlsoap.org/ws/2004/09/policy >"
> > > > > >                 URI="
> > http://localhost:53307/policy.xml#UTOverTransport" />
> > > > > > </service>
> > > > > >
> > > > > > Is that achievable in axis2 ?
> > > > > > Thanks.
> > > > > >
> > > > > > -
> > > > > >
> > > > > > --
> > > > > > Saminda Abeyruwan
> > > > > >
> > > > > > Software Engineer
> > > > > > WSO2 Inc. - www.wso2.org <http://www.wso2.org >
> > > > >
> > > > > --
> > > > > Sanjiva Weerawarana, Ph.D.
> > > > > Founder & Director; Lanka Software Foundation;
> > http://www.opensource.lk/
> > > > > Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
> > > > > Director; Open Source Initiative; http://www.opensource.org/
> > > > > Member; Apache Software Foundation; http://www.apache.org/
> > > > > Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
> > > > >
> > > > >
> > ---------------------------------------------------------------------
> > > > > To unsubscribe, e-mail:
> > axis-dev-unsubscribe@ws.apache.org
> > > > > For additional commands, e-mail: axis-dev-help@ws.apache.org
> > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Sanka Samaranayake
> > > > WSO2 Inc.
> > > >
> > > > http://sankas.blogspot.com/
> > > > http://www.wso2.org/
> > >
> > >
> >
> >
> >
> > --
> > Sanka Samaranayake
> > WSO2 Inc.
> >
> > http://sankas.blogspot.com/
> > http://www.wso2.org/
>
>
> --
> Davanum Srinivas :: http://wso2.org/ :: Oxygen for Web Services Developers
>


-- 
www.ruchith.org
www.wso2.org

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] using policy references in services.xml

Posted by Davanum Srinivas <da...@gmail.com>.
Sanka, Ruchith,

Does rampart pick it up as well? We should definitely have a
(rampart?) sample where one writes a pojo and adds a policy in the
services.xml (if we don't have one already).

thanks,
dims

On 4/2/07, Sanka Samaranayake <ss...@gmail.com> wrote:
>
>
> On 4/2/07, Nencho Lupanov <ne...@googlemail.com> wrote:
> >
> > Hi Sanka, can i use a statement like this in services.xml :
> >
> >
> >
> > <wsp:PolicyReference URI=
> http://localhost/policy.xml#UTOverTransport />
> >
> > ,meaning that my actual policy expression resides in the policy.xml file
> referenced in the URI attribute.
> >
> > Can you deliver a working example of services.xml using policy references
> wheater at service or operation scope, since this does not work for me ?
>
>
>  Yes ..  Will do prior to Axis1.2 release.
>
>  Please Log a JIRA so that I can follow.
>
>  Thanks,
>  Sanka
>
> >
> >
> >
> > Thanks.
> >
> >
> >
> >
> > 2007/4/2, Sanka Samaranayake <ss...@gmail.com>:
> >
> > > This is available at the moment. AxisService should contain those
> policies that are declared at the service scope in the services.xml ( in the
> AxisOperation if the policy is declared in the operation scope .. etc.)
> > >
> > > Thanks,
> > > Sanka
> > >
> > >
> > >
> > > On 4/2/07, Sanjiva Weerawarana <sanjiva@opensource.lk > wrote:
> > > > I think we need to do the attachment work for services.xml too ... I'm
> > > > definitely +1 for it.
> > > >
> > > > Sanka?
> > > >
> > > > Sanjiva.
> > > >
> > > > Saminda Abeyruwan wrote:
> > > > > Forwared with Axis2 prefix
> > > > >
> > > > >
> > > > > Hi All,
> > > > > I need to use policy references in services.xml,
> > > > > meaning that i do not need the actual policy info but a reference to
> it,
> > > > > so if i want to change the policy, i should not deal with
> services.xml but
> > > > > rather with the resource behind that uri, for example:
> > > > >
> > > > > <service >
> > > > > <operation name="echo">
> > > > >   <messageReceiver
> > > > >
> class="org.apache.axis2.rpc.receivers.RPCMessageReceiver
> "/>
> > > > > </operation>
> > > > > <parameter name="ServiceClass"
> > > > > locked="false">
> org.apache.rampart.samples.policy.sample01.SimpleService</parameter>
> > > > >
> > > > > <module ref="rampart" />
> > > > > <module ref="addressing" />
> > > > >
> > > > > <wsp:PolicyReference wsu:Id="UTOverTransport"
> > > > >                 xmlns:wsu="
> > > > >
> http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
> "
> > > > >
> xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy
> > > > > <http://schemas.xmlsoap.org/ws/2004/09/policy >"
> > > > >                 URI="
> http://localhost:53307/policy.xml#UTOverTransport" />
> > > > > </service>
> > > > >
> > > > > Is that achievable in axis2 ?
> > > > > Thanks.
> > > > >
> > > > > -
> > > > >
> > > > > --
> > > > > Saminda Abeyruwan
> > > > >
> > > > > Software Engineer
> > > > > WSO2 Inc. - www.wso2.org <http://www.wso2.org >
> > > >
> > > > --
> > > > Sanjiva Weerawarana, Ph.D.
> > > > Founder & Director; Lanka Software Foundation;
> http://www.opensource.lk/
> > > > Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
> > > > Director; Open Source Initiative; http://www.opensource.org/
> > > > Member; Apache Software Foundation; http://www.apache.org/
> > > > Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
> > > >
> > > >
> ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail:
> axis-dev-unsubscribe@ws.apache.org
> > > > For additional commands, e-mail: axis-dev-help@ws.apache.org
> > > >
> > > >
> > >
> > >
> > >
> > > --
> > > Sanka Samaranayake
> > > WSO2 Inc.
> > >
> > > http://sankas.blogspot.com/
> > > http://www.wso2.org/
> >
> >
>
>
>
> --
> Sanka Samaranayake
> WSO2 Inc.
>
> http://sankas.blogspot.com/
> http://www.wso2.org/


-- 
Davanum Srinivas :: http://wso2.org/ :: Oxygen for Web Services Developers

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: [Axis2] using policy references in services.xml

Posted by Nencho Lupanov <ne...@googlemail.com>.
Hi Sanka,

I am using axis2 version 1.1.1 ,  I am not able to use policy references
like that in services.xml:


<?xml version="1.0" encoding="UTF-8"?><service
xmlns:wsu="
http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"

xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"
xmlns:wsa="http://www.w3.org/2005/08/addressing">

<operation name="echo">
  <messageReceiver
class="org.apache.axis2.rpc.receivers.RPCMessageReceiver"/>

 </operation>
 <parameter name="ServiceClass" locked="false">
org.apache.rampart.samples.policy.sample01.SimpleService</parameter>

 <!-- <parameter name="useOriginalwsdl">true</parameter>  -->

 <module ref="rampart" />
 <module ref="addressing" />
<wsp:PolicyReference wsu:Id="UTOverTransport"
              URI="http://localhost:53307/policy.xml#UTOverTransport" />

</service>

Note that i am using a working rampart sample - the policy sample01, so i
just replaced the actual policy info with a reference to it , which of
cource is available and acessible http uri.Nevetheless, i get the following
error message when i try to invoke the client:

     [java] INFO: Deploying module : addressing-1.1
     [java] 2007-4-3 15:02:21 org.apache.axis2.deployment.DeploymentEngine
            doDeploy
     [java] INFO: Deploying module : rampart-1.1
     [java] Exception in thread "main" org.apache.axis2.AxisFault:
            java.lang.RuntimeException:
http://localhost:53307/policy.xml#UTOverTransport
            can't be resolved
     [java]     at
org.apache.axis2.description.OutInAxisOperationClient.send
            (OutInAxisOperation.java:271)
     [java]     at
org.apache.axis2.description.OutInAxisOperationClient.execute
            (OutInAxisOperation.java:202)
     [java]     at org.apache.axis2.client.ServiceClient.sendReceive
            (ServiceClient.java:579)
     [java]     at org.apache.axis2.client.ServiceClient.sendReceive
            (ServiceClient.java:508)
     [java]     at org.apache.rampart.samples.policy.sample01.Client.main
            (Unknown Source)
     [java] Java Result: 1

Note again, that i alredy check several times that the uri is acessible from
my browser.So, If we summaries - this policy is not available due to version
1.1.1 but will be available in version 1.2. Is that so? If it is available,
can you provide a sample services.xml , please?

Thanks!

>
>
> On 4/2/07, Nencho Lupanov <ne...@googlemail.com> wrote:
> >
> > Hi Sanka, can i use a statement like this in services.xml :
> >
> >
> > <
> > wsp:PolicyReference URI= http://localhost/policy.xml#UTOverTransport />
> >
> > ,meaning that my actual policy expression resides in the policy.xml file
> > referenced in the URI attribute.
> >
> > Can you deliver a working example of services.xml using policy
> > references wheater at service or operation scope, since this does not work
> > for me ?
> >
>
>
> Yes ..  Will do prior to Axis1.2 release.
>
> Please Log a JIRA so that I can follow.
>
> Thanks,
> Sanka
>
>  Thanks.
> >
> >
> >
> >
> > 2007/4/2, Sanka Samaranayake <ss...@gmail.com>:
> > >
> > > This is available at the moment. AxisService should contain those
> > > policies that are declared at the service scope in the services.xml (
> > > in the AxisOperation if the policy is declared in the operation scope ..
> > > etc.)
> > >
> > > Thanks,
> > > Sanka
> > >
> > > On 4/2/07, Sanjiva Weerawarana <sanjiva@opensource.lk > wrote:
> > > >
> > > > I think we need to do the attachment work for services.xml too ...
> > > > I'm
> > > > definitely +1 for it.
> > > >
> > > > Sanka?
> > > >
> > > > Sanjiva.
> > > >
> > > > Saminda Abeyruwan wrote:
> > > > > Forwared with Axis2 prefix
> > > > >
> > > > >
> > > > > Hi All,
> > > > > I need to use policy references in services.xml,
> > > > > meaning that i do not need the actual policy info but a reference
> > > > to it,
> > > > > so if i want to change the policy, i should not deal with
> > > > services.xml but
> > > > > rather with the resource behind that uri, for example:
> > > > >
> > > > > <service >
> > > > > <operation name="echo">
> > > > >   <messageReceiver
> > > > > class="org.apache.axis2.rpc.receivers.RPCMessageReceiver "/>
> > > > > </operation>
> > > > > <parameter name="ServiceClass"
> > > > > locked="false">
> > > > org.apache.rampart.samples.policy.sample01.SimpleService</parameter>
> > > > >
> > > > > <module ref="rampart" />
> > > > > <module ref="addressing" />
> > > > >
> > > > > <wsp:PolicyReference wsu:Id="UTOverTransport"
> > > > >                 xmlns:wsu="
> > > > > http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
> > > > "
> > > > >                 xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy
> > > >
> > > > > <http://schemas.xmlsoap.org/ws/2004/09/policy >"
> > > > >                 URI="
> > > > http://localhost:53307/policy.xml#UTOverTransport" />
> > > > > </service>
> > > > >
> > > > > Is that achievable in axis2 ?
> > > > > Thanks.
> > > > >
> > > > > -
> > > > >
> > > > > --
> > > > > Saminda Abeyruwan
> > > > >
> > > > > Software Engineer
> > > > > WSO2 Inc. - www.wso2.org <http://www.wso2.org >
> > > >
> > > > --
> > > > Sanjiva Weerawarana, Ph.D.
> > > > Founder & Director; Lanka Software Foundation;
> > > > http://www.opensource.lk/
> > > > Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
> > > > Director; Open Source Initiative; http://www.opensource.org/
> > > > Member; Apache Software Foundation; http://www.apache.org/
> > > > Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
> > > >
> > > >
> > > > ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> > > > For additional commands, e-mail: axis-dev-help@ws.apache.org
> > > >
> > > >
> > >
> > >
> > > --
> > > Sanka Samaranayake
> > > WSO2 Inc.
> > >
> > > http://sankas.blogspot.com/
> > > http://www.wso2.org/
> >
> >
> >
>
>
> --
> Sanka Samaranayake
> WSO2 Inc.
>
> http://sankas.blogspot.com/
> http://www.wso2.org/
>

Re: [Axis2] using policy references in services.xml

Posted by Sanka Samaranayake <ss...@gmail.com>.
On 4/2/07, Nencho Lupanov <ne...@googlemail.com> wrote:
>
> Hi Sanka, can i use a statement like this in services.xml :
>
>
> <
> wsp:PolicyReference URI=http://localhost/policy.xml#UTOverTransport />
>
> ,meaning that my actual policy expression resides in the policy.xml file
> referenced in the URI attribute.
>
> Can you deliver a working example of services.xml using policy references
> wheater at service or operation scope, since this does not work for me ?
>


Yes ..  Will do prior to Axis1.2 release.

Please Log a JIRA so that I can follow.

Thanks,
Sanka

Thanks.
>
>
>
>
> 2007/4/2, Sanka Samaranayake <ss...@gmail.com>:
> >
> > This is available at the moment. AxisService should contain those
> > policies that are declared at the service scope in the services.xml ( in
> > the AxisOperation if the policy is declared in the operation scope .. etc.)
> >
> > Thanks,
> > Sanka
> >
> > On 4/2/07, Sanjiva Weerawarana <sanjiva@opensource.lk > wrote:
> > >
> > > I think we need to do the attachment work for services.xml too ... I'm
> > > definitely +1 for it.
> > >
> > > Sanka?
> > >
> > > Sanjiva.
> > >
> > > Saminda Abeyruwan wrote:
> > > > Forwared with Axis2 prefix
> > > >
> > > >
> > > > Hi All,
> > > > I need to use policy references in services.xml,
> > > > meaning that i do not need the actual policy info but a reference to
> > > it,
> > > > so if i want to change the policy, i should not deal with
> > > services.xml but
> > > > rather with the resource behind that uri, for example:
> > > >
> > > > <service >
> > > > <operation name="echo">
> > > >   <messageReceiver
> > > > class="org.apache.axis2.rpc.receivers.RPCMessageReceiver "/>
> > > > </operation>
> > > > <parameter name="ServiceClass"
> > > > locked="false">
> > > org.apache.rampart.samples.policy.sample01.SimpleService</parameter>
> > > >
> > > > <module ref="rampart" />
> > > > <module ref="addressing" />
> > > >
> > > > <wsp:PolicyReference wsu:Id="UTOverTransport"
> > > >                 xmlns:wsu="
> > > > http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
> > > "
> > > >                 xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy
> > >
> > > > <http://schemas.xmlsoap.org/ws/2004/09/policy >"
> > > >                 URI="
> > > http://localhost:53307/policy.xml#UTOverTransport" />
> > > > </service>
> > > >
> > > > Is that achievable in axis2 ?
> > > > Thanks.
> > > >
> > > > -
> > > >
> > > > --
> > > > Saminda Abeyruwan
> > > >
> > > > Software Engineer
> > > > WSO2 Inc. - www.wso2.org <http://www.wso2.org >
> > >
> > > --
> > > Sanjiva Weerawarana, Ph.D.
> > > Founder & Director; Lanka Software Foundation;
> > > http://www.opensource.lk/
> > > Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
> > > Director; Open Source Initiative; http://www.opensource.org/
> > > Member; Apache Software Foundation; http://www.apache.org/
> > > Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> > > For additional commands, e-mail: axis-dev-help@ws.apache.org
> > >
> > >
> >
> >
> > --
> > Sanka Samaranayake
> > WSO2 Inc.
> >
> > http://sankas.blogspot.com/
> > http://www.wso2.org/
>
>
>


-- 
Sanka Samaranayake
WSO2 Inc.

http://sankas.blogspot.com/
http://www.wso2.org/

Re: [Axis2] using policy references in services.xml

Posted by Nencho Lupanov <ne...@googlemail.com>.
Hi Sanka, can i use a statement like this in services.xml :


<wsp:PolicyReference URI=http://localhost/policy.xml#UTOverTransport />

,meaning that my actual policy expression resides in the policy.xml file
referenced in the URI attribute.

Can you deliver a working example of services.xml using policy references
wheater at service or operation scope, since this does not work for me ?

Thanks.




2007/4/2, Sanka Samaranayake <ss...@gmail.com>:
>
> This is available at the moment. AxisService should contain those policies
> that are declared at the service scope in the services.xml ( in the
> AxisOperation if the policy is declared in the operation scope .. etc.)
>
> Thanks,
> Sanka
>
> On 4/2/07, Sanjiva Weerawarana <sa...@opensource.lk> wrote:
> >
> > I think we need to do the attachment work for services.xml too ... I'm
> > definitely +1 for it.
> >
> > Sanka?
> >
> > Sanjiva.
> >
> > Saminda Abeyruwan wrote:
> > > Forwared with Axis2 prefix
> > >
> > >
> > > Hi All,
> > > I need to use policy references in services.xml,
> > > meaning that i do not need the actual policy info but a reference to
> > it,
> > > so if i want to change the policy, i should not deal with services.xmlbut
> > > rather with the resource behind that uri, for example:
> > >
> > > <service >
> > > <operation name="echo">
> > >   <messageReceiver
> > > class="org.apache.axis2.rpc.receivers.RPCMessageReceiver "/>
> > > </operation>
> > > <parameter name="ServiceClass"
> > > locked="false">
> > org.apache.rampart.samples.policy.sample01.SimpleService</parameter>
> > >
> > > <module ref="rampart" />
> > > <module ref="addressing" />
> > >
> > > <wsp:PolicyReference wsu:Id="UTOverTransport"
> > >                 xmlns:wsu="
> > >
> > http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
> > "
> > >                 xmlns:wsp="
> > http://schemas.xmlsoap.org/ws/2004/09/policy
> > > <http://schemas.xmlsoap.org/ws/2004/09/policy >"
> > >                 URI="http://localhost:53307/policy.xml#UTOverTransport"
> > />
> > > </service>
> > >
> > > Is that achievable in axis2 ?
> > > Thanks.
> > >
> > > -
> > >
> > > --
> > > Saminda Abeyruwan
> > >
> > > Software Engineer
> > > WSO2 Inc. - www.wso2.org <http://www.wso2.org >
> >
> > --
> > Sanjiva Weerawarana, Ph.D.
> > Founder & Director; Lanka Software Foundation; http://www.opensource.lk/
> > Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
> > Director; Open Source Initiative; http://www.opensource.org/
> > Member; Apache Software Foundation; http://www.apache.org/
> > Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-dev-help@ws.apache.org
> >
> >
>
>
> --
> Sanka Samaranayake
> WSO2 Inc.
>
> http://sankas.blogspot.com/
> http://www.wso2.org/

Re: [Axis2] using policy references in services.xml

Posted by Sanka Samaranayake <ss...@gmail.com>.
If you are attaching a Policy as a PolicyReference, the actual policy should
either be a declared in the services.xml or the reference should be resolved
to a actual URL.

Thanks,
Sanka

On 4/2/07, Sanka Samaranayake <ss...@gmail.com> wrote:
>
> This is available at the moment. AxisService should contain those policies
> that are declared at the service scope in the services.xml ( in the
> AxisOperation if the policy is declared in the operation scope .. etc.)
>
> Thanks,
> Sanka
>
> On 4/2/07, Sanjiva Weerawarana <sa...@opensource.lk> wrote:
> >
> > I think we need to do the attachment work for services.xml too ... I'm
> > definitely +1 for it.
> >
> > Sanka?
> >
> > Sanjiva.
> >
> > Saminda Abeyruwan wrote:
> > > Forwared with Axis2 prefix
> > >
> > >
> > > Hi All,
> > > I need to use policy references in services.xml,
> > > meaning that i do not need the actual policy info but a reference to
> > it,
> > > so if i want to change the policy, i should not deal with services.xmlbut
> > > rather with the resource behind that uri, for example:
> > >
> > > <service >
> > > <operation name="echo">
> > >   <messageReceiver
> > > class="org.apache.axis2.rpc.receivers.RPCMessageReceiver "/>
> > > </operation>
> > > <parameter name="ServiceClass"
> > > locked="false">
> > org.apache.rampart.samples.policy.sample01.SimpleService</parameter>
> > >
> > > <module ref="rampart" />
> > > <module ref="addressing" />
> > >
> > > <wsp:PolicyReference wsu:Id="UTOverTransport"
> > >                 xmlns:wsu="
> > >
> > http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
> > "
> > >                 xmlns:wsp="
> > http://schemas.xmlsoap.org/ws/2004/09/policy
> > > <http://schemas.xmlsoap.org/ws/2004/09/policy >"
> > >                 URI="http://localhost:53307/policy.xml#UTOverTransport"
> > />
> > > </service>
> > >
> > > Is that achievable in axis2 ?
> > > Thanks.
> > >
> > > -
> > >
> > > --
> > > Saminda Abeyruwan
> > >
> > > Software Engineer
> > > WSO2 Inc. - www.wso2.org <http://www.wso2.org >
> >
> > --
> > Sanjiva Weerawarana, Ph.D.
> > Founder & Director; Lanka Software Foundation; http://www.opensource.lk/
> > Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
> > Director; Open Source Initiative; http://www.opensource.org/
> > Member; Apache Software Foundation; http://www.apache.org/
> > Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-dev-help@ws.apache.org
> >
> >
>
>
> --
> Sanka Samaranayake
> WSO2 Inc.
>
> http://sankas.blogspot.com/
> http://www.wso2.org/




-- 
Sanka Samaranayake
WSO2 Inc.

http://sankas.blogspot.com/
http://www.wso2.org/

Re: [Axis2] using policy references in services.xml

Posted by Sanka Samaranayake <ss...@gmail.com>.
This is available at the moment. AxisService should contain those policies
that are declared at the service scope in the services.xml ( in the
AxisOperation if the policy is declared in the operation scope .. etc.)

Thanks,
Sanka

On 4/2/07, Sanjiva Weerawarana <sa...@opensource.lk> wrote:
>
> I think we need to do the attachment work for services.xml too ... I'm
> definitely +1 for it.
>
> Sanka?
>
> Sanjiva.
>
> Saminda Abeyruwan wrote:
> > Forwared with Axis2 prefix
> >
> >
> > Hi All,
> > I need to use policy references in services.xml,
> > meaning that i do not need the actual policy info but a reference to it,
> > so if i want to change the policy, i should not deal with services.xmlbut
> > rather with the resource behind that uri, for example:
> >
> > <service >
> > <operation name="echo">
> >   <messageReceiver
> > class="org.apache.axis2.rpc.receivers.RPCMessageReceiver "/>
> > </operation>
> > <parameter name="ServiceClass"
> > locked="false">org.apache.rampart.samples.policy.sample01.SimpleService
> </parameter>
> >
> > <module ref="rampart" />
> > <module ref="addressing" />
> >
> > <wsp:PolicyReference wsu:Id="UTOverTransport"
> >                 xmlns:wsu="
> >
> http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
> "
> >                 xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy
> > <http://schemas.xmlsoap.org/ws/2004/09/policy>"
> >                 URI="http://localhost:53307/policy.xml#UTOverTransport"
> />
> > </service>
> >
> > Is that achievable in axis2 ?
> > Thanks.
> >
> > -
> >
> > --
> > Saminda Abeyruwan
> >
> > Software Engineer
> > WSO2 Inc. - www.wso2.org <http://www.wso2.org>
>
> --
> Sanjiva Weerawarana, Ph.D.
> Founder & Director; Lanka Software Foundation; http://www.opensource.lk/
> Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
> Director; Open Source Initiative; http://www.opensource.org/
> Member; Apache Software Foundation; http://www.apache.org/
> Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>
>


-- 
Sanka Samaranayake
WSO2 Inc.

http://sankas.blogspot.com/
http://www.wso2.org/

Re: [Axis2] using policy references in services.xml

Posted by Sanjiva Weerawarana <sa...@opensource.lk>.
I think we need to do the attachment work for services.xml too ... I'm 
definitely +1 for it.

Sanka?

Sanjiva.

Saminda Abeyruwan wrote:
> Forwared with Axis2 prefix
> 
> 
> Hi All,
> I need to use policy references in services.xml,
> meaning that i do not need the actual policy info but a reference to it,
> so if i want to change the policy, i should not deal with services.xml but
> rather with the resource behind that uri, for example:
> 
> <service >
> <operation name="echo">
>   <messageReceiver 
> class="org.apache.axis2.rpc.receivers.RPCMessageReceiver "/>
> </operation>
> <parameter name="ServiceClass" 
> locked="false">org.apache.rampart.samples.policy.sample01.SimpleService</parameter>
> 
> <module ref="rampart" />
> <module ref="addressing" />
> 
> <wsp:PolicyReference wsu:Id="UTOverTransport"
>                 xmlns:wsu=" 
> http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
>                 xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy 
> <http://schemas.xmlsoap.org/ws/2004/09/policy>"
>                 URI="http://localhost:53307/policy.xml#UTOverTransport" />
> </service>
> 
> Is that achievable in axis2 ?
> Thanks.
> 
> -
> 
> -- 
> Saminda Abeyruwan
> 
> Software Engineer
> WSO2 Inc. - www.wso2.org <http://www.wso2.org>

-- 
Sanjiva Weerawarana, Ph.D.
Founder & Director; Lanka Software Foundation; http://www.opensource.lk/
Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
Director; Open Source Initiative; http://www.opensource.org/
Member; Apache Software Foundation; http://www.apache.org/
Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org