MonoX support board

Start the conversation, ask questions and share tips and solutions with fellow developers.

Non-registered users can only browse through our support boards. Please register now if you want to post your questions. It takes a second and it is completely free. Alternatively, you can log in without registration using your credentials at major sites such as Google, Microsoft Live, OpenId, Facebook, LinkedIn or Yahoo.

OpenSocial support  (Mono Support )

Viewed 17992 time(s), 5 post(s) 1/11/2012 7:29:29 PMby grant.stone007
grant-stone007

grant.stone007

1/11/2012 7:29:29 PM
I am following the mono-software topic entitled "MonoX: ASP.NET support for OpenSocial". I have made sure my web.config has sections and values as the topic describes.

However, when I attempt to go to /MonoX/OpenSocial/OpenSocial.svc I get the "/MonoX/Pages/MonoX/Error.aspx?aspxerrorpath=/MonoX/OpenSocial/OpenSocial.svc" page instead of the expected XRDS response.

I look in the /MonoX/ApplicationData/Logs folder and nothing is logged in log file. I do have error in Windows Event Log - Application

WebHost failed to process a request.
Sender Information: System.ServiceModel.Activation.HostedHttpRequestAsyncResult/15857780
Exception: System.Web.HttpException (0x80004005): There was no channel actively listening at 'http://foczy.com/MonoX/OpenSocial/OpenSocial.svc'. This is often caused by an incorrect address URI. Ensure that the address to which the message is sent matches an address on which a service is listening. ---> System.ServiceModel.EndpointNotFoundException: There was no channel actively listening at 'http://foczy.com/MonoX/OpenSocial/OpenSocial.svc'. This is often caused by an incorrect address URI. Ensure that the address to which the message is sent matches an address on which a service is listening.
at System.ServiceModel.Activation.HostedHttpTransportManager.HttpContextReceived(HostedHttpRequestAsyncResult result)
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest()
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest()
at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result)
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.End(IAsyncResult result)
Process Name: w3wp
Process ID: 54820


I do not know what is wrong by this message. I do know that in my database, both the oaConsumer and oaToken have no records in them.

Is there something perhaps wrong or missing or am I mis-using the OpenSocial feature?
This content has not been rated yet. 
647 Reputation 69 Total posts
pajo

pajo

1/12/2012 10:40:22 AM
Hi,

Can you please give me details about framework version and IIS version where you are trying to run service? Usually this is problem with URI service will register for. If your site is responding to www.foczy.com and foczy.com, service will register for www.foczy.com, WCF doesn't allow you to register same endpoint for two different URIs with same scheme(http, https).

Even if oaConsumer is empty you should get XRDS response, but getting any other resource in MonoX default service implementation will require you to have valid oAuth token and you will need to add at least one consumer to be able to create token. You can find attached script to add default consumer, you can find details about public and secret key in my blog. The oaToken table is used for storing tokens and it's used by oAuth token manager.
This content has not been rated yet. 
629 Reputation 83 Total posts
grant-stone007

grant.stone007

1/12/2012 1:38:58 PM
My framework is v4.0.30319 and my IIS is 7.0.

I ran your db script.

I tried using www.foczy.com as opposed to foczy.com and I get the following error logged in Event Loag - Application...

2012-01-12 06:14:42,484 [13] ERROR DotNetOpenAuth.Messaging [(null)] - Protocol error: Expected message DotNetOpenAuth.OAuth.Messages.AccessProtectedResourceRequest but received DotNetOpenAuth.OAuth.Messages.UserAuthorizationRequest instead.
at DotNetOpenAuth.Messaging.ErrorUtilities.VerifyProtocol(Boolean condition, String message, Object[] args)
at DotNetOpenAuth.Messaging.Channel.TryReadFromRequest[TRequest](HttpRequestInfo httpRequest, TRequest& request)
at DotNetOpenAuth.OAuth.ServiceProvider.ReadProtectedResourceAuthorization(HttpRequestInfo request)
at OpenSocial.Service.OAuthAuthorizationManager.CheckAccessCore(OperationContext operationContext)
at System.ServiceModel.ServiceAuthorizationManager.CheckAccess(OperationContext operationContext)
at System.ServiceModel.ServiceAuthorizationManager.CheckAccess(OperationContext operationContext, Message& message)
at System.ServiceModel.Dispatcher.AuthorizationBehavior.Authorize(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage11(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage1(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)
at System.ServiceModel.Dispatcher.ChannelHandler.DispatchAndReleasePump(RequestContext request, Boolean cleanThread, OperationContext currentOperationContext)
at System.ServiceModel.Dispatcher.ChannelHandler.HandleRequest(RequestContext request, OperationContext currentOperationContext)
at System.ServiceModel.Dispatcher.ChannelHandler.AsyncMessagePump(IAsyncResult result)
at System.ServiceModel.Dispatcher.ChannelHandler.OnAsyncReceiveComplete(IAsyncResult result)
at System.Runtime.Fx.AsyncThunk.UnhandledExceptionFrame(IAsyncResult result)
at System.Runtime.AsyncResult.Complete(Boolean completedSynchronously)
at System.Runtime.InputQueue`1.AsyncQueueReader.Set(Item item)
at System.Runtime.InputQueue`1.EnqueueAndDispatch(Item item, Boolean canDispatchOnThisThread)
at System.Runtime.InputQueue`1.EnqueueAndDispatch(T item, Action dequeuedCallback, Boolean canDispatchOnThisThread)
at System.ServiceModel.Channels.SingletonChannelAcceptor`3.Enqueue(QueueItemType item, Action dequeuedCallback, Boolean canDispatchOnThisThread)
at System.ServiceModel.Channels.HttpChannelListener.HttpContextReceived(HttpRequestContext context, Action callback)
at System.ServiceModel.Activation.HostedHttpTransportManager.HttpContextReceived(HostedHttpRequestAsyncResult result)
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest()
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest()
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.OnBeginRequest(Object state)
at System.ServiceModel.AspNetPartialTrustHelpers.PartialTrustInvoke(ContextCallback callback, Object state)
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.OnBeginRequestWithFlow(Object state)
at System.Runtime.IOThreadScheduler.ScheduledOverlapped.IOCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)
at System.Runtime.Fx.IOCompletionThunk.UnhandledExceptionFrame(UInt32 error, UInt32 bytesRead, NativeOverlapped* nativeOverlapped)
at System.Threading._IOCompletionCallback.PerformIOCompletionCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* pOVERLAP)

This content has not been rated yet. 
647 Reputation 69 Total posts
pajo

pajo

1/13/2012 9:55:55 AM
Hi,

There were some issues with XRDS, I have attached fixed version.
Rated 5.00, 1 vote(s). 
629 Reputation 83 Total posts
grant-stone007

grant.stone007

1/13/2012 3:23:43 PM
Yes XRDS is listing correctly. It is only listening on the www.foczy.com and not foczy.com but that is OK. I will publish news to my members to use www.foczy.com.

Thank you.
This content has not been rated yet. 
647 Reputation 69 Total posts