1

テスト環境には SharePoint 2010 があり、カスタム STS (フェデレーション、すべてのサイトはクレームベース) を使用しています。サイトにログインしようとすると、sts ログイン ページにリダイレクトされ、資格情報を入力すると、siteurl/_trust にリダイレクトされ、ここに長時間留まり、タイムアウトします。Windows アプリケーション エラーでは、次のように表示されます。この操作に割り当てられた時間は、より長いタイムアウトの一部であった可能性があります。

別のエラーは次のとおりです。

セキュリティ トークンを発行しようとしたときに例外が発生しました: 00:00:59.9843751 の後に応答を待っている間に要求チャネルがタイムアウトしました。Request への呼び出しに渡されるタイムアウト値を増やすか、Binding の SendTimeout 値を増やします。この操作に割り当てられた時間は、より長いタイムアウトの一部である可能性があります..

何か案は?

4

2 に答える 2

0

SecurityTokenService は WCF サービスであり、他の WCF サービスと同様にサービスのタイムアウトを設定できます。

SharePoint 2010 について言えば、14 個のハイブ フォルダーに WebClients と WebServices という 2 つのフォルダーがあることがわかりました。これらのフォルダーには、SecurityToken サブフォルダーが含まれています。

タイムアウトを変更するには、 receiveTimeout および sendTimeout 属性をバインディング要素に追加して、次のようにする必要があります。

<binding name="spStsBinding" receiveTimeout="00:30:00" sendTimeout="00:30:00">
...
</binding>

14\WebClients\SecurityToken\client.config ファイルと 14\WebServices\SecurityToken\web.config ファイルの両方のすべてのバインディングに対して実行しました。上記の設定では、タイムアウトが 30 分に設定されています。

サービス構成ファイルを編集するために、次のスクリーンショットに示す VS 2008 のツールを使用しました。

ここに画像の説明を入力

お役に立てば幸いです。

于 2011-09-13T11:32:42.767 に答える
0

The solution suggested by Antipod does work when SecurityTokenService is used by your application. However, it doesn't work when it's requested e.g. from Search Application. For example Core Results Search Web Part calls Search Service Application which calls Security Token Service.

In this case SPSecurityContext.SecurityTokenForContext method is called and it requests SecurityTokenService. In this case binding timeouts are not applied because SecurityTokenService WCF binding is initialized in following way:

s_CachedActAsStsBinding = new CustomBinding(bindingElementsInTopDownChannelStackOrder);

where bindingElementsInTopDownChannelStackOrder are taken from configuration in 14\WebClients folder but timeout parameters are not applied.

You can try solutions suggested here: http://www.eventid.net/display.asp?eventid=8306&eventno=10757&source=Microsoft-SharePoint%20Products-SharePoint%20Foundatio&phase=1 but unfortunately they didn't work for me.

于 2011-10-25T10:21:19.887 に答える