非常奇怪的访问问题
需要先解释一下历史,然后是我们迄今为止所做的事情……可能有点长。
我们继承了一个使用 Infragistics Web Controls 与 SQL 对话的 .net Web 应用程序。
已经在开发盒上测试一切正常,并且效果很好。已将其推广到测试箱,一切都很好。然后,已经推出到生产服务器,现在我们遇到了问题......
主要问题是一个页面有几个下拉列表,您从其中一个列表中选择一个值,它与 SQL 框对话,然后填充字段,其中之一是 Infragistics Web 网格。现在,从下拉列表中选择一个值会向 SQL 服务器发送一个查询,并且我知道该查询正在运行并返回数据,就像之前页面上的所有其他字段一样> Web 网格正在填充从查询返回的数据。这将 SQL 方面排除在外。
网页抛出2个错误:
“Sys.InvalidOperationException:类型 Infragistics.Web.UI.ControlMain 已注册。该类型可能被定义多次,或者定义它的脚本文件可能已被加载。可能的原因是在部分更新。”
和
“Sys.ArgumentTypeException:类型为‘Infragistics.Web.UI.WebCurrencyEditor’的对象无法转换为类型‘’。参数名称:实例”
因此,我们将相同的代码推广到三台服务器,并且只有当我尝试时才会失败访问生产服务器上的页面。您首先想到的是 - 权限。
下一步是在另一台机器(台式机)上尝试使用我的详细信息,但仍然出现相同的错误 - 在开发和测试上一切都很好,但在生产上却不然。下一步,在其他机器上尝试其他用户。时好时坏 - 有些用户无法运行 Prod 页面,而其他用户则可以。
因此,从这里开始,查看人们可以进入的所有 AD 组,并与我的进行比较。将我添加到我没有的所有组中,然后再次尝试 - 相同的结果,无法加载页面而不出现上述错误。
所以,我的同事可以从他的机器上访问它,来到我的机器上,登录,并且可以很好地访问它。我去他的机器但无法访问它,我的机器也无法访问它。
下一步 - 我通过 RDC 进入测试服务器,并且可以访问生产设备上的网站。我通过 RDC 进入 DEV 服务器,并且可以访问生产盒上的网站。
所以,我可以算出 SQL 方面,我可以假设代码都很好,就像对其他人一样。已对 AD 组应用了与可以访问它的其他组相同的权限...
我没有做什么?当然有一些简单的事情我没有做......有什么建议吗?对冗长的帖子表示歉意,但解释了我们尝试修复此问题的程度!
need to explain the history first, and then what we have done so far... may be a bit long.
We have inherited a .net web application talking to SQL using Infragistics Web Controls.
Have tested it all fine on a development box, and works great. Have rolled it out to a test box, and all works great. Then, have rolled out to a Production server, and now we get problems.....
The main problem is a page that has several drop down lists, you pick a value from one of the lists, and it talks to the SQL box, and then populates fields, one of them being a Infragistics Web Grid. Now, selecting a value from the drop down list sends a query to the SQL server, and I know that this is working and returning data, as all other fields on the page before the Web Grid are being populated with data returned from the Query. This counts the SQL side out of the equation.
The web page throws 2 errors:
"Sys.InvalidOperationException: Type Infragistics.Web.UI.ControlMain has already been registered. The type may be defined multuiple times or the script file that defines it may have already been loaded. A possible cause is a change of settings during a partial update."
and
"Sys.ArgumentTypeException: Object of type 'Infragistics.Web.UI.WebCurrencyEditor' cannot be converted tp type ''. Parameter name: instance"
So, we have the SAME code being rolled out to THREE servers, and ONLY fails when I try to access the page that is on the Production Server. First thing you will think is - permissions.
Next step was to try on another machine (desktop), with my details, and still get the same error - all good on Dev and Test, but not on Prod. Next step, try other users on other machines. Hit and miss - some users cannot get the Prod page running, others can.
So, from here, looked at all the AD Groups that the people that CAN get in, and compared to mine. Added me to all the groups that I did not have, and tried again - SAME RESULT, cannot load the page without the aforementioned error.
So, my colleague can get to it from HIS machine, comes to mine, logs in, and can get to it fine. I go to HIS machine and cannot get to it, nor can I from mine.
Next step - I RDC into the test server, and I CAN access the web site on the production box. I RDC into the DEV server, and I CAN access the web site on the production box.
So, I can count out the SQL aspect, I can assume the code is all good, as works for others. Permissions have been applied regarding AD groups to be the same as others that can access it...
WHAT AM I NOT DOING? Surely there is something easy I am not doing... Any suggestions? Apologies for the long winded post, but explains the extent we have tried fixing this!!!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我提供了一篇文章的链接,该文章确定了在负载平衡/服务器场场景中出现错误的一个可能原因:AjaxControlToolkit & ScriptResource.axd 负载均衡器(网络场)相关问题。
无论您的问题是否与此有关,直接原因是 ScriptManager 被欺骗两次注册相同的脚本。我认为这与权限没有直接关系。但会有一些潜在的问题:希望 Infragistics 控件本身不会出现错误。
我提出的第一个明显建议是确保所有服务器都运行相同(可能是最新)版本的 AjaxControlToolkit。
I have included a link to an article that identifies one possible cause of the error you are getting in a load-balancing/server-farm scenario: AjaxControlToolkit & ScriptResource.axd load balancer (web farm) related issue.
Whether your issue has anything to do with that or not, the direct cause is that the ScriptManager is being tricked into registering the same script twice. I don't think this has anything to do with permissions directly. But there will be some underlying issue: hopefully not a bug with the Infragistics controls themselves.
First obvious suggestion I would make is to ensure all servers are running the same (and possibly latest) version of the AjaxControlToolkit.