Can org.apache.httpcomponents.httpclient_4.5.1.jar be replaced with org.apache.httpcomponents.httpclient_4.5.13.jar and the .classpath be modified?

you are confused. you have to figure it out what has to be local and what global.
i already gave the hints. do your homework.

Let’s say we need to pass “THE_MOST_SECRET_DATA” at runtime to Katalon (regardless of where it’s stored for the time being). How do we do that?

Is there some generic aproach that can be used regardless of where the sensitive data are stored?

For example, in Can org.apache.httpcomponents.httpclient_4.5.1.jar be replaced with org.apache.httpcomponents.httpclient_4.5.13.jar and the .classpath be modified? - #10 by kazurayam there is a concrete solution for the case when the data is stored in local Mac’s Keychain , which is great but it cannot be used in other cases,

If I were to make my local PC and my remote CI/CD server to share some information, I would store the information in AWS S3 storage. I would choose S3 because I am accustomed to it; others may choose Google Drive or something in Microsoft Azure. I would allocate restricted access permissions to the S3 storage by the AWS way.

I will write my test script code to read the information from AWS S3 storage. I know how to write my Groovy Test Case script so that they communicate with AWS S3. It requires a custom (a bit deep) coding technique. Unfortunately Katalon does not provide any built-in capabilty to use AWS S3.

Though you may ask a recursive question: how to manage the credential information that manages access to AWS S3 itself. Well, that is the first topic you need to learn for getting started with AWS in general. See the following article for example

Too much complicated for you? Then you should invent your own concrete way.

1 Like

The following post shows a sample Katalon project that reads data from AWS S3.

1 Like

see the other topic: API/Web Service Encoded Variables - #15 by bionel

Thanks again for all your help, @kazurayam!

And, also, I’d just like to let you know that there is a very unpleasnt side effect of including twilio-8.34.1-jar-with-dependencies.jar in the Drivers folder

I am sorry to hear that but I am not surprised with it. Changing the version of dependent jars is always risky.

Technically, it wasn’t changing the version of the dependent jar. When I excluded the org.apache.httpcomponents.httpclient_4.5.1.jar which was built-in out of the .classpath file, this exclusion didn’t cause any issue with the HTML report in our Jenkins (with Katalon plugin). The HTML reports dissapear only when twilio-8.34.1-jar-with-dependencies.jar is added to the Driver folder .

The only idea I presently have is to create a separate Katalon project for the test that uses twilio-8.34.1-jar-with-dependencies.jar and run 2 jobs in Jenkins (1.the regular job for the regular project w/o that jar 2. the job with the Twilio jar)

Katalon Studio UI, tool bar > Help > Error Log

This will show you a log from Java VM which executed your test scripts, like this

You may find some Stack Trace messages. It might suggest what happened. It might be good to know.

Though you would still find it difficult to fix the problem anyway.

1 Like

Are you aware of the content of the “-with-dependencies.jar” file?

I would guess it includes several OSS jar files, not only the httpclient, among them there could be some OSS product built-in Katalon Studio as well. If it is the case, you might have 2 versions of a single product. That would cause accidental collision of the version of the product.

I would personally never inject a “-with-depencencies” type of jar file into Katalon Studio, because I would loose control of dependent jar’s version.

I would advise you, you had better list up the dependent jar files contained in the “-with-dependencies” jar. Check the depentent jar and identify which one you need in Katalon project. And you want to include only those jars in Katalon Project which you desperately need.

Not sure what OSS jar files are. The POM is here https://repo1.maven.org/maven2/com/twilio/sdk/twilio/8.34.1/twilio-8.34.1.pom.
Could it be because different versions of the following jar is included in the twilio-8.34.1-jar-with-dependencies.jar


and the classpath:

?

I meant “OSS” standing for “Open Source Software”

The POM shows full list of dependencies

<dependencies>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.18.16</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>commons-codec</groupId>
<artifactId>commons-codec</artifactId>
<version>1.15</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.7</version>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-api</artifactId>
<version>${jjwt.version}</version>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-jackson</artifactId>
<version>${jjwt.version}</version>
<exclusions>
<exclusion>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-impl</artifactId>
<version>${jjwt.version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.5.13</version>
<exclusions>
<exclusion>
<groupId>commons-codec</groupId>
<artifactId>commons-codec</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpcore</artifactId>
<version>4.4.13</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
<version>${jackson.version}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
<version>${jackson.version}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>${jackson.version}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.datatype</groupId>
<artifactId>jackson-datatype-jsr310</artifactId>
<version>${jackson.version}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.dataformat</groupId>
<artifactId>jackson-dataformat-xml</artifactId>
<version>${jackson.version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.7.30</version>
</dependency>
<dependency>
<groupId>javax.xml.bind</groupId>
<artifactId>jaxb-api</artifactId>
<version>2.3.1</version>
</dependency>
<dependency>
<groupId>org.jmockit</groupId>
<artifactId>jmockit</artifactId>
<version>1.24</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.13.2</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.tngtech.archunit</groupId>
<artifactId>archunit</artifactId>
<version>0.23.0</version>
<scope>test</scope>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>nl.jqno.equalsverifier</groupId>
<artifactId>equalsverifier</artifactId>
<version>3.6.1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.squareup.okhttp3</groupId>
<artifactId>mockwebserver</artifactId>
<version>4.9.1</version>
<scope>test</scope>
<exclusions>
<exclusion>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
</exclusion>
<exclusion>
<groupId>com.squareup.okio</groupId>
<artifactId>okio</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.squareup.okio</groupId>
<artifactId>okio</artifactId>
<version>2.9.0</version>
<scope>test</scope>
</dependency>
</dependencies>

There I can find several products which are built-in (though possibly different version) in Katalon Studio.

Anyway I can not see what is the real cause of your problem. All I can suggest to you is to look into the Error log and try to find any evidence what happened …

Thanks, @kazurayam . There is no problem with the HTML report when running locally. It dissapears only when running on Jenkins (with Katalon plugin). I cannot see the Error Log there.

On my mac machine, the Error log file is saved into

/Applications/Katalon Studio.app/Contents/MacOS/config/.metadata/.log

in other word, it is at

<your katalon installation dir>/config/.metadata/.log

I don’t know what is your katalon installation dir is

Thanks @kazurayam . I apologize for not making myself clear. What I meant is that I cannot see the Error Log in the folder with results of running on our Jenkins (with Katalon plugin):

The .log file is NOT found in the project’s <project dir>/Reports folder.

As I wrote, the .log file will be found at <your katalon installation dir>/config/.metadata/.log

The last screenshot you provided shows that

  • the execution0.log file is there in the Reports folder. It has the size of 19KB, which looks normal.
  • but the HTML report file is not there

The HTML report is compiled by a process which executes a Test Suite using the execution0.log files as input.

This situation implies to me that the process failed while it was generating the HTML report.

The process would have emitted some diagnostics messages (Exception message, Stack Trace, etc) in the .log file.

You should find and read the .log file.

I have no access to the nodes on which the Jenkins job is run. Such nodes are created automatically on demand and Katalon gets installed on them from scrach each time. I can only see the workspace, which is wiped out later:

Then you have 3 options.

  1. Just give up performing your test on the remote Jenkins node with your special jar included. Your test works OK on your local PC, doesn’t it? If you can perform your test manually, it’s good enough, isn’t it?
  2. Ask your system administrators so that they help you solve your problem. You only need to read the .log file. Possilbly they can copy the .log file to somewhere for you to read.
  3. Try debugging for yourself; you want to produce a Jenkins environment on a machine for which you have full access (e.g, your local Windows PC), and on it you want try to reproduce your problem. This would be a good lesson for you to understand Jenkins thoroughly.

up to you.

1 Like