You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by aosmakoff <al...@macquarie.com> on 2015/06/19 09:18:40 UTC

Ignite as L2 cache in JBoss6

Hi there. 
We are trying to use Ignite/GridGain as L2 cache for our hibernate
application(s) running in JBoss 6.x that configured with JTA transaction
manager. The program fails to update the cache with a Timeout error.
We narrowed it down to the code in GridCacheJtaManager::checkJta() line
containing: 

if (!jtaTx.enlistResource(rsrc))

where the Tx updates the resource parameters including the timeout. The
problems seems to be that JTA treats the timeout value in seconds than
Ignite/GridGain uses mSec, effectively reducing the specified (in the
container) value by 1000 times. (In Ignite the class is CacheJtaManager)
 
Please see the error below (we used the default JTA timeout = 300sec)

/class org.gridgain.grid.cache.GridCacheTxTimeoutException: Cache
transaction timed out: GridLocalTx [fut=null, super=GridCacheTxLocalAdapter
[completedBase=null, partLock=false, sndTransformedVals=false,
super=GridCacheTxAdapter [xidVer=GridCacheVersion [topVer=46169865,
nodeOrderDrId=1, globalTime=1434692163247, order=1434689857213],
writeVer=null, implicit=false, implicitSingle=false, loc=true, threadId=362,
startTime=1434692163238, nodeId=38301945-ced9-4707-abfe-1ad1de827423,
startVer=GridCacheVersion [topVer=46169865, nodeOrderDrId=1,
globalTime=1434692163247, order=1434689857213], endVer=null,
isolation=READ_COMMITTED, concurrency=PESSIMISTIC,* timeout=300*,
sysInvalidate=false, commitVer=null, finalizing=NONE, preparing=false,
state=MARKED_ROLLBACK, timedOut=true, topVer=-1, duration=564ms,
grpLock=false, onePhaseCommit=false], size=3]]
/

Is this a know issue and is there any workaround.

Many thanks,

Regards,

Alex



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

RE: Ignite as L2 cache in JBoss6

Posted by aosmakoff <al...@macquarie.com>.
Hi Yakov, That was  quick ☺
Thanks we will check it out.
Cheers,
Alex

From: yakov [via Apache Ignite Users] [mailto:ml-node+s70518n546h62@n6.nabble.com]
Sent: Saturday, 20 June 2015 4:37 AM
To: Alex Osmakoff
Subject: Re: Ignite as L2 cache in JBoss6

Alex, I have fixed this. You will be able to download the build on Mon-Tue. Thanks for the catch!

--Yakov

2015-06-19 11:07 GMT+03:00 Yakov Zhdanov <[hidden email]</user/SendEmail.jtp?type=node&node=546&i=0>>:
Alex, I have filed the ticket - https://issues.apache.org/jira/browse/IGNITE-1035


Anyone from community picks it up?

--Yakov

2015-06-19 10:18 GMT+03:00 aosmakoff <[hidden email]</user/SendEmail.jtp?type=node&node=546&i=1>>:
Hi there.
We are trying to use Ignite/GridGain as L2 cache for our hibernate
application(s) running in JBoss 6.x that configured with JTA transaction
manager. The program fails to update the cache with a Timeout error.
We narrowed it down to the code in GridCacheJtaManager::checkJta() line
containing:

if (!jtaTx.enlistResource(rsrc))

where the Tx updates the resource parameters including the timeout. The
problems seems to be that JTA treats the timeout value in seconds than
Ignite/GridGain uses mSec, effectively reducing the specified (in the
container) value by 1000 times. (In Ignite the class is CacheJtaManager)

Please see the error below (we used the default JTA timeout = 300sec)

/class org.gridgain.grid.cache.GridCacheTxTimeoutException: Cache
transaction timed out: GridLocalTx [fut=null, super=GridCacheTxLocalAdapter
[completedBase=null, partLock=false, sndTransformedVals=false,
super=GridCacheTxAdapter [xidVer=GridCacheVersion [topVer=46169865,
nodeOrderDrId=1, globalTime=1434692163247, order=1434689857213],
writeVer=null, implicit=false, implicitSingle=false, loc=true, threadId=362,
startTime=1434692163238, nodeId=38301945-ced9-4707-abfe-1ad1de827423,
startVer=GridCacheVersion [topVer=46169865, nodeOrderDrId=1,
globalTime=1434692163247, order=1434689857213], endVer=null,
isolation=READ_COMMITTED, concurrency=PESSIMISTIC,* timeout=300*,
sysInvalidate=false, commitVer=null, finalizing=NONE, preparing=false,
state=MARKED_ROLLBACK, timedOut=true, topVer=-1, duration=564ms,
grpLock=false, onePhaseCommit=false], size=3]]
/

Is this a know issue and is there any workaround.

Many thanks,

Regards,

Alex



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.



________________________________
If you reply to this email, your message will be added to the discussion below:
http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p546.html
To unsubscribe from Ignite as L2 cache in JBoss6, click here<http://apache-ignite-users.70518.x6.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=538&code=YWxleC5vc21ha29mZkBtYWNxdWFyaWUuY29tfDUzOHwtODQ0MDAyMjc=>.
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>

This email, including any attachments, is confidential. If you are not the intended recipient, you must not disclose, distribute or use the information in this email in any way. If you received this email in error, please notify the sender immediately by return email and delete the message. Unless expressly stated otherwise, the information in this email should not be regarded as an offer to sell or as a solicitation of an offer to buy any financial product or service, an official confirmation of any transaction, or as an official statement of the entity sending this message. Neither Macquarie Group Limited, nor any of its subsidiaries, guarantee the integrity of any emails or attached files and are not responsible for any changes made to them by any other person.




--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p548.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Ignite as L2 cache in JBoss6

Posted by Yakov Zhdanov <yz...@apache.org>.
Cross-posting to dev. Sergey E., can you take a look and finish with this?

Valery, thanks for pointing out.

--Yakov

2015-07-17 9:24 GMT+03:00 shibaevv <sh...@gmail.com>:

> This fix with JTA is working if I keep ignite config outside of my war file
> (e.g. $JBOSS_HOME/config).
> But if I want to keep it inside my war file ignite 1.3.1 failing as it does
> not consider jboss vfs:/ as valid schema (looking for file:/)
>
> uri =
>
> vfs:/C:/Users/vchibaev/Documents/dev/jboss/jboss-as-7.2.0.Final/bin/content/gmer-ear.ear/mro.war/WEB-INF/lib/ignite-core-1.3.1.jar
>
> org.apache.ignite.internal.util.IgniteUtils::resolveProjectHome() {
> ..
>         return findProjectHome(new File(uri));
> }
>
> File ctor:
>         if ((scheme == null) || !scheme.equalsIgnoreCase("file"))
>             throw new IllegalArgumentException("URI scheme is not
> \"file\"")
>
>
>
> --
> View this message in context:
> http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p664.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Re: Ignite as L2 cache in JBoss6

Posted by Yakov Zhdanov <yz...@apache.org>.
Cross-posting to dev. Sergey E., can you take a look and finish with this?

Valery, thanks for pointing out.

--Yakov

2015-07-17 9:24 GMT+03:00 shibaevv <sh...@gmail.com>:

> This fix with JTA is working if I keep ignite config outside of my war file
> (e.g. $JBOSS_HOME/config).
> But if I want to keep it inside my war file ignite 1.3.1 failing as it does
> not consider jboss vfs:/ as valid schema (looking for file:/)
>
> uri =
>
> vfs:/C:/Users/vchibaev/Documents/dev/jboss/jboss-as-7.2.0.Final/bin/content/gmer-ear.ear/mro.war/WEB-INF/lib/ignite-core-1.3.1.jar
>
> org.apache.ignite.internal.util.IgniteUtils::resolveProjectHome() {
> ..
>         return findProjectHome(new File(uri));
> }
>
> File ctor:
>         if ((scheme == null) || !scheme.equalsIgnoreCase("file"))
>             throw new IllegalArgumentException("URI scheme is not
> \"file\"")
>
>
>
> --
> View this message in context:
> http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p664.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Re: Ignite as L2 cache in JBoss6

Posted by shibaevv <sh...@gmail.com>.
This fix with JTA is working if I keep ignite config outside of my war file
(e.g. $JBOSS_HOME/config).
But if I want to keep it inside my war file ignite 1.3.1 failing as it does
not consider jboss vfs:/ as valid schema (looking for file:/)

uri =
vfs:/C:/Users/vchibaev/Documents/dev/jboss/jboss-as-7.2.0.Final/bin/content/gmer-ear.ear/mro.war/WEB-INF/lib/ignite-core-1.3.1.jar

org.apache.ignite.internal.util.IgniteUtils::resolveProjectHome() {
..
        return findProjectHome(new File(uri));
}

File ctor:
        if ((scheme == null) || !scheme.equalsIgnoreCase("file"))
            throw new IllegalArgumentException("URI scheme is not \"file\"")



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p664.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Ignite as L2 cache in JBoss6

Posted by Yakov Zhdanov <yz...@apache.org>.
We are in the end of QA cycle and will make community edition available in
a day which should contain JTA fix.

You can also give a try to RC available here:
https://dist.apache.org/repos/dist/dev/incubator/ignite/1.3.0-rc2/

--Yakov

2015-07-15 6:47 GMT+03:00 shibaevv <sh...@gmail.com>:

> .. still waiting for next build 1.1.5 with JTA fix..
>
>
>
> --
> View this message in context:
> http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p652.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Re: Ignite as L2 cache in JBoss6

Posted by shibaevv <sh...@gmail.com>.
.. still waiting for next build 1.1.5 with JTA fix..



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p652.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Ignite as L2 cache in JBoss6

Posted by yakov <yz...@apache.org>.
This will be available with the next release that is expected at the end of
this week.



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p677.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Ignite as L2 cache in JBoss6

Posted by shibaevv <sh...@gmail.com>.
Hey, just follow up from Yakov cross-post from 17-July to you..
When do you think I can expect this "vfs:" protocol handling in your catch
block (for jboss 6 deployment)?
Thanks
Valera



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p675.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Ignite as L2 cache in JBoss6

Posted by sevdokimov <se...@apache.org>.
shibaevv, I've fixed this problem. Fix will be available in the next release
on Friday or early next week.



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538p620.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Ignite as L2 cache in JBoss6

Posted by Yakov Zhdanov <yz...@apache.org>.
Alex, I have fixed this. You will be able to download the build on Mon-Tue.
Thanks for the catch!

--Yakov

2015-06-19 11:07 GMT+03:00 Yakov Zhdanov <yz...@apache.org>:

> Alex, I have filed the ticket -
> https://issues.apache.org/jira/browse/IGNITE-1035
>
>
> Anyone from community picks it up?
>
> --Yakov
>
> 2015-06-19 10:18 GMT+03:00 aosmakoff <al...@macquarie.com>:
>
>> Hi there.
>> We are trying to use Ignite/GridGain as L2 cache for our hibernate
>> application(s) running in JBoss 6.x that configured with JTA transaction
>> manager. The program fails to update the cache with a Timeout error.
>> We narrowed it down to the code in GridCacheJtaManager::checkJta() line
>> containing:
>>
>> if (!jtaTx.enlistResource(rsrc))
>>
>> where the Tx updates the resource parameters including the timeout. The
>> problems seems to be that JTA treats the timeout value in seconds than
>> Ignite/GridGain uses mSec, effectively reducing the specified (in the
>> container) value by 1000 times. (In Ignite the class is CacheJtaManager)
>>
>> Please see the error below (we used the default JTA timeout = 300sec)
>>
>> /class org.gridgain.grid.cache.GridCacheTxTimeoutException: Cache
>> transaction timed out: GridLocalTx [fut=null,
>> super=GridCacheTxLocalAdapter
>> [completedBase=null, partLock=false, sndTransformedVals=false,
>> super=GridCacheTxAdapter [xidVer=GridCacheVersion [topVer=46169865,
>> nodeOrderDrId=1, globalTime=1434692163247, order=1434689857213],
>> writeVer=null, implicit=false, implicitSingle=false, loc=true,
>> threadId=362,
>> startTime=1434692163238, nodeId=38301945-ced9-4707-abfe-1ad1de827423,
>> startVer=GridCacheVersion [topVer=46169865, nodeOrderDrId=1,
>> globalTime=1434692163247, order=1434689857213], endVer=null,
>> isolation=READ_COMMITTED, concurrency=PESSIMISTIC,* timeout=300*,
>> sysInvalidate=false, commitVer=null, finalizing=NONE, preparing=false,
>> state=MARKED_ROLLBACK, timedOut=true, topVer=-1, duration=564ms,
>> grpLock=false, onePhaseCommit=false], size=3]]
>> /
>>
>> Is this a know issue and is there any workaround.
>>
>> Many thanks,
>>
>> Regards,
>>
>> Alex
>>
>>
>>
>> --
>> View this message in context:
>> http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538.html
>> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>>
>
>

Re: Ignite as L2 cache in JBoss6

Posted by Yakov Zhdanov <yz...@apache.org>.
Alex, I have filed the ticket -
https://issues.apache.org/jira/browse/IGNITE-1035


Anyone from community picks it up?

--Yakov

2015-06-19 10:18 GMT+03:00 aosmakoff <al...@macquarie.com>:

> Hi there.
> We are trying to use Ignite/GridGain as L2 cache for our hibernate
> application(s) running in JBoss 6.x that configured with JTA transaction
> manager. The program fails to update the cache with a Timeout error.
> We narrowed it down to the code in GridCacheJtaManager::checkJta() line
> containing:
>
> if (!jtaTx.enlistResource(rsrc))
>
> where the Tx updates the resource parameters including the timeout. The
> problems seems to be that JTA treats the timeout value in seconds than
> Ignite/GridGain uses mSec, effectively reducing the specified (in the
> container) value by 1000 times. (In Ignite the class is CacheJtaManager)
>
> Please see the error below (we used the default JTA timeout = 300sec)
>
> /class org.gridgain.grid.cache.GridCacheTxTimeoutException: Cache
> transaction timed out: GridLocalTx [fut=null, super=GridCacheTxLocalAdapter
> [completedBase=null, partLock=false, sndTransformedVals=false,
> super=GridCacheTxAdapter [xidVer=GridCacheVersion [topVer=46169865,
> nodeOrderDrId=1, globalTime=1434692163247, order=1434689857213],
> writeVer=null, implicit=false, implicitSingle=false, loc=true,
> threadId=362,
> startTime=1434692163238, nodeId=38301945-ced9-4707-abfe-1ad1de827423,
> startVer=GridCacheVersion [topVer=46169865, nodeOrderDrId=1,
> globalTime=1434692163247, order=1434689857213], endVer=null,
> isolation=READ_COMMITTED, concurrency=PESSIMISTIC,* timeout=300*,
> sysInvalidate=false, commitVer=null, finalizing=NONE, preparing=false,
> state=MARKED_ROLLBACK, timedOut=true, topVer=-1, duration=564ms,
> grpLock=false, onePhaseCommit=false], size=3]]
> /
>
> Is this a know issue and is there any workaround.
>
> Many thanks,
>
> Regards,
>
> Alex
>
>
>
> --
> View this message in context:
> http://apache-ignite-users.70518.x6.nabble.com/Ignite-as-L2-cache-in-JBoss6-tp538.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>