0

我目前正在使用 VWD 2010 Express,并且有兴趣更详细地探索 WCF REST,但我找不到“ADO.NET 实体数据模型”模板或有关如何安装它的任何信息。这也被称为 ODATA 实体框架是否正确?我想使用 SQL Express 数据库和后来的 MySQL 数据库创建 WCF REST 服务。

我搜索了在线模板站点,但也没有看到它。

顺便说一句,我现在最感兴趣的是 VB 模板。

此外,假设 ODATA EF 将与 MySQL 数据库一起使用是否准确?是否有专门用于 MySQL 的替代模板?

*更新* 根据 Ian Michael William 的建议,我尝试安装 WcfDataServices.exe。安装失败并在日志文件中显示:

[0A34:08FC][2012-10-29T19:02:14]: Caching bundle from: 'C:\DOCUME~1\Bob\LOCALS~1\Temp\{e0328255-3f36-4c55-b959-379ddaeee93f}\.be\WcfDataServices.exe' to: 'C:\Documents and Settings\All Users.WINDOWS\Application Data\Package Cache\{e0328255-3f36-4c55-b959-379ddaeee93f}\WcfDataServices.exe'
[0A34:08FC][2012-10-29T19:02:15]: Registering bundle dependency provider: {e0328255-3f36-4c55-b959-379ddaeee93f}, version: 5.0.50831.0
[0A34:0BF8][2012-10-29T19:02:16]: Error 0x80092009: Failed to get authenticode certificate embedded in: C:\Documents and Settings\All Users.WINDOWS\Application Data\Package Cache\.unverified\wcf_dataservices
[0A34:0BF8][2012-10-29T19:02:16]: Error 0x80092009: Failed to verify signature of payload: wcf_dataservices
[0A34:0BF8][2012-10-29T19:02:16]: Failed to verify payload: wcf_dataservices at path: C:\Documents and Settings\All Users.WINDOWS\Application Data\Package Cache\.unverified\wcf_dataservices, error: 0x80092009. Deleting file.
[0A34:0BF8][2012-10-29T19:02:16]: Error 0x80092009: Failed to cache payload: wcf_dataservices
[03AC:043C][2012-10-29T19:02:16]: Failed to cache payload: wcf_dataservices from working path: C:\DOCUME~1\Bob\LOCALS~1\Temp\{e0328255-3f36-4c55-b959-379ddaeee93f}\wcf_dataservices, error: 0x80092009.
[03AC:043C][2012-10-29T19:02:16]: Application requested retry of payload: wcf_dataservices, encountered error: 0x80092009. Retrying...
[0A34:0BF8][2012-10-29T19:02:17]: Error 0x80092009: Failed to get authenticode certificate embedded in: C:\Documents and Settings\All Users.WINDOWS\Application Data\Package Cache\.unverified\wcf_dataservices
[0A34:0BF8][2012-10-29T19:02:17]: Error 0x80092009: Failed to verify signature of payload: wcf_dataservices
[0A34:0BF8][2012-10-29T19:02:17]: Failed to verify payload: wcf_dataservices at path: C:\Documents and Settings\All Users.WINDOWS\Application Data\Package Cache\.unverified\wcf_dataservices, error: 0x80092009. Deleting file.
[0A34:0BF8][2012-10-29T19:02:17]: Error 0x80092009: Failed to cache payload: wcf_dataservices
[03AC:043C][2012-10-29T19:02:17]: Failed to cache payload: wcf_dataservices from working path: C:\DOCUME~1\Bob\LOCALS~1\Temp\{e0328255-3f36-4c55-b959-379ddaeee93f}\wcf_dataservices, error: 0x80092009.
[03AC:043C][2012-10-29T19:02:17]: Application requested retry of payload: wcf_dataservices, encountered error: 0x80092009. Retrying...
[0A34:0BF8][2012-10-29T19:02:18]: Error 0x80092009: Failed to get authenticode certificate embedded in: C:\Documents and Settings\All Users.WINDOWS\Application Data\Package Cache\.unverified\wcf_dataservices
[0A34:0BF8][2012-10-29T19:02:18]: Error 0x80092009: Failed to verify signature of payload: wcf_dataservices
[0A34:0BF8][2012-10-29T19:02:18]: Failed to verify payload: wcf_dataservices at path: C:\Documents and Settings\All Users.WINDOWS\Application Data\Package Cache\.unverified\wcf_dataservices, error: 0x80092009. Deleting file.
[0A34:0BF8][2012-10-29T19:02:18]: Error 0x80092009: Failed to cache payload: wcf_dataservices
[03AC:043C][2012-10-29T19:02:18]: Failed to cache payload: wcf_dataservices from working path: C:\DOCUME~1\Bob\LOCALS~1\Temp\{e0328255-3f36-4c55-b959-379ddaeee93f}\wcf_dataservices, error: 0x80092009.
[03AC:043C][2012-10-29T19:02:18]: Error 0x80092009: Failed to cache packages.
[03AC:0E64][2012-10-29T19:02:18]: Error 0x80092009: Failed while waiting for cache thread to complete before executing.
[0A34:08FC][2012-10-29T19:02:18]: Removing bundle dependency provider: {e0328255-3f36-4c55-b959-379ddaeee93f}
[0A34:08FC][2012-10-29T19:02:18]: Removing cached bundle: {e0328255-3f36-4c55-b959-379ddaeee93f}, from path: C:\Documents and Settings\All Users.WINDOWS\Application Data\Package Cache\{e0328255-3f36-4c55-b959-379ddaeee93f}\
[03AC:0E64][2012-10-29T19:02:18]: Apply complete, result: 0x80092009 restart: No
4

2 回答 2

1

如果您在此处运行 WCF 数据服务 5.0 安装程序:

http://www.microsoft.com/en-us/download/details.aspx?id=29306

...您应该会看到 VWD 2010 Express 的 VB 和 C# 项目模板出现在“网络”项目中。

于 2012-10-29T23:25:12.237 回答
1

用于创建 OData 服务的 Microsoft 堆栈称为“WCF 数据服务”,不要与“WCF 服务”或“WCF RIA 服务”混淆。我相信 VWD 2010 Express 确实有一个用于创建新的“WCF 数据服务”的模板。

我们强烈建议开发人员依赖我们的 NuGet 包,我同样建议您使用 EF Code First 来让您的生活更轻松,而不是处理“ADO.NET 实体数据模型”。

我最近一直打算写博客。如果你能等那么久,我会试着写博客文章并在今晚之前发布。(示例将在 C# 中,但其中不会有任何复杂的内容,因此应该很容易转换为 VB.NET。)

我相信有一些供应商可以帮助 EF 与 MySQL 一起工作。我听说它们的质量参差不齐,但我自己没有尝试过。DevArt 在这个领域一直备受赞誉。

当我发布博客文章时,我会更新这个答案。

于 2012-10-29T21:49:28.837 回答