On Wed, Mar 7, 2018 at 1:26 PM, Madhawa Gunasekara <madha...@wso2.com>
wrote:

> Hi Naduni,
>
> You can use ant plugin [1]. Here is a sample config [2]
>
> [1] https://ant.apache.org/manual/Tasks/replace.html
> [2] https://github.com/wso2-attic/product-dss/blob/master/
> modules/distribution/pom.xml#L321
>
> Thanks Madhawa. I was able to get it done using the ant plugin.

Thanks,
Naduni

> Thanks,
> Madhawa
>
> On Wed, Mar 7, 2018 at 12:27 PM, Naduni Pamudika <nad...@wso2.com> wrote:
>
>> Hi All,
>>
>> I have a requirement to comment out the below element in identity.xml
>> when building the micro-gateway distribution.
>>
>> <Server xmlns="http://wso2.org/projects/carbon/carbon.xml";>
>>     <OAuth>
>>         <!-- Scope validators list. The validators registered here wil be
>> executed during token validation. -->
>>         <ScopeValidators>
>>             <ScopeValidator class="org.wso2.carbon.identit
>> y.oauth2.validators.JDBCScopeValidator"/>
>>             <ScopeValidator class="org.wso2.carbon.identit
>> y.oauth2.validators.XACMLScopeValidator"/>
>>         </ScopeValidators>
>>     </OAuth>
>> </Server>
>>
>> I tried using the maven replacer plugin by adding a configuration as
>> below, but it didn't work as it replaced the value of the class attribute
>> with an empty string.
>>
>> <configuration>
>>     
>> <file>${basedir}/../../p2-profile/micro-gateway/target/wso2carbon-core-${carbon.kernel.version}/repository/conf/identity/identity.xml</file>
>>     <replacements>
>>         <replacement>
>>             <xpath>/Server/OAuth/ScopeValidators</xpath>
>>             
>> <token>(org.wso2.carbon.identity.oauth2.validators.XACMLScopeValidator)</token>
>>             <value></value>
>>         </replacement>
>>     </replacements>
>> </configuration>
>>
>> Does anyone know how to get this done using the replacer plugin or any
>> other plugin?
>>
>> Thanks,
>> Naduni
>>
>> --
>> *Naduni Pamudika*
>> Software Engineer | WSO2
>> Mobile: +94 719 143658 <+94%2071%20914%203658>
>> [image: http://wso2.com/signature] <http://wso2.com/signature>
>>
>> _______________________________________________
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> *Madhawa Gunasekara*
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: +94 719411002 <+94+719411002>
> blog: *http://madhawa-gunasekara.blogspot.com
> <http://madhawa-gunasekara.blogspot.com>*
> linkedin: *http://lk.linkedin.com/in/mgunasekara
> <http://lk.linkedin.com/in/mgunasekara>*
>



-- 
*Naduni Pamudika*
Software Engineer | WSO2
Mobile: +94 719 143658 <+94%2071%20914%203658>
[image: http://wso2.com/signature] <http://wso2.com/signature>
_______________________________________________
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to