I am using sendhttp node and using https POST I keep getting this error in

I am using sendhttp node and using https POST
I keep getting this error in the log. i believe i proved the endpoint, header name, header value, body , user,pwd,domain

Not sure what am i missing.
com.appiancorp.process.engine.UnattendedJavaActivityRequest - An error occurred while executing activity: id=67377, classname=com.appiancorp.process.runtime.activities.HttpRequestActivityNTLM
java.lang.ArrayIndexOutOfBoundsException: 1
          at com.appiancorp.util.http.HttpUtils.buildHttpMethod(HttpUtils.java:87)
          at com.appiancorp.process.runtime.activities.HttpRequestActivityNTLM.run(HttpRequestActivityNTLM.java:83)
          at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:101)
          at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:98)
          at com.appiancorp.common.ContextClassLoaderSwitcher.runInContext(ContextClassLoaderSwitcher.java:25)
          at com.appiancorp.process.runt...

OriginalPostID-93608

OriginalPostID-93608

  Discussion posts and replies are publicly visible

  • ...ime.framework.DefaultActivityExecutor.execute(DefaultActivityExecutor.java:98)
              at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute(UnattendedJavaActivityRequest.java:83)
              at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute0(UnattendedJavaActivityRequest.java:55)
  • It seems you have an extra header name that doesn't have a header value.

    Looking at the source code of this plug-in here is where it is failing:

    if (headerNames_ != null) {
                                  for (int h = 0; h < headerNames_.length; h++) {
                                            m.addRequestHeader(headerNames_[h], headerValues_[h]);

    which makes me think you have two header names in the headerNames field but you only have one header value in the headerValue input.
  • Remember the number of header names needs to match the number of header values. If using an expression ={} make sure both arrays are of the same length.
  • Thanks Eduardo. one solved and something else. i fixed the header issue, it was the headername constant not being multiple and values are multiple
    we did install the certificates using the commandline keytool , the certs are also seen using keytool -list etc. but Appian/Jboss complains that path not found when called from appian model. does SendHttp node need cert path or name etc?
    2013-12-23 18:02:30,412 [default-short-running-threads-threads - 10] ERROR com.appiancorp.process.runtime.activities.HttpRequestActivityNTLM - javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
    javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
              at sun.security.ssl.Alerts.getSSLException(Alerts.java:192)
              at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1886)
  • I am not sure if this plug-in allows you to call web services that require a certificate.

    You may ask that in separate post for the author to confirm.
  • Hi Rayudua,

    I am trying to connect to POST Https rest service using 2 way ssl through HTTP Query Smart Service but I am getting the same error you were getting long time ago. I have uploaded the cert at both the places, admin console in Appian and cacerts file in Java Key store but still not working. I would really appreciate if you can tell me what fix you applied to resolve the error.

    Thanks,
    VM