You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Dhiraj Bokde (JIRA)" <ji...@apache.org> on 2015/07/14 01:14:04 UTC

[jira] [Commented] (CAMEL-8898) ElementNotFoundException on LinkedIn authentication

    [ https://issues.apache.org/jira/browse/CAMEL-8898?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14625551#comment-14625551 ] 

Dhiraj Bokde commented on CAMEL-8898:
-------------------------------------

Hi Tomas, LinkedIn has changed scopes that are accessible by default. One must get their permissions for most scopes for testing an app. The only ones that worked for me IIRC were r_basicprofile and r_network. They also changed the way exception handling is done when using their login form, which breaks the form parsing logic in the component causing the exception you see. This also means a lot of integration tests can't be run right now without getting LinkedIn's approval for the test application. 
I will update the component to handle error messages from the new login form, to generate a better error message. 

> ElementNotFoundException on LinkedIn authentication
> ---------------------------------------------------
>
>                 Key: CAMEL-8898
>                 URL: https://issues.apache.org/jira/browse/CAMEL-8898
>             Project: Camel
>          Issue Type: Bug
>    Affects Versions: 2.15.2
>            Reporter: Thomas Diesler
>             Fix For: 2.16.0
>
>
> {code}
> Caused by: com.gargoylesoftware.htmlunit.ElementNotFoundException: elementName=[form] attributeName=[name] attributeValue=[oauth2SAuthorizeForm]
> 	at com.gargoylesoftware.htmlunit.html.HtmlPage.getFormByName(HtmlPage.java:669)
> 	at org.apache.camel.component.linkedin.api.LinkedInOAuthRequestFilter.getRefreshToken(LinkedInOAuthRequestFilter.java:169)
> 	at org.apache.camel.component.linkedin.api.LinkedInOAuthRequestFilter.updateOAuthToken(LinkedInOAuthRequestFilter.java:279)
> 	at org.apache.camel.component.linkedin.api.LinkedInOAuthRequestFilter.filter(LinkedInOAuthRequestFilter.java:240)
> 	at org.apache.cxf.jaxrs.client.spec.ClientRequestFilterInterceptor.handleMessage(ClientRequestFilterInterceptor.java:60)
> {code}
> To reproduce:
> 1. add your credentials to src/test/resources/test-options.properties
> 2. run [camel-linkedin-component]$ mvn clean install -P linkedin-test



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)