[ 
https://issues.apache.org/jira/browse/NIFI-11579?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Vrinda Palod updated NIFI-11579:
--------------------------------
    Description: 
Hi Team,

I am trying to run Invokrhttp using StandardOauth2AccessTokenProvider 
controller service. When I set basic authentication and username and password 
in my controller service, it throws below error.

!image-2023-05-22-15-49-35-231.png!

 
InvokeHTTP[id=32a98900-0188-1000-ffff-ffff88fdac58] Failed to properly 
initialize Processor. If still scheduled to run, NiFi will attempt to 
initialize and run the Processor again after the 'Administrative Yield 
Duration' has elapsed. Failure is due to java.io.UncheckedIOException: OAuth2 
access token request failed: java.io.UncheckedIOException: OAuth2 access token 
request failed
 - Caused by: com.fasterxml.jackson.core.JsonParseException: Unrecognized token 
'eyJraWQiOiJlN2RmMGRmNS01ODcwLTQ0MjEtOTA2Mi1iZDkyZmVlYWI0MTMiLCJhbGciOiJQUzUxMiJ9':
 was expecting (JSON String, Number, Array, Object or token 'null', 'true' or 
'false')
at [Source: 
(String)"eyJraWQiOiJlN2RmMGRmNS01ODcwLTQ0MjEtOTA2Mi1iZDkyZmVlYWI0MTMiLCJhbGciOiJQUzUxMiJ9.eyJzdWIiOiJhNzA1NjQ5IiwiYXVkIjoiTGRhcFByb3ZpZGVyIiwibmJmIjoxNjg0NzUwNTM5LCJpc3MiOiJMZGFwUHJvdmlkZXIiLCJwcmVmZXJyZWRfdXNlcm5hbWUiOiJhNzA1NjQ5IiwiZXhwIjoxNjg0NzkzNzM5LCJpYXQiOjE2ODQ3NTA1MzksImp0aSI6ImEwNjc3MjNjLWY5ZTgtNDg2Yi1iNjk5LWM3MThlM2JkYjI0ZSJ9.hnUxMPxCKNluxdLkPrlIy6JWkZAjEvbjWfDRxQjBSVXRyXNrcqgHyBb6Ruvca59xeWmEg1p4wuE5AENuzUEcwnuGX5vX-G0gx-4zY1WYpN7pp6JbXnKUxIXLqr4KMDyHAT0_0aVuNbgqJZ1MLOrfssh4jw_Trxol92N4kb0I4z"[truncated
 513 chars]; line: 1, column: 81]
 

Below is how I am setting up my controller service. There is no issue with 
endpoint url we are using.

!image-2023-05-22-15-51-44-000.png!

 

  was:
Hi Team,

I am trying to run Invokrhttp using StandardOauth2AccessTokenProvider 
controller service. When I set basic authentication and username and password 
in my controller service, it throws below error.

!image-2023-05-22-15-49-35-231.png!

 
InvokeHTTP[id=32a98900-0188-1000-ffff-ffff88fdac58] Failed to properly 
initialize Processor. If still scheduled to run, NiFi will attempt to 
initialize and run the Processor again after the 'Administrative Yield 
Duration' has elapsed. Failure is due to java.io.UncheckedIOException: OAuth2 
access token request failed: java.io.UncheckedIOException: OAuth2 access token 
request failed
- Caused by: com.fasterxml.jackson.core.JsonParseException: Unrecognized token 
'eyJraWQiOiJlN2RmMGRmNS01ODcwLTQ0MjEtOTA2Mi1iZDkyZmVlYWI0MTMiLCJhbGciOiJQUzUxMiJ9':
 was expecting (JSON String, Number, Array, Object or token 'null', 'true' or 
'false')
 at [Source: 
(String)"eyJraWQiOiJlN2RmMGRmNS01ODcwLTQ0MjEtOTA2Mi1iZDkyZmVlYWI0MTMiLCJhbGciOiJQUzUxMiJ9.eyJzdWIiOiJhNzA1NjQ5IiwiYXVkIjoiTGRhcFByb3ZpZGVyIiwibmJmIjoxNjg0NzUwNTM5LCJpc3MiOiJMZGFwUHJvdmlkZXIiLCJwcmVmZXJyZWRfdXNlcm5hbWUiOiJhNzA1NjQ5IiwiZXhwIjoxNjg0NzkzNzM5LCJpYXQiOjE2ODQ3NTA1MzksImp0aSI6ImEwNjc3MjNjLWY5ZTgtNDg2Yi1iNjk5LWM3MThlM2JkYjI0ZSJ9.hnUxMPxCKNluxdLkPrlIy6JWkZAjEvbjWfDRxQjBSVXRyXNrcqgHyBb6Ruvca59xeWmEg1p4wuE5AENuzUEcwnuGX5vX-G0gx-4zY1WYpN7pp6JbXnKUxIXLqr4KMDyHAT0_0aVuNbgqJZ1MLOrfssh4jw_Trxol92N4kb0I4z"[truncated
 513 chars]; line: 1, column: 81]
 

Below is how I am setting up my controller service. There is no issue with 
endpoint url we are using.

 

 


> InvokeHttp is not working when setting Username and password as grant type
> --------------------------------------------------------------------------
>
>                 Key: NIFI-11579
>                 URL: https://issues.apache.org/jira/browse/NIFI-11579
>             Project: Apache NiFi
>          Issue Type: Bug
>    Affects Versions: 1.20.0, 1.21.0
>            Reporter: Vrinda Palod
>            Priority: Critical
>         Attachments: image-2023-05-22-15-49-35-231.png, 
> image-2023-05-22-15-51-44-000.png
>
>
> Hi Team,
> I am trying to run Invokrhttp using StandardOauth2AccessTokenProvider 
> controller service. When I set basic authentication and username and password 
> in my controller service, it throws below error.
> !image-2023-05-22-15-49-35-231.png!
>  
> InvokeHTTP[id=32a98900-0188-1000-ffff-ffff88fdac58] Failed to properly 
> initialize Processor. If still scheduled to run, NiFi will attempt to 
> initialize and run the Processor again after the 'Administrative Yield 
> Duration' has elapsed. Failure is due to java.io.UncheckedIOException: OAuth2 
> access token request failed: java.io.UncheckedIOException: OAuth2 access 
> token request failed
>  - Caused by: com.fasterxml.jackson.core.JsonParseException: Unrecognized 
> token 
> 'eyJraWQiOiJlN2RmMGRmNS01ODcwLTQ0MjEtOTA2Mi1iZDkyZmVlYWI0MTMiLCJhbGciOiJQUzUxMiJ9':
>  was expecting (JSON String, Number, Array, Object or token 'null', 'true' or 
> 'false')
> at [Source: 
> (String)"eyJraWQiOiJlN2RmMGRmNS01ODcwLTQ0MjEtOTA2Mi1iZDkyZmVlYWI0MTMiLCJhbGciOiJQUzUxMiJ9.eyJzdWIiOiJhNzA1NjQ5IiwiYXVkIjoiTGRhcFByb3ZpZGVyIiwibmJmIjoxNjg0NzUwNTM5LCJpc3MiOiJMZGFwUHJvdmlkZXIiLCJwcmVmZXJyZWRfdXNlcm5hbWUiOiJhNzA1NjQ5IiwiZXhwIjoxNjg0NzkzNzM5LCJpYXQiOjE2ODQ3NTA1MzksImp0aSI6ImEwNjc3MjNjLWY5ZTgtNDg2Yi1iNjk5LWM3MThlM2JkYjI0ZSJ9.hnUxMPxCKNluxdLkPrlIy6JWkZAjEvbjWfDRxQjBSVXRyXNrcqgHyBb6Ruvca59xeWmEg1p4wuE5AENuzUEcwnuGX5vX-G0gx-4zY1WYpN7pp6JbXnKUxIXLqr4KMDyHAT0_0aVuNbgqJZ1MLOrfssh4jw_Trxol92N4kb0I4z"[truncated
>  513 chars]; line: 1, column: 81]
>  
> Below is how I am setting up my controller service. There is no issue with 
> endpoint url we are using.
> !image-2023-05-22-15-51-44-000.png!
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to