0

I am interested in understanding this code, but I am not sure how to get IntelliJ to be able to use Tomcat's PoolProperties. If it were an external library such as the Connector/J or a JSTL library, I might be able to figure it out, but since a web program is already using Tomcat, I am not sure. Should I be using the Project Structure menu to add a Tomcat library?

Jack J
  • 1,514
  • 3
  • 20
  • 28

1 Answers1

1

That depends on the project's dependency management tool you're using. If it's Maven or Gradle, you just need to register the dependency Tomcat JDBC

<dependency>
    <groupId>org.apache.tomcat</groupId>
    <artifactId>tomcat-jdbc</artifactId>
    <version>9.0.16</version>
</dependency>

Or for Gradle

implementation 'org.apache.tomcat:tomcat-jdbc:9.0.16'

Remember to pick a version which is compatible with the Tomcat web server version you're using.
Look at MvnRepository.

If the process of adding dependencies is manual, you need to add the JAR file via the IDEA Module settings. You'd also need to manually copy that JAR to the build artifact (e.g. the WAR file), under the appropriate directory.

LppEdd
  • 20,274
  • 11
  • 84
  • 139