mulesoft / facebook-connector

Facebook Cloud Connector
Other
4 stars 9 forks source link

Demo application cannot be started #17

Open yurykuchmel opened 11 years ago

yurykuchmel commented 11 years ago

I have just tried to run demo app and got the following error.

Env: eclipse juno, Mule Runtime 3.4.0 ee

Error: cvc-complex-type.2.4.a: Invalid content was found starting with element 'facebook:config'. One of '{"http://www.mulesoft.org/schema/mule/core":annotations, "http://www.mulesoft.org/schema/mule/core":description, "http://www.springframework.org/schema/beans":beans, "http://www.springframework.org/schema/beans":bean, "http://www.springframework.org/schema/context":property-placeholder, "http://www.springframework.org/schema/beans":ref, "http://www.mulesoft.org/schema/mule/core":global-property, "http://www.mulesoft.org/schema/mule/core":configuration, "http://www.mulesoft.org/schema/mule/core":notifications, "http://www.mulesoft.org/schema/mule/core":abstract-extension, "http://www.mulesoft.org/schema/mule/core":abstract-mixed-content-extension, "http://www.mulesoft.org/schema/mule/core":abstract-agent, "http://www.mulesoft.org/schema/mule/core":abstract-security-manager, "http://www.mulesoft.org/schema/mule/core":abstract-transaction-manager, "http://www.mulesoft.org/schema/mule/core":abstract-connector, "http://www.mulesoft.org/schema/mule/core":abstract-global-endpoint, "http://www.mulesoft.org/schema/mule/core":abstract-exception-strategy, "http://www.mulesoft.org/schema/mule/core":abstract-flow-construct, "http://www.mulesoft.org/schema/mule/core":flow, "http://www.mulesoft.org/schema/mule/core":sub-flow, "http://www.mulesoft.org/schema/mule/core":abstract-model, "http://www.mulesoft.org/schema/mule/core":abstract-interceptor-stack, "http://www.mulesoft.org/schema/mule/core":abstract-filter, "http://www.mulesoft.org/schema/mule/core":abstract-transformer, "http://www.mulesoft.org/schema/mule/core":processor-chain, "http://www.mulesoft.org/schema/mule/core":custom-processor, "http://www.mulesoft.org/schema/mule/core":invoke, "http://www.mulesoft.org/schema/mule/core":abstract-global-intercepting-message-processor, "http://www.mulesoft.org/schema/mule/core":custom-queue-store, "http://www.mulesoft.org/schema/mule/core":abstract-processing-strategy}' is expected.

josesahad commented 11 years ago

Fixed. Please take a look now. Regards José

yurykuchmel commented 11 years ago

I am able to run demo application on local environment but it doesn't work. Steps to reproduce: 1. Go to http://localhost:8081/fb-authrorize (returned something). 2. Go to http://localhost:8081/fb-demo (returned Failed to invoke getUserFriends. Message payload is of type: String). Here is exception from the log: Root Exception stack trace: java.lang.IllegalArgumentException: The accessTokenId cannot be null at org.mule.module.facebook.oauth.ManagedAccessTokenProcessInterceptor.execute(ManagedAccessTokenProcessInterceptor.java:46) at org.mule.module.facebook.oauth.ManagedAccessTokenProcessInterceptor.execute(ManagedAccessTokenProcessInterceptor.java:21) at org.mule.module.facebook.oauth.ManagedAccessTokenProcessTemplate.execute(ManagedAccessTokenProcessTemplate.java:32)


I have not changed anything in the demo application except mule.properties file (Twitter and Facebook params added) Please check this.

yurykuchmel commented 11 years ago

I have tried to store accessTokenId from flowVars and add set-session-variable block after facebook:authorize in facebook-authorize flow and call http://localhost:8081/fb-authorize. I ensured that accessTokenId was stored in session vars in scope of facebook-authorize flow. Then I called http://localhost:8081/fb-demo to check value of accessTokenId via logger (logger set after http endpoint and before facebook:get-user-friends processor) in facebook-demo flow:

    <logger message="The user identification is #[flowVars['OAuthAccessTokenId']]

Here is output: Browser: Failed to invoke getUserFriends. Message payload is of type: String Console: INFO 2013-05-31 09:57:36,873 [[demo1].connector.http.mule.default.receiver.03] org.mule.api.processor.LoggerMessageProcessor: The user identification is null Session variable is null Please check this.

yurykuchmel commented 11 years ago

During investigation of this issue I have met one more obstacle on my way. It is pretty the same as https://github.com/mulesoft/facebook-connector/issues/15

vasjav1 commented 9 years ago

i am getting issue, with latest

Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'facebook:config'. One of '{"http://www.springframework.org/schema/beans":beans, "http://www.springframework.org/schema/beans":bean, "http://www.springframework.org/schema/context":property-placeholder, "http://www.springframework.org/schema/beans":ref, "http://www.mulesoft.org/schema/mule/core":global-property, "http://www.mulesoft.org/schema/mule/core":configuration, "http://www.mulesoft.org/schema/mule/core":notifications, "http://www.mulesoft.org/schema/mule/core":abstract-extension, "http://www.mulesoft.org/schema/mule/core":abstract-shared-extension, "http://www.mulesoft.org/schema/mule/core":abstract-mixed-content-extension, "http://www.mulesoft.org/schema/mule/core":abstract-agent, "http://www.mulesoft.org/schema/mule/core":abstract-security-manager, "http://www.mulesoft.org/schema/mule/core":abstract-transaction-manager, "http://www.mulesoft.org/schema/mule/core":abstract-shared-transaction-manager, "http://www.mulesoft.org/schema/mule/core":abstract-connector, "http://www.mulesoft.org/schema/mule/core":abstract-shared-connector, "http://www.mulesoft.org/schema/mule/core":abstract-global-endpoint, "http://www.mulesoft.org/schema/mule/core":abstract-exception-strategy, "http://www.mulesoft.org/schema/mule/core":abstract-flow-construct, "http://www.mulesoft.org/schema/mule/core":flow, "http://www.mulesoft.org/schema/mule/core":sub-flow, "http://www.mulesoft.org/schema/mule/core":abstract-model, "http://www.mulesoft.org/schema/mule/core":abstract-interceptor-stack, "http://www.mulesoft.org/schema/mule/core":abstract-filter, "http://www.mulesoft.org/schema/mule/core":abstract-transformer, "http://www.mulesoft.org/schema/mule/core":processor-chain, "http://www.mulesoft.org/schema/mule/core":custom-processor, "http://www.mulesoft.org/schema/mule/core":abstract-empty-processor, "http://www.mulesoft.org/schema/mule/core":invoke, "http://www.mulesoft.org/schema/mule/core":abstract-global-intercepting-message-processor, "http://www.mulesoft.org/schema/mule/core":custom-queue-store, "http://www.mulesoft.org/schema/mule/core":abstract-processing-strategy}' is expected.

what is the fix for this issue ?

Thanks vasu