是否可以在没有“登录”的情况下更改用户状态(或出现登录) [英] Is it possible to change a user status without "Logging in" (or appearing logged in)

查看:110
本文介绍了是否可以在没有“登录”的情况下更改用户状态(或出现登录)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有一个UCMA可信应用程序,它正在Lync / Sfb和第三方系统之间进行用户状态的双向同步。  这个系统经过了一些修改,但没有一个正常工作。

We have a UCMA trusted application that is doing bidirectional syncing of user status between Lync/Sfb and a third party system.  This system has been through a few revisions, none of which work quite right.

初始修订版将以用户身份登录,然后无限期地以该用户身份登录。  这会产生令人遗憾的副作用,即让用户显示为"已登录"。 (但是当他们从
登出Lync / SfB客户端时无法接听电话/即时消息/等)。

The initial revision would log in as a user, and then stay logged in as that user indefinitely.  This had the unfortunate side effect of leaving the user showing up as "logged in" (but unable to take calls/IMs/etc) when they logged out of the Lync/SfB client.

第二种方法是登录/发布预览/退出当用户在第三方系统中更改其状态时 这种方法的问题在于我们无法轻易区分"状态18500注销"与"状态18500注销"之间的区别。
来自我们的应用程序注销与实际退出Lync / SfB客户端的用户。

The second approach taken was to do a login/PublishPresence/logout of the user when they changed their status in the third party system.  The problem with this approach has been that we can't easily tell the difference between a "status 18500 logout" coming from our application logging out vs. a user actually logging out of the Lync/SfB client.

所以,我是想知道我们遇到的任何一个问题是否有任何解决方案。  当我们创建UserEndpoint时,我们将所有ApplicationSharingSupport,AudioSupport,InstantMessagingSupport和VideoSupport设置为UnSupported。  
我们可以设置一个额外的标志,这样我们的连接就不会让用户显示为"在线"状态。如果他们没有以其他方式登录?

So, I was wondering if there were any solutions to either of the problems we ran into.  When we create the UserEndpoint we are setting all of the ApplicationSharingSupport, AudioSupport, InstantMessagingSupport, and VideoSupport to UnSupported.  Is there an additional flag we can set so that our connection won't cause the user to show up as "online" if they are not otherwise logged in?

相反,有没有办法告诉"来源"?注销通知?  我们能够识别登录/注销通知的唯一方法是基于检查AggregatedPresenceState.DeviceType == DeviceType.Undefined。  
我们可以从这些通知中获取任何其他信息以确定其来源吗?

Conversely, is there any way to tell the "source" of a logout notification?  The only way we have been able to identify login/logout notifications is based on checking for AggregatedPresenceState.DeviceType == DeviceType.Undefined.  Is there any other information we can get from these notifications to figure out their source?

最后,有没有办法我们可以在不登录的情况下更新用户状态代理人呢?  这将消除这些问题并大大简化我们的代码。

Finally, is there a way we could update a users status without logging in as the agent at all?  That would eliminate these issues and greatly simplify our code.

推荐答案

如果使用UserEndpointSettings.AutomaticPresencePublicationEnabled设置为False启动端点,那么您的端点最初不会对用户的存在产生任何影响(但您需要订阅LocalOwnerPresence)。  类似地,
如果你有一个UserEndpoint先前已经发布了某个东西的EndpointState(而不是UserState),发布另一个EndpointState属性为50000将导致你的端点脱机 - 导致任何其他活跃的端点获取存在优先权前端聚合中
。  

If you start your endpoint with UserEndpointSettings.AutomaticPresencePublicationEnabled set to False, then your endpoint will not initially have any impact on the presence of the user (but you will need to subscribe to LocalOwnerPresence).  Similarly, if you have a UserEndpoint that has previously published an EndpointState (not UserState) of something, publishing another EndpointState stat of 50000 will result in your endpoint being offline - causing whatever other endpoint is active to take presence precedence in the front-end's aggregation.  

您可以采取的一种方法是将您的应用程序视为字面代表用户的第三方端点。  如果他们发布Lync状态(您应该能够通过在线订阅观看),请让您的端点发布
50000状态以"离线"并让Lync端点接管。  如果他们想要回到第三方,请发布第三方需要在Lync中反映他们在该系统上的状态的状态。

One path you could take is to treat your application as literally representing the third party endpoint for the user.  If they publish a Lync presence state (which you should be able to watch via a presence subscription), have your endpoint publish a 50000 state to go 'offline' and let the Lync endpoint take over.  If they want to go back to the third party, publish whatever presence state the third party needs to reflect in Lync their state on that system.

这有Lync状态的缺点改变覆盖第三方国家(并且第三方必须重新发布以使其再次活动),但我认为它可能会做你想要的。

This has the downside of a Lync state change overwriting a third party state (and the third party would have to re-publish to make it active again), but I think it might do what you want.


这篇关于是否可以在没有“登录”的情况下更改用户状态(或出现登录)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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