Hi Shameera,

As per the description in [1].

"A graph of bundles is computed starting with the specified bundles. The
graph is expanded by adding any bundle that is either wired to a package
that is currently exported by a bundle in the graph or requires a bundle in
the graph. The graph is fully constructed when there is no bundle outside
the graph that is wired to a bundle in the graph. The graph may contain
UNINSTALLED bundles that are removal
pending<http://www.osgi.org/javadoc/r5/core/org/osgi/framework/wiring/FrameworkWiring.html#getRemovalPendingBundles%28%29>.
"


I also think that it is enough to one level dependency closure refreshing
process.


[1]. http://www.osgi.org/javadoc/r5/core/


Regards,


On Fri, May 16, 2014 at 5:46 PM, Shameera Rathnayaka <[email protected]>wrote:

> Had an offline chat with Aruna,
>
> Regarding  refresh all nested level bundles, If we assume developer will
> follow all osgi best practices( yes, they should be enforced) like not keep
> object references of classes in imported packages, then we can simply
> continue with one level dependency closer refreshing process.
>
> Thanks
> Shameera.
>
>
> On Fri, May 16, 2014 at 11:57 AM, Shameera Rathnayaka 
> <[email protected]>wrote:
>
>> Hi Aruna,
>>
>> If you rewire the first level of bundles in dependency closure IMO of
>> course you need to do it for all next level bundles too.
>>
>> I think we came to a conclusion where we doesn't support hot update(with
>> patch) for top level bundle in bundle hierarchy as it may cause to refresh
>> almost all the bundle in runtime. which is same as restart.
>>
>> List of top level bundles is yet to be decided. You can maintain a
>> property with you patch meta file to provide this information, where hot
>> patch deployer print a WARN to restart the server if there is a such top
>> level bundle comes with patches or deployer will ask a permission to
>> restart the system after applying all the patches if require.
>>
>> thanks,
>> Shameera.
>>
>>
>> On Fri, May 16, 2014 at 11:43 AM, Aruna Karunarathna <[email protected]>wrote:
>>
>>> Hi all,
>>>
>>> Currently I am involved in the R & D of the Hot patch deployment of OSGi
>>> Bundles. As per now I have implemented the hot deployment as follows.
>>>
>>>
>>>    - Update the bundle using an InputStream
>>>    - Get the FrameworkWiring using the SystemBundle
>>>    - Get the bundle's dependency closure using the FrameworkWiring
>>>    - Then finally refresh the the bundles within the dependency closure
>>>
>>>
>>>  My problem is that, is it enough to refresh the first level
>>> dependencies only to the hot deployment to be successful; or do I have to
>>> refresh the next level bundles also.
>>>
>>> I am not clear enough according to the documentation in [1].
>>>
>>> [1].
>>> http://www.osgi.org/javadoc/r4v43/core/org/osgi/framework/wiring/FrameworkWiring.html#refreshBundles(java.util.Collection,
>>> org.osgi.framework.FrameworkListener...)
>>>
>>>
>>>
>>> Regards,
>>> --
>>>
>>> * Aruna Sujith Karunarathna* | Software Engineer
>>> WSO2, Inc | lean. enterprise. middleware.
>>> #20, Palm Grove, Colombo 03, Sri Lanka
>>> Mobile: +94 71 9040362 | Work: +94 112145345
>>> Email: [email protected] | Web: www.wso2.com
>>>
>>>
>>
>>
>>
>> --
>> *Software Engineer - WSO2 Inc.*
>> *email: shameera AT wso2.com <[email protected]> , shameera AT apache.org
>> <[email protected]>*
>> *phone:  +9471 922 1454 <%2B9471%20922%201454>*
>>
>> *Linked in : *http://lk.linkedin.com/pub/shameera-rathnayaka/1a/661/561
>> *Twitter     : *https://twitter.com/Shameera_R
>>
>
>
>
> --
> *Software Engineer - WSO2 Inc.*
> *email: shameera AT wso2.com <[email protected]> , shameera AT apache.org
> <[email protected]>*
> *phone:  +9471 922 1454 <%2B9471%20922%201454>*
>
> *Linked in : *http://lk.linkedin.com/pub/shameera-rathnayaka/1a/661/561
> *Twitter     : *https://twitter.com/Shameera_R
>



-- 

* Aruna Sujith Karunarathna* | Software Engineer
WSO2, Inc | lean. enterprise. middleware.
#20, Palm Grove, Colombo 03, Sri Lanka
Mobile: +94 71 9040362 | Work: +94 112145345
Email: [email protected] | Web: www.wso2.com
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to