You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by vkulichenko <va...@gmail.com> on 2015/12/04 00:27:15 UTC

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Hi,

I'm not familiar with JBoss classloading model, but I would start with
making sure that your data model classes (the ones that are stored in cache)
are available on classpath of all nodes (both servers and clients). Probably
you need to put them to the same module where Ignite is deployed, so that
Ignite classes and model classes can be loaded by the same class loader.

Let us know if this helps.

Also please properly subscribe to the mailing list so that the community
receives email notifications. Follow the instruction here:
http://apache-ignite-users.70518.x6.nabble.com/mailing_list/MailingListOptions.jtp?forum=1

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2136.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by Anton Vinogradov <av...@gridgain.com>.
PR merged to branch ignite-1.5.
Issue not closed with reason: need to write tests.

On Thu, Dec 17, 2015 at 1:59 PM, Alexey Goncharuk <
alexey.goncharuk@gmail.com> wrote:

> Looks good to me as well. However, shouldn't any tests be added as well?
>

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by Alexey Goncharuk <al...@gmail.com>.
Looks good to me as well. However, shouldn't any tests be added as well?

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by Yakov Zhdanov <yz...@apache.org>.
Seems fair to me.

Sam or Alex Goncharuk, can any of you review this as well?

--Yakov

2015-12-17 13:39 GMT+03:00 Anton Vinogradov <av...@gridgain.com>:

> Yakov,
> TC seems to be ok, could you please review
> https://github.com/apache/ignite/pull/345/files before comit?
>
> On Thu, Dec 17, 2015 at 1:27 PM, Yakov Zhdanov <yz...@apache.org>
> wrote:
>
>> Anton, can you please let us know if changes have been merged?
>>
>> --Yakov
>>
>> 2015-12-16 17:00 GMT+03:00 Anton Vinogradov <av...@gridgain.com>:
>>
>>> Val,
>>> Yes, Please check my pull-request
>>> https://github.com/apache/ignite/pull/345
>>> I'll megre changes tomorrow morning in case everything is ok & TC passed.
>>>
>>> On Wed, Dec 16, 2015 at 6:11 AM, vkulichenko <
>>> valentin.kulichenko@gmail.com> wrote:
>>>
>>>> Completely agree with Juan. Setting class loader only for default
>>>> configuration is definitely not enough for the most use cases.
>>>>
>>>> I reopened the ticket. Anton, will you have a chance to finish the fix?
>>>>
>>>> -Val
>>>>
>>>>
>>>>
>>>> --
>>>> View this message in context:
>>>> http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2228.html
>>>> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>>>>
>>>
>>>
>>
>

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by Anton Vinogradov <av...@gridgain.com>.
Yakov,
TC seems to be ok, could you please review
https://github.com/apache/ignite/pull/345/files before comit?

On Thu, Dec 17, 2015 at 1:27 PM, Yakov Zhdanov <yz...@apache.org> wrote:

> Anton, can you please let us know if changes have been merged?
>
> --Yakov
>
> 2015-12-16 17:00 GMT+03:00 Anton Vinogradov <av...@gridgain.com>:
>
>> Val,
>> Yes, Please check my pull-request
>> https://github.com/apache/ignite/pull/345
>> I'll megre changes tomorrow morning in case everything is ok & TC passed.
>>
>> On Wed, Dec 16, 2015 at 6:11 AM, vkulichenko <
>> valentin.kulichenko@gmail.com> wrote:
>>
>>> Completely agree with Juan. Setting class loader only for default
>>> configuration is definitely not enough for the most use cases.
>>>
>>> I reopened the ticket. Anton, will you have a chance to finish the fix?
>>>
>>> -Val
>>>
>>>
>>>
>>> --
>>> View this message in context:
>>> http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2228.html
>>> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>>>
>>
>>
>

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by Yakov Zhdanov <yz...@apache.org>.
Anton, can you please let us know if changes have been merged?

--Yakov

2015-12-16 17:00 GMT+03:00 Anton Vinogradov <av...@gridgain.com>:

> Val,
> Yes, Please check my pull-request
> https://github.com/apache/ignite/pull/345
> I'll megre changes tomorrow morning in case everything is ok & TC passed.
>
> On Wed, Dec 16, 2015 at 6:11 AM, vkulichenko <
> valentin.kulichenko@gmail.com> wrote:
>
>> Completely agree with Juan. Setting class loader only for default
>> configuration is definitely not enough for the most use cases.
>>
>> I reopened the ticket. Anton, will you have a chance to finish the fix?
>>
>> -Val
>>
>>
>>
>> --
>> View this message in context:
>> http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2228.html
>> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>>
>
>

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by Anton Vinogradov <av...@gridgain.com>.
Val,
Yes, Please check my pull-request https://github.com/apache/ignite/pull/345
I'll megre changes tomorrow morning in case everything is ok & TC passed.

On Wed, Dec 16, 2015 at 6:11 AM, vkulichenko <va...@gmail.com>
wrote:

> Completely agree with Juan. Setting class loader only for default
> configuration is definitely not enough for the most use cases.
>
> I reopened the ticket. Anton, will you have a chance to finish the fix?
>
> -Val
>
>
>
> --
> View this message in context:
> http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2228.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by vkulichenko <va...@gmail.com>.
Completely agree with Juan. Setting class loader only for default
configuration is definitely not enough for the most use cases.

I reopened the ticket. Anton, will you have a chance to finish the fix?

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2228.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by Yakov Zhdanov <yz...@apache.org>.
Thanks, Juan! We are very glad to hear that Ignite is helpful for you!

--Yakov

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by Anton Vinogradov <av...@gridgain.com>.
Juan,

I've checked fix and pushed it to ignite-1.5.

On Mon, Dec 14, 2015 at 3:29 PM, Yakov Zhdanov <yz...@apache.org> wrote:

> Juan,
>
> Anton Vinogradov has identified the problem in cache manager and fixed it
> (one-liner fix) and will check tc today. If this does not break anything,
> we will include it into ignite-1.5 release which should be available early
> next week.
>
> --Yakov
>
> 2015-12-08 18:18 GMT+03:00 juanavelez <js...@gmail.com>:
>
>> That was the original approach but seeing how difficult it is to
>> correctly set the IgniteConfiguration object (either by using Properties as
>> you pointed out earlier in this thread because of Factories, SPIs, etc. or
>> JSON as stated in another thread), we realized we could not avoid using
>> Spring and hence the route of using
>> IgnitionEx.loadConfigurations(springCfgUrl) which I agree tightly couples
>> us to a specific JCache implementation.
>>
>> We have already tested the approach and it seems to work at least for our
>> purposes.
>>
>> And yes, indeed we are bound by what the JCache API allows
>> Ignite/Hazelcast to expose which might not be the full features.
>>
>> BTW: We are very happy with Ignite, it has very strong features (we like
>> the most the seamless integration with JTA/XA!) which fit perfect our
>> intended purpose. Thank you for such a great product and your constant help.
>>
>>
>> Thanks - Juan
>>
>>
>> On Dec 7, 2015, at 2:25 PM, vkulichenko [via Apache Ignite Users] <[hidden
>> email] <http:///user/SendEmail.jtp?type=node&node=2178&i=0>> wrote:
>>
>> Juan,
>>
>> I don't see how this will help you.
>> IgnitionEx.loadConfigurations(springCfgUrl) still uses Spring to load
>> configuration from the file.
>>
>> I think the best way is to create IgniteConfiguration object, set class
>> loader, start Ignite and create cache using Ignite API. If you then use
>> only JCache APIs, switching to another provider will be very easy even if
>> you don't use CacheManager. But note that not all Ignite features will be
>> available in this case (like SQL queries, for example).
>>
>> -Val
>>
>> ------------------------------
>> If you reply to this email, your message will be added to the discussion
>> below:
>>
>> http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2171.html
>> To unsubscribe from Help with integrating Ignite(as JCache) with JBoss
>> EAP 6.4, click here.
>> NAML
>> <http://apache-ignite-users.70518.x6.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>
>>
>>
>>
>> ------------------------------
>> View this message in context: Re: Help with integrating Ignite(as
>> JCache) with JBoss EAP 6.4
>> <http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2178.html>
>> Sent from the Apache Ignite Users mailing list archive
>> <http://apache-ignite-users.70518.x6.nabble.com/> at Nabble.com.
>>
>
>

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by Yakov Zhdanov <yz...@apache.org>.
Juan,

Anton Vinogradov has identified the problem in cache manager and fixed it
(one-liner fix) and will check tc today. If this does not break anything,
we will include it into ignite-1.5 release which should be available early
next week.

--Yakov

2015-12-08 18:18 GMT+03:00 juanavelez <js...@gmail.com>:

> That was the original approach but seeing how difficult it is to correctly
> set the IgniteConfiguration object (either by using Properties as you
> pointed out earlier in this thread because of Factories, SPIs, etc. or JSON
> as stated in another thread), we realized we could not avoid using Spring
> and hence the route of using IgnitionEx.loadConfigurations(springCfgUrl)
> which I agree tightly couples us to a specific JCache implementation.
>
> We have already tested the approach and it seems to work at least for our
> purposes.
>
> And yes, indeed we are bound by what the JCache API allows
> Ignite/Hazelcast to expose which might not be the full features.
>
> BTW: We are very happy with Ignite, it has very strong features (we like
> the most the seamless integration with JTA/XA!) which fit perfect our
> intended purpose. Thank you for such a great product and your constant help.
>
>
> Thanks - Juan
>
>
> On Dec 7, 2015, at 2:25 PM, vkulichenko [via Apache Ignite Users] <[hidden
> email] <http:///user/SendEmail.jtp?type=node&node=2178&i=0>> wrote:
>
> Juan,
>
> I don't see how this will help you.
> IgnitionEx.loadConfigurations(springCfgUrl) still uses Spring to load
> configuration from the file.
>
> I think the best way is to create IgniteConfiguration object, set class
> loader, start Ignite and create cache using Ignite API. If you then use
> only JCache APIs, switching to another provider will be very easy even if
> you don't use CacheManager. But note that not all Ignite features will be
> available in this case (like SQL queries, for example).
>
> -Val
>
> ------------------------------
> If you reply to this email, your message will be added to the discussion
> below:
>
> http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2171.html
> To unsubscribe from Help with integrating Ignite(as JCache) with JBoss EAP
> 6.4, click here.
> NAML
> <http://apache-ignite-users.70518.x6.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>
>
>
>
> ------------------------------
> View this message in context: Re: Help with integrating Ignite(as JCache)
> with JBoss EAP 6.4
> <http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2178.html>
> Sent from the Apache Ignite Users mailing list archive
> <http://apache-ignite-users.70518.x6.nabble.com/> at Nabble.com.
>

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by juanavelez <js...@gmail.com>.
That was the original approach but seeing how difficult it is to correctly set the IgniteConfiguration object (either by using Properties as you pointed out earlier in this thread because of Factories, SPIs, etc. or JSON as stated in another thread), we realized we could not avoid using Spring and hence the route of using IgnitionEx.loadConfigurations(springCfgUrl) which I agree tightly couples us to a specific JCache implementation.

We have already tested the approach and it seems to work at least for our purposes.

And yes, indeed we are bound by what the JCache API allows Ignite/Hazelcast to expose which might not be the full features.

BTW: We are very happy with Ignite, it has very strong features (we like the most the seamless integration with JTA/XA!) which fit perfect our intended purpose. Thank you for such a great product and your constant help.


Thanks - Juan


> On Dec 7, 2015, at 2:25 PM, vkulichenko [via Apache Ignite Users] <ml...@n6.nabble.com> wrote:
> 
> Juan, 
> 
> I don't see how this will help you. IgnitionEx.loadConfigurations(springCfgUrl) still uses Spring to load configuration from the file. 
> 
> I think the best way is to create IgniteConfiguration object, set class loader, start Ignite and create cache using Ignite API. If you then use only JCache APIs, switching to another provider will be very easy even if you don't use CacheManager. But note that not all Ignite features will be available in this case (like SQL queries, for example). 
> 
> -Val 
> 
> If you reply to this email, your message will be added to the discussion below:
> http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2171.html <http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2171.html>
> To unsubscribe from Help with integrating Ignite(as JCache) with JBoss EAP 6.4, click here <http://apache-ignite-users.70518.x6.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=2134&code=anNqdW5rZW1haWw3M0BnbWFpbC5jb218MjEzNHw1NjQzNTc4Mjg=>.
> NAML <http://apache-ignite-users.70518.x6.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>




--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2178.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by vkulichenko <va...@gmail.com>.
Juan,

I don't see how this will help you.
IgnitionEx.loadConfigurations(springCfgUrl) still uses Spring to load
configuration from the file.

I think the best way is to create IgniteConfiguration object, set class
loader, start Ignite and create cache using Ignite API. If you then use only
JCache APIs, switching to another provider will be very easy even if you
don't use CacheManager. But note that not all Ignite features will be
available in this case (like SQL queries, for example).

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2171.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by juanavelez <js...@gmail.com>.
Hi Val,

Thanks for your reply. 

The reason for all this request was to try to use the JCache API as agnostically as possible, so we could switch implementations if necessary (for example switch from Hazelcast to Ignite and viceversa).

I agree with you that having the configuration in properties is very difficult (I tried to use JSON to deserialize a very simple Ignite Configuration and honestly could not accomplish it).

At this point I think we are going to go the route of using Spring configuration and use its URI as a parameter to CachingProvider.getCacheManager but we still have the issue of the ClassLoader (for which you have gladly opened a ticket). 

Since the fix for the classloader issue is not yet released, we don’t know yet how we will proceed. An option we are thinking is to create the IgniteConfiguration based on code in IgnitionEx.loadConfigurations(springCfgUrl).

Thanks - Juan

> On Dec 7, 2015, at 1:05 PM, vkulichenko [via Apache Ignite Users] <ml...@n6.nabble.com> wrote:
> 
> Juan, 
> 
> I don't see why we should provide cache configuration properties there, because cache is created by CacheManager, not CachingProvider, and based on configuration object, not Spring XML file. 
> 
> At the same time I agree that now there is now way to use Ignite's CacheManager without Spring and it would be nice to have an alternative. But the problem is that it's really hard to express the whole Ignite configuration as Properties class (there are factories, SPIs, etc.). 
> 
> I think we can add an optional grid name property that will allow to provide the name of already started Ignite instance. This way user will be able to start Ignite outside of CacheManager using IgniteConfiguration object (no XML file needed) and then create CacheManager based on this existing Ignite instance. What do you think? 
> 
> -Val 
> 
> If you reply to this email, your message will be added to the discussion below:
> http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2166.html <http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2166.html>
> To unsubscribe from Help with integrating Ignite(as JCache) with JBoss EAP 6.4, click here <http://apache-ignite-users.70518.x6.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=2134&code=anNqdW5rZW1haWw3M0BnbWFpbC5jb218MjEzNHw1NjQzNTc4Mjg=>.
> NAML <http://apache-ignite-users.70518.x6.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>




--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2168.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by vkulichenko <va...@gmail.com>.
Juan,

I don't see why we should provide cache configuration properties there,
because cache is created by CacheManager, not CachingProvider, and based on
configuration object, not Spring XML file.

At the same time I agree that now there is now way to use Ignite's
CacheManager without Spring and it would be nice to have an alternative. But
the problem is that it's really hard to express the whole Ignite
configuration as Properties class (there are factories, SPIs, etc.).

I think we can add an optional grid name property that will allow to provide
the name of already started Ignite instance. This way user will be able to
start Ignite outside of CacheManager using IgniteConfiguration object (no
XML file needed) and then create CacheManager based on this existing Ignite
instance. What do you think?

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2166.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by juanavelez <js...@gmail.com>.
Hi Val,

Thanks for opening the ticket.

Regarding the properties, I think it’d be good if each configurable property (e.g. CacheConfiguration.atomicityMode, CacheConfiguration.backups, TransactionConfiguration.txManagerLookupClassName, etc.) could have its own property name, such as you don’t have to rely on Spring-based configuration for the actual configuration of the Cache and instead pass a Properties object to CachingProvider::getCacheManager which would be honored (basically looking for the specific property names and setting those in the appropriate *Configuration object).

Thanks - Juan

> On Dec 4, 2015, at 12:48 PM, vkulichenko [via Apache Ignite Users] <ml...@n6.nabble.com> wrote:
> 
> Juan, 
> 
> Here is the ticket for this: https://issues.apache.org/jira/browse/IGNITE-2087 <https://issues.apache.org/jira/browse/IGNITE-2087>
> 
> What other properties except the class loader should be honored in your point of view? Please share your thoughts in the ticket. You are also free to pick it up and make the fix ;) 
> 
> -Val 
> 
> If you reply to this email, your message will be added to the discussion below:
> http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2143.html <http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2143.html>
> To unsubscribe from Help with integrating Ignite(as JCache) with JBoss EAP 6.4, click here <http://apache-ignite-users.70518.x6.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=2134&code=anNqdW5rZW1haWw3M0BnbWFpbC5jb218MjEzNHw1NjQzNTc4Mjg=>.
> NAML <http://apache-ignite-users.70518.x6.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>




--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2144.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by vkulichenko <va...@gmail.com>.
Juan,

Here is the ticket for this:
https://issues.apache.org/jira/browse/IGNITE-2087

What other properties except the class loader should be honored in your
point of view? Please share your thoughts in the ticket. You are also free
to pick it up and make the fix ;)

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2143.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by juanavelez <js...@gmail.com>.
Val, 

Correct. If the classloader passed to CachingProvider::getCacheManager(uri,
clsLdr) is honored, that would be a fix. Also, it would be great if
properties passed to the other overloaded mehtod
CachingProvider::getCacheManager(urig, clsLdr, props) was honored as well. 

Thanks - Juan



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2140.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by vkulichenko <va...@gmail.com>.
Juan,

Do I understand correctly, that if Ignite's cache manager sets its class
loader (the one that was passed to getCacheManager() method) to the
IgniteConfiguration when starting a node, everything will work properly? If
so, it's a good point and looks like an easy fix.

Please confirm that I am not missing anything here and I will create a
ticket.

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2139.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Help with integrating Ignite(as JCache) with JBoss EAP 6.4

Posted by juanavelez <js...@gmail.com>.
Hi Val,

I was unable to make Ignite work as a JCache provider (even thought it is
possible to pass properties to the getCacheManager method, those properties
are discarded by Ignite's Cache Manager, so there is no way to set the class
loader to be used by ignite), however I did have success instead using it
normally (good thing an Ignite Cache is a JCache cache). In order to keep
using the MANIFEST dependencies/JBoss module paradigm I had to set the
classloader in the InginiteConfiguration(setClassLoader) class using the
classloader that loaded the code that starts ignite
(Thread.currentThread().getContextClassLoader()).

And indeed you are correct that a solution is to place the ignite libraries
in the EAR's lib folder as they can see the EJB's module code (by default in
JBoss EAP 6+, the isolation among modules in an EAR is set to false, which
means all modules can see each other, well, EJB/LIB/WAR modules can see LIBs
and EJBs but WAR code can only be seen by WAR code) but I was trying to use
the MANIFEST dependencies/jboss module approach.

Thanks - Juan



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Help-with-integrating-Ignite-as-JCache-with-JBoss-EAP-6-4-tp2134p2137.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.