这是一个非常具体的问题,但我没有想法。 I m 采用银灯4.0和WCF数据服务。 错误 网络反应包含出乎意料的章节。 ID=16是在我向银星客户打电话时发生的。 不可否认的是,同样的电话/密码可以更简单地操作,但并非较为复杂(图表中更多的物体),而且我很相信,这只是一次工作。 数据还输入数据库,因此必须在服务器上取得成功。
我先拿到与菲德尔公司提出的不同批量申请的包裹,我可以说的唯一区别是,失败的实体更多。
The DataServiceRequestException is thrown on the client in this code:
this.Context.BeginSaveChanges(SaveChangesOptions.Batch, new AsyncCallback((iar) =>
{
ServiceOperationStatus status = ServiceOperationStatus.Success;
try
{
// Callback method for the async request, retrieves the status of the requested action
DataServiceResponse response = this.Context.EndSaveChanges(iar);
...
The only pages I ve found searching are: http://social.msdn.microsoft.com/Forums/en-US/adodotnetdataservices/thread/c81cb454-01f5-4413-a99b-4ad059c5901f http://social.msdn.microsoft.com/Forums/en-US/adodotnetdataservices/thread/3bb4cef6-7f1e-4875-a140-271fe8ebb3cb/ ~which mentions threading in Azure, but I m pretty sure I don t have that problem. I m calling the save method from a button click command.
我感谢任何想法。 我会开始研究我的数据库,以确保我所期望的某种变化。 在我看来,我更感动。
EDIT: added scrubbed captured $batch from Fiddler (I changed some names and removed the properties to remove domain specific information)
--batchresponse_b7b32f26-5246-4d02-9a6e-24ab6156d798
Content-Type: multipart/mixed; boundary=changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 201 Created
Content-ID: 249
Cache-Control: no-cache
DataServiceVersion: 1.0;
Content-Type: application/atom+xml;charset=utf-8
Location: http://localhost/Services/EDMDataService.svc/DT(314)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<entry xml:base="http://localhost/Services/EDMDataService.svc/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<id>http://localhost/Services/EDMDataService.svc/DT(314)</id>
<title type="text"></title>
<updated>2011-11-15T21:16:31Z</updated>
<author>
<name />
</author>
<link rel="edit" title="DTemplate" href="DT(314)" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/ZFields" type="application/atom+xml;type=feed" title="ZFields" href="DT(314)/ZFields" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/DSize" type="application/atom+xml;type=entry" title="Size" href="DT(314)/DSize" />
<category term="DataModels.DTemplate" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<m:properties>
</m:properties>
</content>
</entry>
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 201 Created
Content-ID: 250
Cache-Control: no-cache
DataServiceVersion: 1.0;
Content-Type: application/atom+xml;charset=utf-8
Location: http://localhost/Services/EDMDataService.svc/ZFields(351)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<entry xml:base="http://localhost/Services/EDMDataService.svc/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<id>http://localhost/Services/EDMDataService.svc/ZFields(351)</id>
<title type="text"></title>
<updated>2011-11-15T21:16:31Z</updated>
<author>
<name />
</author>
<link rel="edit" title="ZField" href="ZFields(351)" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/DT" type="application/atom+xml;type=feed" title="DT" href="ZFields(351)/DT" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/Media" type="application/atom+xml;type=feed" title="Media" href="ZFields(351)/Media" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/Playlists" type="application/atom+xml;type=feed" title="Playlists" href="ZFields(351)/Playlists" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/Layout" type="application/atom+xml;type=entry" title="Layout" href="ZFields(351)/Layout" />
<category term="DataModels.ZField" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<m:properties>
</m:properties>
</content>
</entry>
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 201 Created
Content-ID: 251
Cache-Control: no-cache
DataServiceVersion: 1.0;
Content-Type: application/atom+xml;charset=utf-8
Location: http://localhost/Services/EDMDataService.svc/Layouts(412)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<entry xml:base="http://localhost/Services/EDMDataService.svc/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<id>http://localhost/Services/EDMDataService.svc/Layouts(412)</id>
<title type="text"></title>
<updated>2011-11-15T21:16:31Z</updated>
<author>
<name />
</author>
<link rel="edit" title="Layout" href="Layouts(412)" />
<category term="DataModels.Layout" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<m:properties>
</m:properties>
</content>
</entry>
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 204 No Content
Content-ID: 252
Cache-Control: no-cache
DataServiceVersion: 1.0;
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 204 No Content
Content-ID: 253
Cache-Control: no-cache
DataServiceVersion: 1.0;
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 201 Created
Content-ID: 254
Cache-Control: no-cache
DataServiceVersion: 1.0;
Content-Type: application/atom+xml;charset=utf-8
Location: http://localhost/Services/EDMDataService.svc/Playlists(13410)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<entry xml:base="http://localhost/Services/EDMDataService.svc/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<id>http://localhost/Services/EDMDataService.svc/Playlists(13410)</id>
<title type="text"></title>
<updated>2011-11-15T21:16:31Z</updated>
<author>
<name />
</author>
<link rel="edit" title="Playlist" href="Playlists(13410)" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/PlaylistItems" type="application/atom+xml;type=feed" title="PlaylistItems" href="Playlists(13410)/PlaylistItems" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/SEntities" type="application/atom+xml;type=feed" title="SEntities" href="Playlists(13410)/SEntities" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/SConstraint" type="application/atom+xml;type=entry" title="SConstraint" href="Playlists(13410)/SConstraint" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/PlaylistMode" type="application/atom+xml;type=entry" title="PlaylistMode" href="Playlists(13410)/PlaylistMode" />
<category term="DataModels.Playlist" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<m:properties>
</m:properties>
</content>
</entry>
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 201 Created
Content-ID: 255
Cache-Control: no-cache
DataServiceVersion: 1.0;
Content-Type: application/atom+xml;charset=utf-8
Location: http://localhost/Services/EDMDataService.svc/SConstraints(18677)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<entry xml:base="http://localhost/Services/EDMDataService.svc/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<id>http://localhost/Services/EDMDataService.svc/SConstraints(18677)</id>
<title type="text"></title>
<updated>2011-11-15T21:16:31Z</updated>
<author>
<name />
</author>
<link rel="edit" title="SConstraint" href="SConstraints(18677)" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/TimeRanges" type="application/atom+xml;type=feed" title="TimeRanges" href="SConstraints(18677)/TimeRanges" />
<category term="DataModels.SConstraint" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<m:properties>
</m:properties>
</content>
</entry>
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 204 No Content
Content-ID: 256
Cache-Control: no-cache
DataServiceVersion: 1.0;
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 201 Created
Content-ID: 257
Cache-Control: no-cache
DataServiceVersion: 1.0;
Content-Type: application/atom+xml;charset=utf-8
Location: http://localhost/Services/EDMDataService.svc/TimeRanges(16222)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<entry xml:base="http://localhost/Services/EDMDataService.svc/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<id>http://localhost/Services/EDMDataService.svc/TimeRanges(16222)</id>
<title type="text"></title>
<updated>2011-11-15T21:16:31Z</updated>
<author>
<name />
</author>
<link rel="edit" title="TimeRange" href="TimeRanges(16222)" />
<category term="DataModels.TimeRange" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<m:properties>
</m:properties>
</content>
</entry>
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 204 No Content
Content-ID: 258
Cache-Control: no-cache
DataServiceVersion: 1.0;
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 204 No Content
Content-ID: 259
Cache-Control: no-cache
DataServiceVersion: 1.0;
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 201 Created
Content-ID: 260
Cache-Control: no-cache
DataServiceVersion: 1.0;
Content-Type: application/atom+xml;charset=utf-8
Location: http://localhost/Services/EDMDataService.svc/PlaylistItems(1555717)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<entry xml:base="http://localhost/Services/EDMDataService.svc/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<id>http://localhost/Services/EDMDataService.svc/PlaylistItems(1555717)</id>
<title type="text"></title>
<updated>2011-11-15T21:16:31Z</updated>
<author>
<name />
</author>
<link rel="edit" title="PlaylistItem" href="PlaylistItems(1555717)" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/Playlist" type="application/atom+xml;type=entry" title="Playlist" href="PlaylistItems(1555717)/Playlist" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/SConstraint" type="application/atom+xml;type=entry" title="SConstraint" href="PlaylistItems(1555717)/SConstraint" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/PExclusion" type="application/atom+xml;type=feed" title="PExclusion" href="PlaylistItems(1555717)/PExclusion" />
<category term="DataModels.PlaylistItem" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<m:properties>
</m:properties>
</content>
</entry>
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 204 No Content
Content-ID: 261
Cache-Control: no-cache
DataServiceVersion: 1.0;
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 201 Created
Content-ID: 262
Cache-Control: no-cache
DataServiceVersion: 1.0;
Content-Type: application/atom+xml;charset=utf-8
Location: http://localhost/Services/EDMDataService.svc/SConstraints(18676)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<entry xml:base="http://localhost/Services/EDMDataService.svc/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<id>http://localhost/Services/EDMDataService.svc/SConstraints(18676)</id>
<title type="text"></title>
<updated>2011-11-15T21:16:31Z</updated>
<author>
<name />
</author>
<link rel="edit" title="SConstraint" href="SConstraints(18676)" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/TimeRanges" type="application/atom+xml;type=feed" title="TimeRanges" href="SConstraints(18676)/TimeRanges" />
<category term="DataModels.SConstraint" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<m:properties>
</m:properties>
</content>
</entry>
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 204 No Content
Content-ID: 263
Cache-Control: no-cache
DataServiceVersion: 1.0;
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 201 Created
Content-ID: 264
Cache-Control: no-cache
DataServiceVersion: 1.0;
Content-Type: application/atom+xml;charset=utf-8
Location: http://localhost/Services/EDMDataService.svc/TimeRanges(16221)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<entry xml:base="http://localhost/Services/EDMDataService.svc/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<id>http://localhost/Services/EDMDataService.svc/TimeRanges(16221)</id>
<title type="text"></title>
<updated>2011-11-15T21:16:31Z</updated>
<author>
<name />
</author>
<link rel="edit" title="TimeRange" href="TimeRanges(16221)" />
<category term="DataModels.TimeRange" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<m:properties>
</m:properties>
</content>
</entry>
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914
Content-Type: application/http
Content-Transfer-Encoding: binary
HTTP/1.1 204 No Content
Content-ID: 265
Cache-Control: no-cache
DataServiceVersion: 1.0;
--changesetresponse_d4c80211-1c69-4d36-98fd-df47e2383914--
--batchresponse_b7b32f26-5246-4d02-9a6e-24ab6156d798--