次のアイデアに基づいて、サーバー クライアント アプリケーションを開発しました。
クライアント(Windows アプリケーション) は、ソケットに基づくクライアント サーバー アプリケーションのように、サーバー (PHP Web ページ)と連携します。クライアントが生データを PHP Web ページに送信すると、PHP スクリプトは受信したデータをチェック/処理し、最後にスクリプトがクライアントに応答を返します (データの受け入れ/拒否/その他)。
基本的な考え方は、クライアントがアクティブかどうかに関係なく、クライアントがX 秒ごとにサーバーに「ping」することです。クライアントアクティビティをログに記録するための最適なソリューションは何ですか? 例えば:
Client1 started application at Time1       and it "ping" Server for lets say 30 minutes, after that interval the Server stop receiving "pings" from the client;
Client2 started application at Time1+10min and it "ping" Server for lets say 40 minutes, after that interval the Server stop receiving "pings" from the client;
Client1 started application at Time1+35    and it "ping" Server for lets say 60 minutes, after that interval the Server stop receiving "pings" from the client;
** Server stop receiving "pings" from client means there is no activity for at least 1 minute
次のデータを提供できる最終レポートが必要です。
Client   |  Start at   |    End at   | Active
=========+=============+=============+========
Client1  | Time1       | Time1+30min | 30min 
Client2  | Time1+10min | Time1+50min | 40min 
Client1  | Time1+35min | Time1+95min | 60min 
MySQL ログ テーブルを作成する方法と、将来のレポートのために PHP を介してログ テーブルに保存する情報がわかりません。
質問/観察は大歓迎です。
編集: エントリをログに記録するための PHP コードは必要ありません。MySQL CREATE TABLE または SELECT コマンドは必要ありません。すべての記録を保存する良い方法と、それらから何らかの情報を取得する良い方法をお願いしたいだけです。最後まで読まずに投稿に反対票を投じてくれてありがとう。