Silverlight 和 WCF RIA

发布于 2024-10-07 06:52:25 字数 292 浏览 0 评论 0原文

我有一个应用程序,我使用 Silverlight 4 和 WCF RIA 服务向用户呈现数据。在此应用程序中,我还有一个模块(控制台应用程序),负责在数据库中存储一些平面文件(xml 文件)。

我的问题是:根据最佳实践,这两个选项中哪一个是最好的?

  1. 控制台应用程序也可以重用 WCF RIA 服务,将平面文件存储在数据库中。
  2. 创建特定于控制台应用程序的其他 WCF 服务,以将平面文件存储在数据库中(使用 ServiceContract)。

有什么想法吗?或者其他选择? 谢谢!

I have an application where I present the data to the users by using Silverlight 4 and WCF RIA Services. In this application I have also a module (console app) which is responsible to store in the DB some flat files (xml files).

My question is: According to the best practices which one of these two options is the best?

  1. Reuse the WCF RIA Services also for the Console App to store the flat files in DB.
  2. Create others WCF Services specific for the Console App to store the flat files in DB (with ServiceContract).

Any idea? Or other options?
THANKS!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

北城半夏 2024-10-14 06:52:25

我只能说,重用任何可重用的代码始终是最佳实践。我不明白您为什么要为另一个应用程序创建一个全新的服务层?可重用(在多个应用程序/平台上)是 Web 服务的重点。

All I can say is it is always a best practice to reuse any code that can be reused. I don't see why you would want to create a whole new service layer for another application? Being reusable (over multiple applications/platforms) is the point of web services.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文