Hi Daniel,

When you add the wcffacility to the container you can specify the timeout:
container.AddFacility<WcfFacility>(f => f.CloseTimeout = TimeSpan.Zero)

Cheers
John





________________________________
From: Daniel Richardson <[email protected]>
To: Castle Project Users <[email protected]>
Sent: Fri, 27 August, 2010 2:28:53 PM
Subject: WcfIntegration - timeout exception?

Hi,

I am using the WcfIntegration client side to instantiate my services.
The lifestyle is transient (this is a requirement of my design) so I
understand that I need to manage the lifecycle of the components. I am
using the below code to instantiate and call my service (where the
ComponentContainer is a wrapper around IWindsorContainer).

This however results in a call to the Dispose method on
WcfChannelHolder, which is throwing an exception due to the call to
release the communication object...
WcfUtils.ReleaseCommunicationObject(Channel, TimeSpan.Zero);
This results in a System.TimeoutException when attempting to close the
channel.

Why is the timeout set to zero? Is anyone else encountering this
issue? Can this be made configurable somehow?

    var search = ComponentContainer.Resolve<ISearchService>();
    try
    {
        var result = search.PolicySearch(new PolicySearchRequest
        {
            RiskReference = "abc"
        });
        System.Console.WriteLine("count: " + result.ResultCount);
    }
    finally
    {
        ComponentContainer.Release(search);
    }

Thanks

-- 
You received this message because you are subscribed to the Google Groups 
"Castle Project Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/castle-project-users?hl=en.


      

-- 
You received this message because you are subscribed to the Google Groups 
"Castle Project Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/castle-project-users?hl=en.

Reply via email to