hi, i'm tring to use the trace api but i have same problems to correctly close 
the trace service.

the call to fbTraceIstance.start("sessionName") will never return so this code 
will not works


fbTraceIstance.start("sessionName")
//next code will never execute
Console.WriteLine("started, press enter to exit");
Console.ReadLine();
fbTraceIstance.Stop(TraceId);  //TraceId is extracted from the first line of 
service output


but if i start the service on another thread i have an exception on 
fbTraceIstance.Close becouse the service is still opened and it tries to reopen 
it inside the
FbTrace.DoSimpleAction method called by FbTrace.Close

this is the multithread code

ThreadPool.QueueUserWorkItem(obj => fbTraceIstance.start("sessionName"));
Console.WriteLine("started, press enter to exit"); Console.ReadLine();
fbTraceIstance.Stop(TraceId);  //TraceId is extracted from the first line of 
service output 

so what's the way to correctly close the service?

and if the client application will exit without closing it there's same problem 
on the firebird server ? for example memory leak, etc

thanks


------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
_______________________________________________
Firebird-net-provider mailing list
Firebird-net-provider@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider

Reply via email to