开发者

Get data from another computer using sqlite

Now, i am planning to have 1 main computer and 2 client computer in the sam开发者_StackOverflow中文版e domain. I want to run a form application in the main computer that uses Sqlite database. Then I want to query some data in the main computer from client computers. What would be your suggestions about those 2 questions of mine:

  1. What is the best way to implement this server-client structure to communicate computers.
  2. What is the best way to get a big datatable from main computer that uses sqlite.

I am using .Net Framework 4.0 for Form applications.


you may share the directory, either via Netbios (aka samba, for linux users) or nfs.

however, this is not a good idea, since sqlite locks the file, this may break your implementation if the filesystem fails for whatever reason. you might want to use a real distributed architecture, helping concurrency and load balancing.

another way would be to use sqlite, but proxy it through a web service, made by you specifically for this. it will serve the requests, and it would be run in the same server where you want the sqlite file, so you can avoid sharing the file/directory containing the database


You could set up a WCF service that serializes and deserializes commonly shared model/domain objects. WCF sends it across the wire.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜