问题描述
面对一个非常奇怪的问题.
Facing a very strange issue.
遵循本指南 https://azure.microsoft.com/zh-CN/documentation/articles/app-service-mobile-xamarin-forms-blob-storage/,以在Xamarin Forms应用程序中实现文件同步.
Following this guide https://azure.microsoft.com/en-in/documentation/articles/app-service-mobile-xamarin-forms-blob-storage/ to implement File Sync in Xamarin Forms app.
我的服务中的Get方法(GetUser,App服务控制器中的默认get方法)被称为三次&在第三次迭代中,它给了我404资源未找到的错误.前两次迭代工作正常.这是客户电话
The Get method in my service (GetUser, default get method in App service controller) is being called thrice & on the 3rd iteration it gives me a 404 resource not found error. First 2 iterations work fine.This is the client call
await userTable.PullAsync(
null,
userTable.Where(x => x.Email == userEmail), false, new System.Threading.CancellationToken(), null);
如果我删除以下行,
// Initialize file sync
this.client.InitializeFileSyncContext(new TodoItemFileSyncHandler(this), store);
然后代码正常工作,没有任何错误.我需要一些时间来做一个示例项目,与此同时,如果任何人都可以有所启发,那将是有帮助的.
then the code works just fine, without any errors.I will need some time doing a sample project, meanwhile if anyone can shed some light, it will be of help.
谢谢
推荐答案
现在进行了排序,最终我不得不给出它的要求.我也必须为用户创建一个存储控制器,尽管我不需要一个存储控制器,因为我不需要针对用户将任何文件保存在存储中.
this is sorted now, eventually I had to give it what it was asking for. I had to create a storage controller for User too, although I don't need one as I don't need to save any files in storage against the users.
我现在正在进一步测试该应用程序,以查看这是否可以完全解决我的问题,或者我需要为我在应用程序中使用的每个实体都配备一个存储控制器.
I am testing the app further now to see if this sorts my problem completely or I need a storage controller for every entity I use in my app.
在这种情况下,这真的很奇怪,因为我不打算将存储用于所有实体.
In which case it will be really odd as I don't intend to use the storage for all my entities.
这篇关于收到“找不到资源错误".在使用Azure File Sync时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!