~grubng-dev/grubng/tools-urlsdb

« back to all changes in this revision

Viewing changes to Database.cs

  • Committer: thindil
  • Date: 2011-04-18 16:59:49 UTC
  • Revision ID: thindil2@gmail.com-20110418165949-uarst200sahg4qel
added automatic disabling upload server during maintenance work

Show diffs side-by-side

added added

removed removed

Lines of Context:
404
404
                                                        {
405
405
                                                                solrcommand.Append("</delete>");
406
406
                                                                scommand = System.Text.RegularExpressions.Regex.Replace(solrcommand.ToString(), @"[\p{IsC}]", String.Empty);
407
 
                                                                MainClass.SendToSolr(scommand);
408
 
                                                                MainClass.SendToSolr("<commit/>");
 
407
                                                                MainClass.SendCommand(scommand, "Solr");
 
408
                                                                MainClass.SendCommand("<commit/>", "Solr");
409
409
                                                                solrcommand.Remove(0, solrcommand.Length);
410
410
                                                                solrcommand.Append("<delete>");
411
411
                                                                amount = 0;
415
415
                                                reader.Dispose();
416
416
                                                solrcommand.Append("</delete>");
417
417
                                                scommand = System.Text.RegularExpressions.Regex.Replace(solrcommand.ToString(), @"[\p{IsC}]", String.Empty);
418
 
                                                MainClass.SendToSolr(scommand);
419
 
                                                MainClass.SendToSolr("<commit/>");
 
418
                                                MainClass.SendCommand(scommand, "Solr");
 
419
                                                MainClass.SendCommand("<commit/>", "Solr");
420
420
                                        }
421
421
                                        dbcmd.CommandText = "DELETE FROM `urlslist` WHERE `http_code1`=" + status + " AND `http_code2`=" + status + 
422
422
                                                " AND `http_code3`=" + status + ";";