Office 365 默认日历的 ID 自动更改 [英] Office 365 default Calendar's ID changes automatically

查看:64
本文介绍了Office 365 默认日历的 ID 自动更改的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的是 Office 365 API 的 V2 DLL 来执行日历操作.我正在保存默认日历的 ID 以对其执行操作.

从过去两年开始,它对我来说工作正常,但最近从过去 1 个月开始,当我试图从我的帐户中获取日历时 - 只是为了检查我正在尝试处理的日历是否可用 - 日历获取的 ID 与从 O365 API 获取的日历 ID 不同

已保存的日历 ID - AQMkADc5NDI0NjFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX8jvkC_BGp2m1nqTgcABqRbG9B8nEivpWgOOBcJGwAAAgEGAAAABqRbG9B80nEivpZcode==aaaaaabq==gwhabaaaabq==gwhabaaaaab

新回复 -

<代码>[{IsBooking":假,IsAdditional":假,"CalendarName": "日历","CalendarId": "AQMkADc5NDI0NjFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX8jvkC_BGp2m1nqTgcABqRbG9B8nEivpWgOOBcJGwAAAgEGAAAABqRbG9B8nEivpWgOOBcJGwABkA==,==已选择":假,IsDefault":真,"HasWriteAccess": 真,"IsFreeBusy": 真,EWS_URL":空,"CalendarColor": "#5D61DF",时区 ID":空}]

然而,更改不是永久性的,一天左右后,再次尝试时,日历 ID 会变回作为默认日历 ID 保存在数据库中的相同 ID.

日历的 ID 是日历的唯一标识符.但是,在许多情况下,它的值会发生变化.有什么方法可以使用changeKey识别相同的日历?知道我们如何使用 changeKey 属性吗?

我也觉得很奇怪,但日历 ID 只更改了最后 30-35 个字符.加密算法可能有问题.请提出建议.

解决方案

我正在和团队一起讨论这个问题.文件夹的 ID 永远不应该改变.它基于邮箱中不可变的存储文件夹的 PR_ENTRYID.我不确定他们在 REST 的 id 中添加了什么额外的好处 - 看起来确实存在一些串联.

至于change key,它与id没有直接关系,所以真的没有办法从change key转换为id.这似乎只是我们这边的一个错误.但当然,只要文件夹发生变化,更改键就会发生变化,并且是一个不透明的 blob(即使对我们在 OData 和 EWS 层也是如此).

有趣的是,您还可以通过提取请求 PR_ENTRYID 扩展属性,并且您应该看到底层 ID 始终相同.但这不会解决任何问题,只能让您了解幕后发生的事情.

我会在收到他们的回复后回复.

I was using V2 DLL of Office 365 API for performing calendar operations. I am saving default calendar's ID for performing operations on it.

It was working fine for me from last two years but lately since last 1 month, when I am trying to fetch calendars from my account - just to check if the calendar is available on whom I am trying to work on - the calendar ID fetched is different from the calendar ID fetched from O365 API

Saved Calendar ID - AQMkADc5NDI0NjFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX8jvkC_BGp2m1nqTgcABqRbG9B8nEivpWgOOBcJGwAAAgEGAAAABqRbG9B8nEivpWgOOBcJGwABH-QZPwAAAA==

New Response -

[{
    "IsBooking": false,
    "IsAdditional": false,
    "CalendarName": "Calendar",
    "CalendarId": "AQMkADc5NDI0NjFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX8jvkC_BGp2m1nqTgcABqRbG9B8nEivpWgOOBcJGwAAAgEGAAAABqRbG9B8nEivpWgOOBcJGwABHKkz6wAAAA==",
    "Selected": false,
    "IsDefault": true,
    "HasWriteAccess": true,
    "IsFreeBusy": true,
    "EWS_URL": null,
    "CalendarColour": "#5D61DF",
    "TimeZoneId": null
}]

However the change is not permanent and after a day or so, when tried again, the calendar id changes back to same id saved in db as default calendar id.

The ID of calendar is calendar's unique identifier. However in many cases, it's value is changed. Is there any way by which we can identify the same calendar using changeKey? Any idea how we can use changeKey property?

I find it strange too but only last 30-35 characters changed for calendar id. May be something wrong with encryption algorithm. Please suggest.

解决方案

I am circling back with the team on this one. The Id of a folder should never change. It is based on the PR_ENTRYID of the folder in store which is immutable within a mailbox. I am not sure what extra goodness they stuff in the id in REST - it does appear there is some concatenation going on.

As for change key, it isn't related directly to the id, so there really isn't a way to convert from the change key to the id. This appears to simply be a bug on our side. But of course, the change key changes whenever there is a change to the folder and is an opaque blob (even to us at the OData and EWS layer).

Of interest, you could also request the PR_ENTRYID extended property with your fetches and you should see that the underlying id is always the same. But that wouldn't fix anything other than to future your understanding of what is going on under the covers.

I will post back when I get a response from them.

这篇关于Office 365 默认日历的 ID 自动更改的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆