USE ENTITY SELECTION
は,ORDAのエンティティセレクションをクラシック言語のカレントセレクションに変換するコマンドです。
コマンドは,クラシック言語の代わりにORDAでカレントセレクションを作成するためのものです。パフォーマンス最適化のため,可能なときには,元のエンティティセレクションをクローンせずにそのままカレントセレクションのバックエンドとして利用します。その場合,元のエンティティセレクションとカレントセレクションは同じデータセットを指します。実際の振る舞いは種々の条件に左右されるため,USE ENTITY SELECTION
の実行後に元のカレントセレクションを使用することは避けてください。
「WindowsでSDIモードを使用する」を有効にしている場合,ユーザーが画面を操作してアプリケーションを終了できるように設定されていなければなりません。MDIモードでは,メインウィンドウ(MDI)を閉じることにより,アプリケーションを終了することができますが,SDIモードでは,すべてのウィンドウを閉じた後であっても,Webサーバー・SQLサーバー・ワーカー・イベント待ちプロセスなどが残っていれば,アプリケーションは終了せずにバックグランドプロセスとして実行を継続します(タスクマネージャーを参照してください)。すべてのウィンドウを閉じた時点でWebサーバーなどのインタラクティブなプロセスが残っていない場合,QUIT 4D
が自動的に実行され,アプリケーションは終了します。たとえば,「スプラッシュウィンドウを表示」が無効に設定されており,On Startup で何もダイアログを開始しない場合,アプリケーションは開始直後に終了します。
WebSocketServerを使用すれば,リアルタイムで音声や動画をストリーミング配信することができますか
4D.WebSocketServer
には,WebSocketStreamのようにバックプレッシャーを適用する仕組みがないので,動画のライブ配信やビデオ会議システムのようなアプリケーションを構築する用途には向いていません。
ブラウザからJavaScriptで定期的に送信されるフレーム画像を扱うような“防犯カメラ”アプリケーションであれば,WebSocketServerだけで構築することができます。
Qodly for 4Dは日本語のテーブル名やフィールド名に対応していますか
Qodlyアプリケーションは,REST APIを介して4Dと対話します。データエクスプローラーは,Qodlyアプリケーションのプロトタイプとも呼べるものですが,テーブル名やフィールド名に日本語が使用されていても問題なく動作し,REST APIレベルでは対応していることが確認できます。
Qodlyアプリケーションでは,REST APIの呼び出しを制御する抽象化レイヤーであるデータソースが重要な役目を担います。データソース名とテーブル/フィールド名(データクラス/属性名)を一緒にする必要はありませんが,普通は両者の名前を揃えたいと思うはずです。そこでデータソース名に日本語が使用できるのか,という疑問が生じます。
Qodly Studioの画面上で日本語を入力しようとすると,エラーメッセージが表示される箇所があります。たとえば,Webフォーム名に日本語を使用すると,The name must start with a letter(先頭は文字でなければなりません)というメッセージが表示され,入力した値を確定することができません。同様に,データソース名に日本語を使用すると,Only letters and numbers are allowed(使用できるのは文字または数字です)というメッセージが表示され,やはり,確定することができません。Qodly Studio側でフィルターによる入力制限がかけられているためです。
Webフォーム名はプロジェクトフォルダー内にある.WebForm ファイルの名前そのものなので,直接ファイル名を変更すれば,日本語にすることができます。データソース名は.WebForm ファイル(JSON形式)の中に列挙されているので,直接ファイルの内容を編集すれば,こちらも日本語で定義することができ,実際に動かしてみると,特に問題ないことが確認できます。
現在,Qodly Studio側のフィルターによる入力制限を緩和することが検討されています。安全性が確認できれば,一部の箇所(特にデータソース名)は日本語が入力できるようになる予定です。Webフォーム名のようにファイル名と対応しているものについては,プラットフォーム間におけるUnicode実装の違いなどを考慮し,引き続きASCII文字に限定されるかもしれません。
Qodly Cloudのライセンスは月額のサブスクリプション料金とのことですが,不特定多数のユーザーがアクセスできる無制限接続ライセンスは提供されないのでしょうか
Qodly Cloudは,不特定多数の一般ユーザーがアクセスできるWebサイトを構築するためのツールではなく,一種のクライアント/サーバー版アプリケーション(クライアントはブラウザ)を開発するためのツールです。そのため,同時接続ユーザー数に基づくシンプルな料金体系がもっとも合理的であると考えています。
とはいえ,ユーザーにログインを求めないアプリケーションの開発をサポートするため,アウトバウンドデータの転送量に基づく料金体系も検討されています。公式のアナウンスをお待ちください。
似たような処理をさせた場合,ORDAとクラシック言語でパフォーマンスに違いはないのでしょうか
単純なクエリであれば,速度・メモリ足跡ともに違いはほとんどありません。どちらの方法で記述しても,実際のクエリは同じデータベースエンジンが処理しているからです。
ORDAは単なるクエリ言語ではなく,クライアント/サーバー型アプリケーションの汎用ドライバーとして機能するように設計されたシステムです。ORDAの真価は,データベース検索後の処理,つまりリストボックスに値を表示したり,データを抽出/集計したりする段階で発揮されます。
クラシック言語では,1回のコマンドで複雑なリレーション検索を実行することが困難なため,検索を何度も実行してセット演算を多用する傾向があったかもしれません。ORDAを使用すれば,そのような処理をコンパクトにまとめることができ,パフォーマンスを大幅に向上できる見込みがあります。処理が複雑であればあるほど,ORDAのほうが優勢になるということです。
.query().query().orderBy()
のように連結したORDAクエリはまとめてサーバー側で実行されるのでしょうか
いいえ。オブジェクト記法で1
行にまとめたとしても,それぞれのメンバー関数でサーバーに対するリモートプロシージャーコールが発生します。.query()
でサポートされているさまざまなシンタックスや演算子をフル活用し,できれば1回のクエリで目的のエンティティセレクションを作成できるようにコーディングすることが勧められています。
Qodly CloudはLinuxで動いているとのことですが,Linux版の4D Serverはリリースされないのでしょうか
そのような計画はありません。仮にLinux版の4D Serverが開発されたとしても,ホスティング環境や設定毎に継続的な専門サポートが絶対に必要となるため,運用コストが非常に高価になります。デベロッパーにとってのメリットはまったくありません。