Certain adapters and operators require access to implementing JAR files provided by vendors of software external to TIBCO StreamBase® and TIBCO® Live Datamart. Examples of external JAR files include the JARs that implement TIBCO Enterprise Message Service™ or a third-party JAR file from a database vendor that implements JDBC access to that vendor's database system.
External JAR files may include proprietary technology from their vendors and are made available only to valid license-holders of those products. Other external JAR files are made publicly available, either from a vendor's download site or from a public Maven repository such as Maven Central.
You can also use the instructions on this page to install a WAR file, such as the one that implements TIBCO LiveView™ Web functionality, or other file types similar to JARs.
Whatever their source, external JAR files must be obtained from their vendor and integrated into a Maven repository accessible to your EventFlow or LiveView fragment project. Projects generally do not pass StreamBase typechecking until all required external JAR files are identified as accessible to the Maven build system.
Maven repositories can be located in several layers:
A public repository, such as Maven Central. EventFlow and LiveView fragment projects have access to Maven Central by default.
A vendor-provided public repository specific to that vendor's products. For example, Oracle Corporation provides an Oracle-specific repository.
A site-specific network repository for your organization or department. In general, a site-specific central repository offers the most flexibility for the installation of required external JAR files and for the deployment of Maven artifacts.
A read-only on-disk repository installed by a software package. Before release 10.3.0, TIBCO StreamBase and TIBCO Live Datamart installed a read-only on-disk Maven repository as part of its installation directory structure. If you are using a StreamBase release before 10.3.0, projects can pull StreamBase-provided artifacts from this installed repository, but you cannot add external JAR files to it. This feature is not used in release 10.3.0 and later.
A machine-specific local repository. This is usually the
~/.m2/repositoryfolder of the current user's home directory on your local machine. Using the local machine's repository provides convenience, but any JAR file installed locally for one machine must be installed locally again for every developer and for any QA and deployment machines.
You must install required external JAR files to the Maven system for your EventFlow or LiveView fragment project in one of several ways. The following ways are listed here in preference order.
If your JAR file is made available by its vendor in a public repository such as Maven Central, then you only need to specify the artifact's name and the version you wish to include, using the> option. The JDBC driver for the MySQL database is an example of a JAR file in this category.
If your JAR file is not available from a public repository, but is downloadable under license from its vendor, you can add such downloaded JAR files to your local machine's Maven repository, or to a site-specific network repository. In Maven terminology, this is known as installing a file.
You can run a Maven Install operation with a Studio Run Configuration, or with command-line mvn install command.
The Maven Install options are described in the next sections. To use either method, you must obtain the external JAR file from its vendor, and obtain, as far as possible, its exact groupId, artifactId, and version number.
It is possible for you to run a Maven Install that specifies a JAR dependency based on a local system path. In this case, you specify an absolute path to the JAR file on your local system, or a path relative to your project folder. This method is not recommended because it is not portable. Your system path on a development system is likely not the same as the path to the same JAR file on a QA or deployment system. This method is not described on this page.
For short-term testing ONLY, you can place an implementing JAR file in your project's
src/main/resourcesfolder. However, you must remove such JAR files before creating the archive for your EventFlow fragment or LiveView fragment project. Otherwise, you could end up distributing another company's proprietary JAR files as part of your fragment, possibly without a license to do so. This is especially important to remember for JAR files that implement proprietary interfaces.
Using a Run Configuration in StreamBase Studio is the best method to run a Maven Install operation if you prefer to not use the included mvn command line tool.
The Run Configuration method of Maven-installing a file is described on Editing Maven Install Configurations.
Command-line mvn is included with StreamBase release 10.3.0 and later. If you are using an earlier release, look for a mvn command installed with your operating system, or you may have to install Maven separately.
You can install the JAR file to the local Maven repository, which is specific to the current user on the current machine.
By default, this is the
.m2 directory of the current user's home directory. Use command syntax like the following. (This command is shown on multiple
lines, but must be entered as one long command.)
mvn install:install-file -Dfile=
Fill in the
version information as obtained from the vendor when you downloaded the JAR file. If unavailable, use reasonable values that honor
the vendor origin of the file, as described in the next section.
The following example shows the command to install the JAR file that implements the JDBC driver for access to the Microsoft
SQL Server database. This example presumes that the downloaded JDBC JAR file,
sqljdbc4.jar, is in the current directory. (Again, this command is shown on multiple lines, but must be entered as one long command.)
mvn install:install-file -Dfile=sqljdbc4.jar -DgroupId=com.microsoft -DartifactId=sqlserver-driver -Dversion=4.0 -Dpackaging=jar -DgeneratePom=true
If your site has a central Maven repository, you can also add the
-DLocalRepositoryPath= parameter to install the JAR file in your site's shared repository. Consult your local Maven administrators for the value
to use at your site.
It is not always obvious what values to fill in for the
version fields for a vendor-provided JAR file. Many vendors assume their JAR files will be used with simple references to the file,
and do not provide Maven-compatible information.
Try the following ways to determine the best values to use with Maven Install, whether in a Run Configuration or on the command line.
In all cases, use reasonable values that honor the origin vendor's trade names. Do not invent arbitrary names and version numbers, and do not provide values that match the StreamBase artifact you are building instead of matching the vendor of origin.
If you obtain a JAR file from a public repository such as Maven Central, then by definition, the JAR file contains Maven-compatible information. This will be loaded automatically as Maven adds the dependency for the file from the public repository.
You can almost always provide the exact version number for an external JAR file. The vendor's web site from which you download the external JAR file generally allows you to choose among several versions. You thus know the version number of the file you chose to download.
If you have a Java JRE or JDK on your search PATH, you also have the jar command. You can use the jar command to look inside a downloaded JAR file for the values to use. Use a command like the following to view the JAR file's table of contents:
JAR files are archived with a Zip-compatible compression method, so you can also use an unzip utility or app, if your system has one.
First, look for the presence of a
META-INF/mavenfolder in the JAR. If that is present, and contains a
pom.xmlfile, then you do not need to look farther. In your Maven Install Run Configuration, you only need to specify the
fileparameter, and the other values are filled in at install time from the JAR's internal
However, if you are using command line Maven, you must still specify all values as arguments on the mvn install:install-file command line. In this case, you can extract the JAR file's
pom.xmlto see what values to enter. For example:
jar xf jms-2.0.jar META-INF/maven/javax.jms/jms/pom.xml
If there is no
mavenfolder in your JAR file, then extract the
META-INF/MANIFEST.MFfile. For example, use the following command on the
tibjms.jarfile shipped with TIBCO Enterprise Message Service™ 8.4:
jar xf tibjms.jar META-INF/MANIFEST.MF
MANIFEST.MFfile shows the following contents:
Manifest-Version: 1.0 Implementation-Title: com/tibco/tibjms Implementation-Version: 8.4.0 Specification-Vendor: TIBCO Software Inc. Specification-Title: TIBCO Enterprise Message Service Specification-Version: 8.4.0 Created-By: 1.8.0_74 (Oracle Corporation) Implementation-Vendor: TIBCO Software Inc. Main-Class: com.tibco.tibjms.version
From this information, you can now provide the following values for your Maven Install configuration or command:
Parameter Name Value file
groupId com.tibco.tibjms artifactId ems version 8.4.0 packaging
The JAR file's
MANIFEST.MFfile may not contain as much Maven-compatible information as the previous example. It will almost always provide you with at least a version number.
In this case, provide a reasonable groupId value that is the reverse URL for the vendor, and an artifactId that reflects the intended use for the file. You can use the basename of the JAR file as the artifactId. For example:
Parameter Name Value file
groupId com.example artifactId silent version
When you install a JAR file into a local machine repository or a site-specific network repository, the installed file may not immediately appear in response to a search in the> dialog.
To get the file to appear, you must rebuild Studio's index of the files contained in that repository. Use the following method
for the local machine's
.m2 repository. (Ask your site's Maven administrators for the version of this procedure that applies to a site-specific network
In Studio, open the Maven Repositories view:
Invoke> > .
In the search field, enter
maven. This restricts the list of views to those with Maven in their names.
Select Maven Repositories.
In the Maven Repositories view:
Open Local Repositories.
Select Local Repository.
Right-click and select Rebuild Index from the context menu.
Watch for status messages in Studio's status bar in the lower right. This command sometimes does not start a rebuild on first invocation. If the command returns very quickly with no status messages, re-run the Rebuild Index command.
Watch for Studio status bar messages. The command should take 5 to 15 seconds with many status messages and possibly a dialog box or two.
On macOS, the newly added JAR file should now appear in response to a search in the> dialog, and should now be selectable from the results view of that dialog.
On Windows, the newly added JAR file may still not appear in the Group Id, Artifact Id, and Version fields manually in the Add Dependency dialog.> dialog even after a successful index rebuild. In this case, if you saw a BUILD SUCCESS message when you installed the file, then it is safely installed. You can fill in the