[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wsas-java-dev
Subject:    Re: [Carbon-dev] Subscription to registry resources
From:       Afkham Azeez <azeez () wso2 ! com>
Date:       2011-02-28 16:11:10
Message-ID: AANLkTim9obGs7ffF8new2A46o9STQPZ5P5Wy3XVTL6XT () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


On Mon, Feb 28, 2011 at 9:05 PM, Hiranya Jayathilaka <hiranya@wso2.com>wrote:

>
>
> On Mon, Feb 28, 2011 at 8:56 PM, Afkham Azeez <azeez@wso2.com> wrote:
>
>> During a discussion today, we (Sanjiva, Asanka, Srinath & I) thought that
>> it will be a good idea to use XPath-like syntax for selecting how to
>> subscribe to Registry resource paths. We could support only some simple
>> scenarios, and not the entire XPath syntax. Let me explain with an example.
>>
>> The RegistrySynchronizer needs to be notified when deployable artifacts
>> are changed in the Registry. Let's say these artifacts are stored in
>> the _system/config/deployment/*server/* path. Shown below is how the
>> HelloService.aar is stored.
>>
>> /_system/config/deployment/*
>> server/service-groups/foo/bar/HelloService.aar*
>>
>> These are the different way in which we can subscribe to different parts
>> of this hierarchy.
>>
>> 1. /_system/config/deployment/server
>> Selects *server* resource only [1]
>>
>> 2. /_system/config/deployment/server/descendant::*
>> Selects descendants of *server* only, does not select *server. *Selected
>> elements wil be server, service-groups, foo, bar, and HelloService.aar [1]
>>
>> 3. /_system/config/deployment/server/descendant-or-self::*
>> Selects *server* and descendants. Selected elements wil be server,
>> service-groups, foo, bar, and HelloService.aar [1]
>>
>> So, this standard syntax allows us to simply select a node and its
>> descendants in different ways.
>>
>
> Sounds like a good plan. So if a new resource is added under server, will a
> subscriber who subscribed using 2 get notified?
>

Yes


>
> Thanks,
> Hiranya
>
>
>>
>> Thoughts welcome.
>>
>>
>> [1] XPath reference: http://zvon.org/comp/r/tut-XPath_1.html
>>
>> --
>> *Afkham Azeez*
>> Senior Software Architect & Senior Manager; WSO2, Inc.; http://wso2.com,
>> *
>> *
>> *Member; Apache Software Foundation; **http://www.apache.org/*<http://www.apache.org/>
>> *
>> email: **azeez@wso2.com* <azeez@wso2.com>* cell: +94 77 3320919
>> blog: **http://blog.afkham.org* <http://blog.afkham.org>*
>> twitter: **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez>
>> *
>> linked-in: **http://lk.linkedin.com/in/afkhamazeez*
>> *
>> *
>> *Lean . Enterprise . Middleware*
>>
>>
>> _______________________________________________
>> Carbon-dev mailing list
>> Carbon-dev@wso2.org
>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>
>>
>
>
> --
> Hiranya Jayathilaka
> Senior Software Engineer;
> WSO2 Inc.;  http://wso2.org
> E-mail: hiranya@wso2.com;  Mobile: +94 77 633 3491
> Blog: http://techfeast-hiranya.blogspot.com
>



-- 
*Afkham Azeez*
Senior Software Architect & Senior Manager; WSO2, Inc.; http://wso2.com,
*
*
*Member; Apache Software Foundation;
**http://www.apache.org/*<http://www.apache.org/>
*
email: **azeez@wso2.com* <azeez@wso2.com>* cell: +94 77 3320919
blog: **http://blog.afkham.org* <http://blog.afkham.org>*
twitter: **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez>
*
linked-in: **http://lk.linkedin.com/in/afkhamazeez*
*
*
*Lean . Enterprise . Middleware*

[Attachment #5 (text/html)]

<br><br><div class="gmail_quote">On Mon, Feb 28, 2011 at 9:05 PM, Hiranya Jayathilaka \
<span dir="ltr">&lt;<a href="mailto:hiranya@wso2.com">hiranya@wso2.com</a>&gt;</span> \
wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px \
#ccc solid;padding-left:1ex;">

<br><br><div class="gmail_quote"><div class="im">On Mon, Feb 28, 2011 at 8:56 PM, \
Afkham Azeez <span dir="ltr">&lt;<a href="mailto:azeez@wso2.com" \
target="_blank">azeez@wso2.com</a>&gt;</span> wrote:<br><blockquote \
class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc \
solid;padding-left:1ex">


<div>During a discussion today, we (Sanjiva, Asanka, Srinath &amp; I) thought that it \
will be a good idea to use XPath-like syntax for selecting how to subscribe to \
Registry resource paths. We could support only some simple scenarios, and not the \
entire XPath syntax. Let me explain with an example. </div>




<div><br></div><div>The RegistrySynchronizer needs to be notified when deployable \
artifacts are changed in the Registry. Let&#39;s say these artifacts are stored in \
the _system/config/deployment/<b>server/</b> path. Shown below is how the \
HelloService.aar is stored.</div>




<div><br></div><div>/_system/config/deployment/<b>server/service-groups/foo/bar/HelloService.aar</b></div><div><br></div><div>These \
are the different way in which we can subscribe to different parts of this \
hierarchy.</div>




<div><br></div><div>1. /_system/config/deployment/server   </div><div>Selects \
<b>server</b> resource only [1]</div><div><br></div><div>2. \
/_system/config/deployment/server/descendant::* </div><div>Selects descendants of \
<b>server</b> only, does not select <b>server. </b>Selected elements wil be server, \
service-groups, foo, bar, and HelloService.aar [1]</div>




<div><br></div><div>3. /_system/config/deployment/server/descendant-or-self::*  \
</div><div>Selects <b>server</b> and descendants. Selected elements wil be server, \
service-groups, foo, bar, and HelloService.aar [1]</div><div>




<br></div><div>So, this standard syntax allows us to simply select a node and its \
descendants in different ways.</div></blockquote><div><br></div></div><div>Sounds \
like a good plan. So if a new resource is added under server, will a subscriber who \
subscribed using 2 get notified?</div>

</div></blockquote><div><br></div><div>Yes</div><div> </div><blockquote \
class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc \
solid;padding-left:1ex;"><div class="gmail_quote"> \
<div><br></div><div>Thanks,</div><div>Hiranya</div><div> </div><blockquote \
class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc \
solid;padding-left:1ex"><div class="im"><div><br></div><div>Thoughts welcome.</div>

<br><div><br>
</div><div>[1] XPath reference: <a href="http://zvon.org/comp/r/tut-XPath_1.html" \
target="_blank">http://zvon.org/comp/r/tut-XPath_1.html</a></div>

<div><br>-- <br><b>Afkham Azeez</b><br><font face="verdana, sans-serif"><span \
style="font-size:x-small">Senior Software Architect &amp; Senior \
Manager</span></font>; <span style="font-size:x-small">WSO2, Inc.; </span><a \
href="http://wso2.com" target="_blank"><span \
style="font-size:x-small">http://wso2.com</span></a><span style="font-size:x-small">, \
<br>




</span><i><span style="font-size:x-small"><br></span></i><div><i><span \
style="font-size:x-small">Member; Apache Software Foundation; </span></i><a \
href="http://www.apache.org/" target="_blank"><i><span \
style="font-size:x-small">http://www.apache.org/</span></i></a><i><span \
style="font-size:x-small"><br>




email: </span></i><a href="mailto:azeez@wso2.com" target="_blank"><i><span \
style="font-size:x-small">azeez@wso2.com</span></i></a><i><span \
style="font-size:x-small"> cell: +94 77 3320919<br>blog: </span></i><a \
href="http://blog.afkham.org" target="_blank"><i><span \
style="font-size:x-small">http://blog.afkham.org</span></i></a><i><span \
style="font-size:x-small"><br>




twitter: </span></i><a href="http://twitter.com/afkham_azeez" \
target="_blank"><i><span \
style="font-size:x-small">http://twitter.com/afkham_azeez</span></i></a><i><span \
style="font-size:x-small"><br>linked-in: </span></i><i><span \
style="font-size:x-small"><a href="http://lk.linkedin.com/in/afkhamazeez" \
target="_blank">http://lk.linkedin.com/in/afkhamazeez</a></span></i><br>




<div></div><div><i><br></i></div><div><i><span style="font-style:normal"><span \
style="font-size:x-small">Lean . Enterprise . \
Middleware</span></span></i></div></div><br> </div>
<br></div>_______________________________________________<br>
Carbon-dev mailing list<br>
<a href="mailto:Carbon-dev@wso2.org" target="_blank">Carbon-dev@wso2.org</a><br>
<a href="http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev" \
target="_blank">http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev</a><br> \
<br></blockquote></div><font color="#888888"><br><br clear="all"><br>-- <br>Hiranya \
Jayathilaka<br>Senior Software Engineer;<br>WSO2 Inc.;  <a href="http://wso2.org" \
target="_blank">http://wso2.org</a><br>E-mail: <a href="mailto:hiranya@wso2.com" \
target="_blank">hiranya@wso2.com</a>;  Mobile: +94 77 633 3491<br>


Blog: <a href="http://techfeast-hiranya.blogspot.com" \
target="_blank">http://techfeast-hiranya.blogspot.com</a><br> \
</font></blockquote></div><br><br clear="all"><br>-- <br><b>Afkham Azeez</b><br><font \
face="verdana, sans-serif"><span style="font-size:x-small">Senior Software Architect \
&amp; Senior Manager</span></font>; <span style="font-size:x-small">WSO2, Inc.; \
</span><a href="http://wso2.com" target="_blank"><span \
style="font-size:x-small">http://wso2.com</span></a><span style="font-size:x-small">, \
<br>

</span><i><span style="font-size:x-small"><br></span></i><div><i><span \
style="font-size:x-small">Member; Apache Software Foundation; </span></i><a \
href="http://www.apache.org/" target="_blank"><i><span \
style="font-size:x-small">http://www.apache.org/</span></i></a><i><span \
style="font-size:x-small"><br>

email: </span></i><a href="mailto:azeez@wso2.com" target="_blank"><i><span \
style="font-size:x-small">azeez@wso2.com</span></i></a><i><span \
style="font-size:x-small"> cell: +94 77 3320919<br>blog: </span></i><a \
href="http://blog.afkham.org" target="_blank"><i><span \
style="font-size:x-small">http://blog.afkham.org</span></i></a><i><span \
style="font-size:x-small"><br>

twitter: </span></i><a href="http://twitter.com/afkham_azeez" \
target="_blank"><i><span \
style="font-size:x-small">http://twitter.com/afkham_azeez</span></i></a><i><span \
style="font-size:x-small"><br>linked-in: </span></i><i><span \
style="font-size:x-small"><a href="http://lk.linkedin.com/in/afkhamazeez" \
target="_blank">http://lk.linkedin.com/in/afkhamazeez</a></span></i><br>

<div></div><div><i><br></i></div><div><i><span style="font-style:normal"><span \
style="font-size:x-small">Lean . Enterprise . \
Middleware</span></span></i></div></div><br>



_______________________________________________
Carbon-dev mailing list
Carbon-dev@wso2.org
http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic