首页 \ 问答 \ WCF和服务发现超时(WCF and service discovery timeout)

WCF和服务发现超时(WCF and service discovery timeout)

有人知道如何设置发现超时。 默认值类似于10-15s,它接缝有点长...

在女巫方面它是否必须配置? 服务? 客户?

服务:

            // Add a ServiceDiscoveryBehavior
            host.Description.Behaviors.Add(new ServiceDiscoveryBehavior());
            // Add a UdpDiscoveryEndpoint
            host.AddServiceEndpoint(new UdpDiscoveryEndpoint());

客户:

    EndpointAddress endPoint = null;

    endPoint = FindCalculatorServiceAddress();

    static EndpointAddress FindCalculatorServiceAddress()
    {
        // Create DiscoveryClient
        DiscoveryClient discoveryClient = new DiscoveryClient(new UdpDiscoveryEndpoint());

        // Find IStringReverser endpoints            
        FindResponse findResponse = discoveryClient.Find(new FindCriteria(typeof(IStringReverser)));

        if (findResponse.Endpoints.Count > 0)
        {
            return findResponse.Endpoints[0].Address;
        }
        else
        {
            return null;
        }
    }

提前致谢


Does someone know how to set the timeout for discovery. The default value is like 10-15s and it seams a bit long...

On witch side does it have to be configured? Service? Client?

Service:

            // Add a ServiceDiscoveryBehavior
            host.Description.Behaviors.Add(new ServiceDiscoveryBehavior());
            // Add a UdpDiscoveryEndpoint
            host.AddServiceEndpoint(new UdpDiscoveryEndpoint());

Client:

    EndpointAddress endPoint = null;

    endPoint = FindCalculatorServiceAddress();

    static EndpointAddress FindCalculatorServiceAddress()
    {
        // Create DiscoveryClient
        DiscoveryClient discoveryClient = new DiscoveryClient(new UdpDiscoveryEndpoint());

        // Find IStringReverser endpoints            
        FindResponse findResponse = discoveryClient.Find(new FindCriteria(typeof(IStringReverser)));

        if (findResponse.Endpoints.Count > 0)
        {
            return findResponse.Endpoints[0].Address;
        }
        else
        {
            return null;
        }
    }

Thanks in advance


原文:https://stackoverflow.com/questions/6112255
更新时间:2023-08-19 07:08

最满意答案

只需在设置中禁用TortoiseSVN 图标叠加 (状态缓存=无)。 您可以使用“检查修改”或“提交”对话框来检查工作副本的状态。

根据我的经验(在Windows XP上),无论如何都不希望图标叠加,因为它们要么不可靠(因为低优先级更新),要么放慢浏览器的速度。


Just disable the TortoiseSVN icon overlays in the settings (Status Cache = None). You can use the "check modifications" or commit dialog instead to examine the status of your working copy.

In my experience (on windows XP) the icon overlays are not desirable anyway because they are either unreliable (because updated with low priority) or they slow down explorer.

相关问答

更多
  • TortoiseSVN现在包括那些在他们的安装文件(或至少它是当我安装它的时候做的)5/23/2012在选择要安装的选项时,我必须点击命令行工具。 现在它位于(tortoisesvnInstallfolder)\bin\svnadmin.exe 只是想我会分享 TortoiseSVN now includes those in their install file (or atleast it did when I installed it 5/23/2012) During the options of ...
  • 在发行说明中 较老的客户端和服务器与1.7台服务器和客户端进行透明的互操作 ... Subversion 1.7服务器使用与Subversion 1.6相同的存储库格式。 因此,可以在1.6.x和1.7.x服务器之间无缝升级和降级,而不会更改磁盘存储库的格式 没有必要做任何事情,你的工作副本将被升级,仍然可以和1.6服务器通话 In the release notes Older clients and servers interoperate transparently with 1.7 servers ...
  • 在svnserve.conf文件中设置以下行: 19 anon-access = none 20 auth-access = write [...] 27 password-db = passwd [...] 39 realm = Name-of-your-repository 46 force-username-case = lower 行号是近似值。 realm应该等于您的存储库的名称。 它可以是任何东西。 password-db是谁有权使用存储库。 默认情况下,该行已被NO ...
  • 简单的方法是使用Subversion附带的svnserve程序。 这应该在Cygwin中。 所有你需要做的就是启动svnserve并使用svn://作为协议而不是file:// 。 首先,您需要修改您的存储库。 你将不得不编辑两个文件: svnserve.conf并passed 。 $ cd /cygdrive/c/.../repos_dir $ cd conf $ vi svnsever.conf # Change the "# password-db = passwd" line & remove ...
  • 如果您在浏览器中打开该URL,您将看到它是一个常规网页,而不是Subversion存储库。 在http://sourceforge.net/scm/?type=svn&group_id=85379找到正确的网址 If you open that URL in your browser, you'll see it's a regular web page, not a Subversion repository. Find the right URL at http://sourceforge.net/sc ...
  • 如果您查看这两个文件,他们会在其中包含示例,您只需取消注释即可。 以下是设置的主要步骤: 在passwd文件中,只需为每个用户添加以下内容: = 在authz中,在文件的底部添加以下行,这些行将授予对整个目录的指定用户的读写访问权限: [/] = rw 最后一步是进入svnserve.conf并取消注释以下行,它们指定您要使用authz和passwd文件作为授权和密码数据库: authz-db = authz password-db = ...
  • .svn文件夹有已检出文件的“原始”副本,所以你可以做的一件事就是svn revert所有内容以获得原始文件: # do this in the same folder that contains the .svn folder svn revert -R . 您可以通过右键单击包含.svn文件夹的文件夹,选择“还原”,检查所需的所有项目,然后单击“确定”,对TortoiseSVN执行相同的操作。 拥有pristines后,只需将它们添加/导入到新的存储库中即可。 您将无法获得任何历史记录,因为它存储在服 ...
  • 1.使用对LAN上的存储库的文件类型访问始终是 坏主意(tm) 2。您的问题的来源(上述除外)是更改版本之间的存储库存储格式和旧版本无法直接读取新版本的存储库:你的客户端的SVN比服务器端更老(更糟糕的是 - 使用|只知道旧格式的repo) 检查客户端主机上的版本(我想,它们是1.6之前的版本)和 更新到版本,与服务器版本兼容(1.9。*的1.7+) 要么 添加任何真实的网络层(svnserve是简单而轻量级的选择)来访问存储库(不再使用file:/// ) - 在这种情况下,旧客户端可以与新的存储库通信 ...
  • 目前,您可以对Subversion的任何服务器版本使用几乎任何客户端版本的Subversion。 您的服务器可以是1.6版本,您的客户端可以是1.8,反之亦然。 没关系。 但是,您不应该使用由一个Subversion客户端创建的工作目录和第二个Subversion客户端,因为无法保证这两个客户端将理解工作目录的布局。 在Subversion的大部分历史中,这条规则被忽视了。 标准的Subversion库创建了一个标准的工作目录布局,大多数客户只是使用它。 我甚至看到人们将他们的工作目录放在Dropbox中并 ...
  • 只需在设置中禁用TortoiseSVN 图标叠加 (状态缓存=无)。 您可以使用“检查修改”或“提交”对话框来检查工作副本的状态。 根据我的经验(在Windows XP上),无论如何都不希望图标叠加,因为它们要么不可靠(因为低优先级更新),要么放慢浏览器的速度。 Just disable the TortoiseSVN icon overlays in the settings (Status Cache = None). You can use the "check modifications" or c ...

相关文章

更多

最新问答

更多
  • 获取MVC 4使用的DisplayMode后缀(Get the DisplayMode Suffix being used by MVC 4)
  • 如何通过引用返回对象?(How is returning an object by reference possible?)
  • 矩阵如何存储在内存中?(How are matrices stored in memory?)
  • 每个请求的Java新会话?(Java New Session For Each Request?)
  • css:浮动div中重叠的标题h1(css: overlapping headlines h1 in floated divs)
  • 无论图像如何,Caffe预测同一类(Caffe predicts same class regardless of image)
  • xcode语法颜色编码解释?(xcode syntax color coding explained?)
  • 在Access 2010 Runtime中使用Office 2000校对工具(Use Office 2000 proofing tools in Access 2010 Runtime)
  • 从单独的Web主机将图像传输到服务器上(Getting images onto server from separate web host)
  • 从旧版本复制文件并保留它们(旧/新版本)(Copy a file from old revision and keep both of them (old / new revision))
  • 西安哪有PLC可控制编程的培训
  • 在Entity Framework中选择基类(Select base class in Entity Framework)
  • 在Android中出现错误“数据集和渲染器应该不为null,并且应该具有相同数量的系列”(Error “Dataset and renderer should be not null and should have the same number of series” in Android)
  • 电脑二级VF有什么用
  • Datamapper Ruby如何添加Hook方法(Datamapper Ruby How to add Hook Method)
  • 金华英语角.
  • 手机软件如何制作
  • 用于Android webview中图像保存的上下文菜单(Context Menu for Image Saving in an Android webview)
  • 注意:未定义的偏移量:PHP(Notice: Undefined offset: PHP)
  • 如何读R中的大数据集[复制](How to read large dataset in R [duplicate])
  • Unity 5 Heighmap与地形宽度/地形长度的分辨率关系?(Unity 5 Heighmap Resolution relationship to terrain width / terrain length?)
  • 如何通知PipedOutputStream线程写入最后一个字节的PipedInputStream线程?(How to notify PipedInputStream thread that PipedOutputStream thread has written last byte?)
  • python的访问器方法有哪些
  • DeviceNetworkInformation:哪个是哪个?(DeviceNetworkInformation: Which is which?)
  • 在Ruby中对组合进行排序(Sorting a combination in Ruby)
  • 网站开发的流程?
  • 使用Zend Framework 2中的JOIN sql检索数据(Retrieve data using JOIN sql in Zend Framework 2)
  • 条带格式类型格式模式编号无法正常工作(Stripes format type format pattern number not working properly)
  • 透明度错误IE11(Transparency bug IE11)
  • linux的基本操作命令。。。