Hi Mahitha,


Yes, there is inherent risk to the usage of xdmp:eval and xdmp:spawn. But
that doesn’t necessarily mean you can’t use them safely. Check for the
possibility of code injection. Put the eval/spawn within a separate
function, add a check for a new privilege, use amps to grant eval/spawn
privilege for that particular function, and make sure nobody is running the
code with admin..



You could also consider using xdmp:invoke if the above is too much trouble
for you.. ;-)



Kind regards,

Geert



*Van:* [email protected] [mailto:
[email protected]] *Namens *Mahitha T U
*Verzonden:* woensdag 9 november 2011 8:13
*Aan:* General Mark Logic Developer Discussion
*Onderwerp:* [MarkLogic Dev General] xdmp:spawn



Hi ,

In our application, to execute some update statements asynchronously we are
using xdmp:spawn.

 Is it safe to use xdmp:spawn ?

Is there any other way to execute update statements asynchronously ?



Regards

Mahitha
_______________________________________________
General mailing list
[email protected]
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to