This website uses cookies. By clicking OK, you consent to the use of cookies. Click Here to learn more about how we use cookies.
OK
  • RSA.com
  • Products
    • Archer®
      • Archer®
      • Advisories
      • Blog
      • Discussions
      • Documentation
      • Downloads
      • Ideas
      • Knowledge Base
      • Archer® Exchange
      • Training
      • Upcoming Events
      • Videos
    • RSA® Fraud & Risk Intelligence Suite
      • RSA® Fraud & Risk Intelligence Suite
      • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Adaptive Authentication for eCommerce
      • RSA® FraudAction Services
      • RSA® Web Threat Detection
      • Upcoming Events
      • Videos
    • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication Cloud
      • Advisories
      • Blog
      • Discussions
      • Documentation
      • Downloads
      • Events
      • Ideas
      • Knowledge Base
      • Training
      • Upcoming Patch Content
      • Videos
    • RSA® Adaptive Authentication Mobile SDK
      • RSA® Adaptive Authentication Mobile SDK
      • Advisories
      • Events
      • Ideas
      • Knowledge Base
      • Request Access
      • Training
    • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise
      • Advisories
      • Blog
      • Discussions
      • Documentation
      • Downloads
      • Events
      • Ideas
      • Knowledge Base
      • Training
      • Videos
    • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • Advisories
      • Blog
      • Discussions
      • Documentation
      • Downloads
      • Events
      • Ideas
      • Knowledge Base
      • Training
      • Videos
    • RSA® Adaptive Authentication for eCommerce
      • RSA® Adaptive Authentication for eCommerce
      • Advisories
      • Blog
      • Discussions
      • Documentation
      • Ideas
      • Knowledge Base
      • Training
      • Videos
    • RSA® FraudAction Services
      • RSA® FraudAction Services
      • Advisories
      • Discussions
      • Documentation
      • Ideas
      • Videos
    • RSA® Web Threat Detection
      • RSA® Web Threat Detection
      • Advisories
      • Blog
      • Discussions
      • Documentation
      • Downloads
      • Ideas
      • Knowledge Base
      • Videos
    • RSA NetWitness® Platform
      • RSA NetWitness® Platform
      • Advisories
      • Blog
      • Discussions
      • Documentation
      • Downloads
      • Ideas
      • Integrations
      • Knowledge Base
      • Training
      • Upcoming Events
      • Videos
    • RSA NetWitness® Detect AI
      • RSA NetWitness® Detect AI
      • Documentation
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
    • RSA NetWitness® Investigator
      • RSA NetWitness® Investigator
      • Documentation
      • Download the Client
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
    • RSA NetWitness® Orchestrator
      • RSA NetWitness® Orchestrator
      • Overview
      • Documentation
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
    • RSA SecurID® Suite
      • RSA SecurID® Suite
      • Advisories
      • Blog
      • Discussions
      • Documentation
      • Downloads
      • Knowledge Base
      • Ideas
      • Integrations
      • Training
      • Videos
    • RSA® Identity Governance & Lifecycle
      • RSA® Identity Governance & Lifecycle
      • Advisories
      • Blog
      • Community Exchange
      • Discussions
      • Documentation
      • Downloads
      • Ideas
      • Knowledge Base
      • Training
      • Upcoming Events
      • Videos
    • RSA SecurID® Access
      • RSA SecurID® Access
      • Advisories
      • Blog
      • Discussions
      • Documentation
      • Downloads
      • Ideas
      • Integrations
      • Knowledge Base
      • Training
      • Upcoming Events
      • Videos
    • Other RSA® Products
      • Other RSA® Products
      • RSA® Access Manager
      • RSA® Data Loss Prevention
      • RSA® Digital Certificate Solutions
      • RSA enVision®
      • RSA® Federated Identity Manager
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
      •  
  • Resources
    • Advisories
      • Product Advisories on RSA Link
      • Archer®
      • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication Hosted
      • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Adaptive Authentication for eCommerce
      • RSA® FraudAction Services
      • RSA® Identity Governance & Lifecycle
      • RSA NetWitness® Platform
      • RSA SecurID® Access
      • RSA® Web Threat Detection
      • All Product Advisories
    • Blogs
      • Blogs on RSA Link
      • Archer®
      • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Adaptive Authentication for eCommerce
      • RSA® Identity Governance & Lifecycle
      • RSA NetWitness® Platform
      • RSA SecurID® Access
      • RSA® Web Threat Detection
      • All Blogs on RSA Link
    • Discussion Forums
      • Discussion Forums
      • Archer®
      • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Adaptive Authentication for eCommerce
      • RSA® FraudAction Services
      • RSA® Identity Governance & Lifecycle
      • RSA NetWitness® Platform
      • RSA SecurID® Access
      • RSA® Web Threat Detection
      • All Discussion Forums on RSA Link
    • Documentation
      • Product Documentation
      • Archer®
      • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication Mobile SDK
      • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Adaptive Authentication for eCommerce
      • RSA® FraudAction Services
      • RSA® Identity Governance & Lifecycle
      • RSA NetWitness® Platform
      • RSA SecurID® Access
      • RSA® Web Threat Detection
      • All Documentation on RSA Link
    • Downloads
      • Product Downloads
      • Archer®
      • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Identity Governance & Lifecycle
      • RSA NetWitness® Platform
      • RSA SecurID® Access
      • RSA® Web Threat Detection
      • All Downloads on RSA Link
    • Ideas
      • Idea Exchange
      • Archer®
      • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication Mobile SDK
      • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Adaptive Authentication for eCommerce
      • RSA® FraudAction Services
      • RSA® Identity Governance & Lifecycle
      • RSA NetWitness® Platform
      • RSA SecurID® Access
      • RSA® Web Threat Detection
      • All Documentation on RSA Link
    • Knowledge Base
      • Knowledge Base
      • Archer®
      • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication Mobile SDK
      • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Adaptive Authentication for eCommerce
      • RSA® Identity Governance & Lifecycle
      • RSA NetWitness® Platform
      • RSA SecurID® Access
      • RSA® Web Threat Detection
      • All Knowledge Base Pages on RSA Link
    • Upcoming Events on RSA Link
      • Upcoming Events
    • Videos
      • Videos on RSA Link
      • Archer®
      • RSA® Adaptive Authentication Cloud
      • RSA® Adaptive Authentication On-Premise
      • RSA® Adaptive Authentication On-Premise (Cassandra)
      • RSA® Adaptive Authentication for eCommerce
      • RSA® Identity Governance & Lifecycle
      • RSA NetWitness® Platform
      • RSA SecurID® Access
      • RSA® Web Threat Detection
      • All Videos on RSA Link
  • Support
    • RSA Link Support
      • RSA Link Support
      • News & Announcements
      • Getting Started
      • Support Forum
      • Support Knowledge Base
      • Ideas & Suggestions
    • RSA Product Support
      • RSA Product Support
      • General Security Advisories and Statements
      • Product Life Cycle
      • Support Information
      •  
      •  
      •  
      •  
      •  
  • RSA Ready
  • RSA University
    • Certification Program
      • Certification Program
    • Course Catalogs
      • Course Catalogs
    • On-Demand Subscriptions
      • On-Demand Subscriptions
      • Archer®
      • RSA NetWitness® Platform
      • RSA SecurID® Suite
    • Product Training
      • Product Training
      • Archer®
      • RSA® Fraud & Risk Intelligence Suite
      • RSA® Identity Governance & Lifecycle
      • RSA NeWitness® Platform
      • RSA SecurID® Access
    • Student Resources
      • Student Resources
      • Access On-Demand Learning
      • Access Virtual Labs
      • Contact RSA University
      • Enrollments & Transcripts
      • Frequently Asked Questions
      • Getting Started
      • Learning Modalities
      • Payments & Cancellations
      • Private Training
      • Training Center Locations
      • Training Credits
      • YouTube Channel
    • Upcoming Events
      • Upcoming Events
      • Full Calendar
      • Conferences
      • Live Classroom Training
      • Live Virtual Classroom Training
      • Webinars
Sign In Register Now
cancel
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for 
Search instead for 
Did you mean: 
Announcements

RSA Link website migration to new platform is in progress

View Status

RSA® Identity Governance & Lifecycle Discussions

Discussions about RSA Identity Governance & Lifecycle.
  • RSA Link
  • :
  • Products
  • :
  • RSA SecurID Suite
  • :
  • RSA Identity Governance & Lifecycle
  • :
  • Discussions
  • :
  • How to consume YAML Web Service using RESTFul Conn...
  • Options
    • Subscribe to RSS Feed
    • Mark Topic as New
    • Mark Topic as Read
    • Float this Topic for Current User
    • Bookmark
    • Subscribe
    • Mute
    • Printer Friendly Page
TusharSutar1
TusharSutar1 Beginner
Beginner
‎2016-06-27 10:01 AM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

How to consume YAML Web Service using RESTFul Connector

Jump to solution

Below is the information of our service available on Open Ldap.

 

role.phpAssign/remove role to/from IDhttps://it.intra.sears.com/it/ds/api/role.phpYAML or JSON
FieldRequired?Description
svc_uidyesService ID
svc_pwyesService password
opyesOperation - add or delete
roleyesDN of role
uidyesEnterprise ID
YAML or JSON
FieldDescription
statusNumeric response code.
ValueMeaning
-1Role assignment/removal error
0Success
1On an add this indicates the user is already a member of the given role
2On a delete this indicates the user is not a member of the given role
messageTerse description of status code
Sample invocation:
--- %YAML:1.0 {"svc_uid": "rmroczk", "svc_pw": "xxx", 
"uid": "btest", "op": "add",
"role": "cn=nsmanageddisabledrole,dc=sears,dc=com"}
Sample result:
--- %YAML:1.0 {"status": 0, "message": "OK"}
or
--- %YAML:1.0 {"status": 1, "message": "already a member"}

 

 

So based on this information, I am configuring RESFul Web Service connector.

Content- Type & Accept both are set to -  application/jason; charset-UTF-8, while running Test I am getting time out on UI & in logs I am getting below error.

2016-06-27 08:56:49.208 [WARN] org.mule.transport.jms.JmsMessageUtils:269 - Header: Content-Type is not compliant with JMS specification (sec. 3.5.1, 3.8.1.1). It will cause problems in your and other applications. Please update your application code to correct this. Mule renamed it to Content_Type

2016-06-27 08:56:49.211 [ERROR] org.mule.exception.DefaultMessagingExceptionStrategy:341 -

********************************************************************************

Message               : Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=jms://AFX.JMS.OUT, connector=ActiveMQJmsConnector

{

  name=jmsConnector

  lifecycle=start

  this=6a08143f

  numberOfConcurrentTransactedReceivers=1

  createMultipleTransactedReceivers=true

  connected=true

  supportedProtocols=[jms]

  serviceOverrides=<none>

}

,  name='endpoint.jms.AFX.JMS.OUT', mep=ONE_WAY, properties={}, transactionConfig=Transaction{factory=null, action=INDIFFERENT, timeout=0}, deleteUnacceptedMessages=false, initialState=started, responseTimeout=10000, endpointEncoding=UTF-8, disableTransportTransformer=false}. Message payload is of type: ActiveMQTextMessage

Code                  : MULE_ERROR--2

--------------------------------------------------------------------------------

Exception stack is:

1. null (java.lang.NullPointerException)

2. Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=jms://AFX.JMS.OUT, connector=ActiveMQJmsConnector

{

  name=jmsConnector

  lifecycle=start

  this=6a08143f

  numberOfConcurrentTransactedReceivers=1

  createMultipleTransactedReceivers=true

  connected=true

  supportedProtocols=[jms]

  serviceOverrides=<none>

}

,  name='endpoint.jms.AFX.JMS.OUT', mep=ONE_WAY, properties={}, transactionConfig=Transaction{factory=null, action=INDIFFERENT, timeout=0}, deleteUnacceptedMessages=false, initialState=started, responseTimeout=10000, endpointEncoding=UTF-8, disableTransportTransformer=false}. Message payload is of type: ActiveMQTextMessage (org.mule.api.transport.DispatchException)

  org.mule.transport.AbstractMessageDispatcher:109 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/transport/DispatchException.html)

--------------------------------------------------------------------------------

Root Exception stack trace:

java.lang.NullPointerException

    + 0 more (set debug level logging or '-Dmule.verbose.exceptions=true' for everything)

********************************************************************************

 

 

2016-06-27 08:56:49.213 [ERROR] org.mule.exception.DefaultMessagingExceptionStrategy:341 -

********************************************************************************

Message               : Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=jms://AFX.JMS.OUT, connector=ActiveMQJmsConnector

{

  name=jmsConnector

  lifecycle=start

  this=6a08143f

  numberOfConcurrentTransactedReceivers=1

  createMultipleTransactedReceivers=true

  connected=true

  supportedProtocols=[jms]

  serviceOverrides=<none>

}

,  name='endpoint.jms.AFX.JMS.OUT', mep=ONE_WAY, properties={}, transactionConfig=Transaction{factory=null, action=INDIFFERENT, timeout=0}, deleteUnacceptedMessages=false, initialState=started, responseTimeout=10000, endpointEncoding=UTF-8, disableTransportTransformer=false}. Message payload is of type: ActiveMQTextMessage

Code                  : MULE_ERROR--2

--------------------------------------------------------------------------------

Exception stack is:

1. null (java.lang.NullPointerException)

2. Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=jms://AFX.JMS.OUT, connector=ActiveMQJmsConnector

{

  name=jmsConnector

  lifecycle=start

  this=6a08143f

  numberOfConcurrentTransactedReceivers=1

  createMultipleTransactedReceivers=true

  connected=true

  supportedProtocols=[jms]

  serviceOverrides=<none>

}

,  name='endpoint.jms.AFX.JMS.OUT', mep=ONE_WAY, properties={}, transactionConfig=Transaction{factory=null, action=INDIFFERENT, timeout=0}, deleteUnacceptedMessages=false, initialState=started, responseTimeout=10000, endpointEncoding=UTF-8, disableTransportTransformer=false}. Message payload is of type: ActiveMQTextMessage (org.mule.api.transport.DispatchException)

  org.mule.transport.AbstractMessageDispatcher:109 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/transport/DispatchException.html)

--------------------------------------------------------------------------------

Root Exception stack trace:

java.lang.NullPointerException

    + 0 more (set debug level logging or '-Dmule.verbose.exceptions=true' for everything)

********************************************************************************

 

 

2016-06-27 08:56:49.214 [INFO] org.mule.api.processor.LoggerMessageProcessor:197 - EXCEPTION redirect flow invoked...

2016-06-27 08:56:49.223 [INFO] org.mule.api.processor.LoggerMessageProcessor:197 - AFX_OUT redirect flow invoked...

2016-06-27 08:56:49.227 [WARN] org.mule.transport.jms.JmsMessageUtils:269 - Header: Content-Type is not compliant with JMS specification (sec. 3.5.1, 3.8.1.1). It will cause problems in your and other applications. Please update your application code to correct this. Mule renamed it to Content_Type

2016-06-27 08:56:49.228 [WARN] org.mule.transport.jms.JmsMessageUtils:269 - Header: Content-Type is not compliant with JMS specification (sec. 3.5.1, 3.8.1.1). It will cause problems in your and other applications. Please update your application code to correct this. Mule renamed it to Content_Type

2016-06-27 08:56:49.231 [ERROR] org.mule.exception.DefaultMessagingExceptionStrategy:341 -

 

 

Labels (1)
Labels
  • Labels:
  • Access Fulfillment Express

  • Tags:
  • Access Fulfillment Express
  • AFX
  • Automated Fulfillment Express
  • Community Thread
  • Discussion
  • Forum Thread
  • Identity G&L
  • Identity Governance & Lifecycle
  • IG&L
  • IGL
  • json
  • RSA Identity
  • RSA Identity G&L
  • RSA Identity Governance & Lifecycle
  • RSA Identity Governance and Lifecycle
  • RSA IGL
  • webservice
  • yaml
0 Likes
Share
Reply
  • All forum topics
  • Previous Topic
  • Next Topic
1 Solution

Accepted Solutions
CoryVeilleux
Employee CoryVeilleux
Employee
In response to TusharSutar1
‎2016-07-19 08:42 AM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

Thank you.

 

I think I see the issue. Can you please edit the connector and uncheck "Asynchronous callback?" on the Settings tab, save the connector, and try again?

 

The asynchronous callback is used in cases where the RESTful web service can't issue an immediate response indicating the result of the operation and instead needs to do further, perhaps long-running, processing and issue a callback later on containing the end result of the operation. This is commonly used when interacting with an enterprise service bus, for example.

 

In your case the web service response contains the result, so you don't need the asynchronous callback. Because it's currently enabled, the test never completes because it's waiting for a results callback that it never receives.

View solution in original post

3 Likes
Share
Reply
18 Replies
DebasishBhattac
DebasishBhattac Beginner
Beginner
‎2016-06-27 10:39 AM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

We do not support content type YAML. We support JSON/XML content.

The log message "Content-Type is not compliant with JMS specification" correctly specifies the problem

2 Likes
Share
Reply
TusharSutar1
TusharSutar1 Beginner
Beginner
In response to DebasishBhattac
‎2016-06-28 04:58 AM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

Hi Debashish,

 

Thank you for replying, I do understand the error, that's why I raised this to community.

Is there any workaround available to consume a YAML response?

 

Or what alternative is there to ovecome this problem?

0 Likes
Share
Reply
PaulDouglas
Employee PaulDouglas
Employee
‎2016-06-29 01:28 AM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

Are you able to provide some more details:

  • What is the application/directory that you're trying to connect with?
  • What commands are you wanting to run?
  • Can you show some screenshots with your configuration?

Thanks

Paul

0 Likes
Share
Reply
TusharSutar1
TusharSutar1 Beginner
Beginner
In response to PaulDouglas
‎2016-07-05 09:03 AM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

Hi Paul,

 

1. The directory is OpenLdap.

2. I want to run commands Add Application role to Account & Remove Application role from Account.(OpenLdap connector don't have commands to add account to Role or remove from Role.)

3. Our OpenLdap guys have an API wherein they allow to add accounts to Ldap Roles & Remove accounts from Ldap roles.

As Ldap connector don't have feature to work with roles, I thought of using Rest Connector as the Ldap service does work with YAML / JASON.

 

The service details are there in above post.

 

The configuration is as below,

RestCon1.JPG

 

I am really not sure about below 2 parts, what configuration is needed?

RestCon2.JPG

RestCon3.JPG

0 Likes
Share
Reply
PaulDouglas
Employee PaulDouglas
Employee
In response to TusharSutar1
‎2016-07-05 09:07 PM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

Your JSON is formatted correctly, so if nothing else, the command should still be sent to the endpoint server.

Are you seeing any errors on the target system? Is it completing correctly?

I'm assuming that the command is sent in JSON, but the return is defaulting to YAML.

If we are unable to consume the YAML format status code, can you try as Regex and see what happens?

Also, can you try removing the Content-Type request header and see what errors occur?

2 Likes
Share
Reply
TusharSutar1
TusharSutar1 Beginner
Beginner
In response to PaulDouglas
‎2016-07-06 07:00 AM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

Hi Paul,

 

1. Yes, you are right it is delivering the request successfully but not able to parse the response.

I am seeing account getting added to the role but I get error after each test suite run.

 

I am getting below error due to parse failure.

       Error code = 2

Failure - Error processing RESTful web service response  Cause: Error processing RESTful web service response: java.lang.StringIndexOutOfBoundsException: String index out of range: 2

 

And I am not at all sure where to put reg ex ?

There are 3 locations given in connector setting Status Code, Brief Header, Detailed Header I have put my regular expression in all of them but still no correct response. I know status code it is not needed.

RestCon5.JPG

RestCon6.JPG

I am not even sure my regular expression is correct or not but I did check it on

Free Online Regular Expression Tester - FreeFormatter.com

 

2. If I remove 'Accept' - type then I am getting same error String Index out of range : 2

 

But if I play bit with Accept Type then error changes,

       Error code = 2

Failure - Error processing RESTful web service response  Cause: Error processing RESTful web service response: java.lang.IllegalStateException: Expected application/jason; UTF-8 but received application/json

So I am keeping Accpet - application/json

This hints that we are getting application/json but something wrong with parsing which is causing String index out Of range :2.

If it is really jason we are receiving then JSONPath also can be used but don't know how to.

Please advise what top do.

 

Thanks,

Tushar.

0 Likes
Share
Reply
CoryVeilleux
Employee CoryVeilleux
Employee
In response to TusharSutar1
‎2016-07-06 07:05 PM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

The important part to keep in mind is that we have 3 fields that we can use to store the representation of the overall success or failure of the request based on the response from the endpoint.

  1. Status Code: This field is the most important. The captured value that we put into this field must be an integer, positive or negative. The value is important too: 0 means that the request/command succeeded, and any other value means that it failed (much like unix/linux exit codes).
  2. Brief Response: This should just be a short message indicating the result of the command. The exact value doesn't matter, but it should conceptually convey what happened.
  3. Detailed Response: This is meant for a more detailed explanation of what happened, and it's mostly important when the request failed. Here you can put information like larger error messages or stack traces - anything that would help in troubleshooting the failure later.

 

One other thing to keep in mind is that there are 2 sections that are used to generate the value that's ultimately stored in the fields. The first section, "Expression," is used to extract a specific value from somewhere in the response, and the next section, which is optional, contains patterns that are used to transform that extracted value. So as an example, if your service will return {"status": "OK"} for success and {"status": "ERROR", "message": "Something bad happened - here are the details"} for failure, you might set the Status Code Expression Type to JsonPath and its expression to status. The extracted value would then be OK for success and ERROR for failure. Since Status Code must be an integer, you would need to add 2 patterns and corresponding replacements in order to convert these to valid values. You would add one pattern of OK with a replacement 0 and another pattern of ERROR with a replacement of something other than 0, like 1. To continue with this example, you could set Brief Response Expression Type to JsonPath and its expression to status as well, but you could remove all patterns and replacements from it so that Brief Response would end up being just either OK or ERROR. Lastly, for Detailed Response you could use Expression Type JsonPath and message for the expression and remove all patterns; for success Detailed Response would be empty and for failure it would be Something bad happened - here are the details.

 

Based on the documentation for your service that you provided, I think you'll just want the following:

 

Status Code

Expression Type: JsonPath

Expression: status

No patterns/replacements

Notes: This field is already 0 for success and other integers for failures, so we don't need to transform it.

 

Brief Response

Expression Type: JsonPath

Expression: message

No patterns/replacements

 

Detailed Response

Expression Type: JsonPath

Expression: message

No patterns/replacements

 

If this doesn't work, then we can turn on debug logging in order to see the actual response from the service and go from there.

5 Likes
Share
Reply
TusharSutar1
TusharSutar1 Beginner
Beginner
In response to CoryVeilleux
‎2016-07-08 05:26 AM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

Thanks for the explanation. It cleared lots of doubts.

 

After changing settings as above, test does add the account to role but no status.

It is getting timed out.

 

How can I enable deug logs?

0 Likes
Share
Reply
BorisLekumovich
Contributor BorisLekumovich Contributor
Contributor
In response to TusharSutar1
‎2016-07-10 03:07 AM
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Jump to solution

Check these posts:

Best practice in debugging AFX connectors?

Video Link : 20615

2 Likes
Share
Reply
  • « Previous
    • 1
    • 2
  • Next »
  • « Previous
    • 1
    • 2
  • Next »
Powered by Khoros
  • Products
  • Resources
  • Solutions
  • RSA University
  • Support
  • RSA Labs
  • RSA Ready
  • About RSA Link
  • Terms & Conditions
  • Privacy Statement
  • Provide Feedback
© 2020 RSA Security LLC or its affiliates.
All rights reserved.