EF5 Timeout

11 views
Skip to first unread message

Arie Zaks

unread,
Jun 1, 2017, 6:34:20 AM6/1/17
to SharpRe...@googlegroups.com
Hi there,

Is there a way to set the Command timeout without changing the base code? there must be an easy way that I have missed :-) 

Thanks in advance

Arie

Jeff Treuting

unread,
Jun 1, 2017, 12:11:23 PM6/1/17
to Arie Zaks, sharpre...@googlegroups.com

You'll want to inject your own DbContext for SharpRepository to use, then you can set the Command timeout however you like before it gets injected.  Here is some info that might help.


https://fairwaytech.com/2013/02/sharprepository-configuration/

Check out the "Entity Framework and Sharing the DbContext" section


https://stackoverflow.com/questions/10549640/how-to-set-commandtimeout-for-dbcontext


General info on setting the Command timeout.


Hope that helps.


Jeff



From: sharpre...@googlegroups.com <sharpre...@googlegroups.com> on behalf of Arie Zaks <ar...@cliclap.com>
Sent: Thursday, June 1, 2017 3:34:18 AM
To: SharpRe...@googlegroups.com
Subject: [SharpRepository] EF5 Timeout
 
--
You received this message because you are subscribed to the Google Groups "SharpRepository" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sharpreposito...@googlegroups.com.
To post to this group, send email to sharpre...@googlegroups.com.
Visit this group at https://groups.google.com/group/sharprepository.
To view this discussion on the web visit https://groups.google.com/d/msgid/sharprepository/CAHXXks0q2LQ4Akg0EWS3AHvLN4Fj8NO%3DWQBH3AEkwP-V7S--Dg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Arie Zaks

unread,
Jun 1, 2017, 3:21:48 PM6/1/17
to Jeff Treuting, sharpre...@googlegroups.com
Thanks for the prompt respond - I really appreciate it!

have a great weekend 

Arie

On Thu, Jun 1, 2017 at 7:11 PM, Jeff Treuting <jtre...@fairwaytech.com> wrote:

You'll want to inject your own DbContext for SharpRepository to use, then you can set the Command timeout however you like before it gets injected.  Here is some info that might help.


https://fairwaytech.com/2013/02/sharprepository-configuration/

Check out the "Entity Framework and Sharing the DbContext" section


https://stackoverflow.com/questions/10549640/how-to-set-commandtimeout-for-dbcontext


General info on setting the Command timeout.


Hope that helps.


Jeff




Sent: Thursday, June 1, 2017 3:34:18 AM
To: SharpRepository@googlegroups.com
Subject: [SharpRepository] EF5 Timeout
 
Hi there,

Is there a way to set the Command timeout without changing the base code? there must be an easy way that I have missed :-) 

Thanks in advance

Arie

--
You received this message because you are subscribed to the Google Groups "SharpRepository" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sharprepository+unsubscribe@googlegroups.com.
To post to this group, send email to sharprepository@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages