You should never use the same ExecutionContext or XWikiContext in
different threads since they are really not designed for this and you
will have weird random issue at best.
You can find a example of a component getting the current XWikiContext
and setting the current wiki id on
https://github.com/xwiki/xwiki-platform/blob/master/xwiki-platform-core/xwi….
On Mon, Nov 16, 2015 at 1:45 PM, Peter Huisman <p.huisman(a)ximm.nl> wrote:
Hi Thomas,
I figured something like this. I have however been trying to pass various parameters to
the request but this has not resulted in any succes: Passing the entire context (either
ExecutionContext or XWikiContext) did’t work and neither did setting the WikiId or the
database. Can you help me on this with an example on what (and how) to set?
Br,
Peter
Van: Thomas Mortagne <thomas.mortagne(a)xwiki.com
<mailto:thomas.mortagne@xwiki.com>>
Onderwerp: Antw.: [xwiki-users] Question on Jobs and context
Datum: 14 november 2015 14:13:17 CET
Aan: XWiki Users <users(a)xwiki.org <mailto:users@xwiki.org>>
Antwoord aan: XWiki Users <users(a)xwiki.org <mailto:users@xwiki.org>>
You can change the context with in the XWikiContext. See
http://platform.xwiki.org/xwiki/bin/view/DevGuide/WritingComponents#HTheXWi…
<http://platform.xwiki.org/xwiki/bin/view/DevGuide/WritingComponents#HTheXWikicontext>
for how to access it from a component.
_______________________________________________
users mailing list
users(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/users
--
Thomas Mortagne