Hi Duarte,<div><br></div><div>Your new method should contain something like this:</div><div><br></div><div><div>sub new {</div><div>    my $class = shift;</div><div><br></div><div>    my $self = $class->SUPER::new(@_);</div>
<div>    </div><div>    delete $self->{config}->{fork} if defined($self->{config}->{fork});</div><div><br></div><div>    return $self;</div><div>}</div></div><div><br></div><div>Note that this will disable forking globally (i.e. the same as if you had not added --fork on the command line).</div>
<div><br></div><div>Will</div><div class="gmail_extra"><br><br><div class="gmail_quote">On 27 November 2012 13:23, Duarte Molha <span dir="ltr"><<a href="mailto:Duarte.Molha@ogt.co.uk" target="_blank">Duarte.Molha@ogt.co.uk</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div lang="EN-GB" link="blue" vlink="purple"><div><p class="MsoNormal">Dear developers<u></u><u></u></p><p class="MsoNormal">
<u></u> <u></u></p><p class="MsoNormal">The use of fork seems to crash the script and I would like to test disabling the fork for my plugins.<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">In your documentation you say:<u></u><u></u></p>
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Helvetica","sans-serif";color:#555555;background:white">NB:</span></b><span><span style="font-size:10.0pt;font-family:"Helvetica","sans-serif";color:#555555;background:white"> </span></span><span style="font-size:10.0pt;font-family:"Helvetica","sans-serif";color:#555555;background:white">VEP users writing plugins should be aware that while the VEP code attempts to preserve the state of any plugin-specific cached data between separate forks, there may be situations where data is lost. If you find this is the case, you should disable forking in the new() method of your plugin by deleting the "fork" key from the $config hash.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Helvetica","sans-serif";color:#555555;background:white"><u></u> <u></u></span></p><p class="MsoNormal">Can you specify exactly how you would to this?<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">Cheers, <u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Duarte Molha</span><span style="font-size:12.0pt;font-family:"Times New Roman","serif""><u></u><u></u></span></p>
<p class="MsoNormal"><u></u> <u></u></p></div></div><br>_______________________________________________<br>
Dev mailing list    <a href="mailto:Dev@ensembl.org">Dev@ensembl.org</a><br>
Posting guidelines and subscribe/unsubscribe info: <a href="http://lists.ensembl.org/mailman/listinfo/dev" target="_blank">http://lists.ensembl.org/mailman/listinfo/dev</a><br>
Ensembl Blog: <a href="http://www.ensembl.info/" target="_blank">http://www.ensembl.info/</a><br>
<br></blockquote></div><br></div>