title: ThreadAbortException on retrieving data from Entities db context
body: <p>on prod application throw an ThreadAbortException during retrieving data from my db context, it's about 1 million rows of data table.
  I set intentionnally set a big CommandTimeOut of 5 hours but even though this i have an system.web.httpException Timeout reached. by logging i can get this trace :</p>
  
  <pre><code>07/11/2013 09:54 : 
  System.Threading.ThreadAbortException: Le thread a été abandonné.
     à SNIReadSync(SNI_Conn* , SNI_Packet** , Int32 )
     à SNINativeMethodWrapper.SNIReadSync(SafeHandle pConn, IntPtr&amp; packet, Int32 timeout)
     à System.Data.SqlClient.TdsParserStateObject.ReadSni(DbAsyncResult asyncResult, TdsParserStateObject stateObj)
     à System.Data.SqlClient.TdsParserStateObject.ReadNetworkPacket()
     à System.Data.SqlClient.TdsParserStateObject.ReadBuffer()
     à System.Data.SqlClient.TdsParserStateObject.ReadByte()
     à System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
     à System.Data.SqlClient.SqlDataReader.ConsumeMetaData()
     à System.Data.SqlClient.SqlDataReader.get_MetaData()
     à System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
     à System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)
     à System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
     à System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
     à System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
     à System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior)
     à System.Data.Common.DbCommand.ExecuteReader(CommandBehavior behavior)
     à System.Data.EntityClient.EntityCommandDefinition.ExecuteStoreCommands(EntityCommand entityCommand, CommandBehavior behavior)
     à System.Data.Objects.Internal.ObjectQueryExecutionPlan.Execute[TResultType](ObjectContext context, ObjectParameterCollection parameterValues)
     à System.Data.Objects.ObjectQuery`1.GetResults(Nullable`1 forMergeOption)
     à System.Data.Objects.ObjectQuery`1.System.Collections.Generic.IEnumerable&lt;T&gt;.GetEnumerator()
     à LinqKit.ExpandableQuery`1.GetEnumerator()
     à System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
     à System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
     à DrillWatcher.DisplaySegment.GetSegmentDataTable(ICollection`1 idDrills, List`1 segmentColumnToDisplay) dans C:\SourcesTFS\JLSA\Main\Source\DrillWatcher\DrillWatcher\DrillWatcher\DisplaySegment.aspx.cs:ligne 262
     à DrillWatcher.DrillWatcher.MakeCsvFile(DataTable source, Boolean withSegment) dans C:\SourcesTFS\JLSA\Main\Source\DrillWatcher\DrillWatcher\DrillWatcher\DrillWatcher.aspx.cs:ligne 989
  </code></pre>
  
  <p>Code :</p>
  
  <pre><code> public static DataTable GetSegmentDataTable(ICollection&lt;long&gt; idDrills, List&lt;string&gt; segmentColumnToDisplay)
          {
              var predicat = PredicateBuilder.True&lt;DrillSegments&gt;();
              Expression&lt;Func&lt;DrillSegments, bool&gt;&gt; exp = segments =&gt; idDrills.Contains(segments.DrillId);
              predicat = predicat.And(exp);
  
              using (var dqe = new DrillQuerierEntities { CommandTimeout = 18000})
              {
  
                  try
                  {
                      //Nom du forage
                      var result = dqe.DrillSegments.Include("DrillSegmentInfo.DrillSegmentInfoExtraData").AsExpandable().Where(predicat).OrderBy(x =&gt; x.SequenceNumber).ToList(); // first toList so querying db
                      var segmentDataTable = new DataTable("DrillSegments");
  -------------
  </code></pre>
  
  <p>Any idea about this strange exception ?
  Thx for advance</p>