Failure recovery

オープン
#368 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
25/100
issue の種類
機能追加
明瞭さ
説明が足りない
活発さ
停滞
技術スタック
fsharp, sql

調査の方向性

GetDataContext() と静的接続について説明されている動作から始め、続いて #238 の関連するインフラストラクチャに関する議論を読んでください。Recovery ヘルパーの範囲について合意され、接続切断と空の Dictionary のケースを再現可能な形で記録できれば完了です。

索引モデルが issue の本文から書いたものです。

説明

enhancement

I have a (quite common scenario I suppose) web server using SQLProvider to connect a database that is located on a different server.

Sometimes the network connection does fail. That is the nature of HTTP. I try to deal with that having a retry logics when calling GetDataContext().

Now, if the web-server runs a maintenance boot (Windows update) and the network connection is not up and running when the server restarts, this is what happens:

  • Server will start, but the connection is in a broken state
  • If the connection is stored to a static variable, all the queries will crash on runtime even when the connection has been restored. Maybe because the column dictionary is empty or something.
  • This can be fixed by accessing the connection as a function, having a backing-field for the connection, and creating it again if it's null.
  • Another problem seems to be that if the server is running for long time, it seems that the primary-key dictionary goes to empty. This will cause update clauses not to work. I don't know yet the scenario and why but I think it's again about network connection breakups.

Besides that, there is more generic infrastructure, described more detailed in #238 but that started to be off-topic so I started a new issue.

Should we have some kind of extra-functions-namespace (like namespace FSharp.Data.Sql.Extensions) in SQLProvider to provide customers some tools to fight with this kind of nasty real life problems?

主要言語
F#
スター
627
フォーク
147
平均マージ
2時間 2分
マージ済み PR(30日)
1

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

fsprojects/SQLProvider のほかの issue

fsprojects/SQLProvider の issue をすべて見る

似ている issue

Backend & API Design の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。