Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » Is Xpand thread safe(Is Xpand thread safe)
Is Xpand thread safe [message #517900] Tue, 02 March 2010 13:37 Go to next message
zakir Hussain is currently offline zakir HussainFriend
Messages: 76
Registered: July 2009
Member
Hello All,

I am trying to invoke XpandTemplates in different threads, could you please suggest me whether Xpand is thread safe.

Each XpandTemplate is invoked using XpandFacade.

Re: Is Xpand thread safe [message #518109 is a reply to message #517900] Wed, 03 March 2010 05:38 Go to previous messageGo to next message
Sven Efftinge is currently offline Sven EfftingeFriend
Messages: 1823
Registered: July 2009
Senior Member
zakir Hussain schrieb:
> Hello All,
>
> I am trying to invoke XpandTemplates in different threads, could you
> please suggest me whether Xpand is thread safe.

No it is not.

Cheers,
Sven


--
Need professional support for Xtext and EMF?
Go to: http://xtext.itemis.com
Twitter : @svenefftinge
Blog : blog.efftinge.de
Re: Is Xpand thread safe [message #518152 is a reply to message #518109] Wed, 03 March 2010 09:53 Go to previous messageGo to next message
zakir Hussain is currently offline zakir HussainFriend
Messages: 76
Registered: July 2009
Member
Hello Sven,

Thank you very much for the reply.....

in my case for each thread i am using an XpandFacade to invoke definition of an Xpand template, so in each thread .xpt and .ext will be parsed and loaded in memory for a particular XpandExecutionContext.

Could you please let me know which classes or which modules in Xpand are not thread safe...

Thanks in Advance!!
Re: Is Xpand thread safe [message #518458 is a reply to message #518152] Thu, 04 March 2010 02:46 Go to previous message
Sven Efftinge is currently offline Sven EfftingeFriend
Messages: 1823
Registered: July 2009
Senior Member
I'ld say nothing is thread safe.
But at the same time we don't have any global state (besides the EMF
registries) so if you create separate facades with separate execution
contexts and you make sure that you don't modify the state both engines
are wokring on (i.e. the model) or create clones before so, you should
be fine.

Sven

zakir Hussain schrieb:
> Hello Sven,
>
> Thank you very much for the reply.....
>
> in my case for each thread i am using an XpandFacade to invoke
> definition of an Xpand template, so in each thread .xpt and .ext will be
> parsed and loaded in memory for a particular XpandExecutionContext.
>
> Could you please let me know which classes or which modules in Xpand are
> not thread safe...
>
> Thanks in Advance!!


--
Need professional support for Xtext and EMF?
Go to: http://xtext.itemis.com
Twitter : @svenefftinge
Blog : blog.efftinge.de
Previous Topic:Re: Using Jet with recursive data structures
Next Topic:How to run xpand (or a workflow) from the command line?
Goto Forum:
  


Current Time: Sat Dec 21 14:27:17 GMT 2024

Powered by FUDForum. Page generated in 0.03955 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top