JDBC Driver for TigerGraph DB - java

I am trying to connect to Tigergraph DB from Spark using IntelliJ IDE. Can anyone help with the jdbc driver (.jar) file? I am looking for "com.tigergraph.jdbc.Driver".
I did find below gitHub repository with all the required .java file. But, I am not sure how to use it inside my spark project. https://github.com/tigergraph/ecosys/tree/master/tools/etl/tg-jdbc-driver
Can anyone help me on this?

It can be done quickly. I hope you are familiar with maven and git.
[[Command prompt]] git clone https://github.com/tigergraph/ecosys.git
Navigate to [[project checkout path]]\ecosys\tools\etl\tg-jdbc-driver
execute mvn clean compile install -Dmaven.test.skip=true
and then, once build is okay you will get the JAR in the folder
You can use this JAR afterwards in your project.

according to the GitHub documentation of tg-jdbc-driver repository, you need to build the JAR and then you can include this dependency in your pom.xml and start using it's API.
Some helpful resources:
https://medium.com/tigergraph/data-lakes-will-yield-more-business-value-when-combined-with-graph-databases-928181dffe24
https://www.programmersought.com/article/68114478380/

Related

Adding local jar (oracle driver) to Maven and Bamboo

I need to use the oracle database driver (oracle.jdbc.driver.OracleDriver) for a project but Oracle does not have a Maven repository for it, so the only way that I have found is to download it onto my machine and then "install" the .jar to Maven as seen in this article.
However, now it is time to add the project to my work's Bamboo build server, but of course the build fails because it can't find the oracle driver.
My question is: how is this sort of thing generally handled? There doesn't seem to be a way to "add" a .jar to a Bamboo build and then point Maven on Bamboo to that .jar. Another alternative that I'm trying is putting the oracle .jar on an internal git repository but I don't know how to point Maven to pull a .jar from a git repository (my current understanding is that maven repos and git repos are different thing entirely).
Any tips or suggestions appreciated, thank you.
The usual way is to set up a Nexus/Artifactory on a server. This server is used for the built artifacts (your Bamboo deploys the EARs/WARs/JARs to it), to proxy external repositories (not necessary, but will speed up things) and to manage third party jars that are not available elsewhere.
In your settings.xml you just point to this Nexus/Artifactory and do the same for the Bamboo.

JPA not works when run via executable jar, but works in eclipse

When executed in Eclipse, it works fine. But when executed via executable jar facing the following error
Here is the persistence.xml file I have been using.
Following are the pom entries that I am using for JPA
If anyone faced the same issue and resolved, please share the ideas. As we need to deliver for testing, any help at earliest would be very helpful.
It's possible that your jar file doesn't include external jar files. Try using the assembly plugin for maven:
See a description of it here.
Please try with this in provider
org.hibernate.jpa.HibernatePersistenceProvider

What are the correct jar files for Jzy3d API?

Can someone tell me which .jar files to download to get the newest Jzy3d version? I have looked at their website but I don't know which files to download.
The easiest way is to use maven to build Jzy3d charts. Install maven if you don't have it.
Add a maven pom.xml file at the root of your project, similar to this one. Running the following command will import dependencies and build the project
mvn clean test install
If you want to retrieve jar manually (discouraged), you can get jzy3d builds here. You will also have to download jzy3d dependencies (jogl, jply, jmathio, jdt-core, miglayout, opencsv, etc) as listed in jzy3d-api pom file.

Adding a local jar into mvn clean package result

I'm building a SonarQube plugin and I need to use Maven to achieve it, I must use the goals clean package to create the jar file that acts as the plugin. My problem is that I need to load either a local jar file, which didn't worked as I tried using: <systemPath>${project.basedir}/lib/epsilon-1.3-core.jar</systemPath> to load it as a dependency and Maven wasn't able to resolve it or I must load three external projects which are at my workspace but I don't know how to tell maven to include them.
Could someone help me to do this? I'd really appreciate it! Using my own Maven repo (with Nexus for example) isn't an option.
I had to do a local maven repository loading the plugins of Epsilon as jar files, it's a temp solution while the Epsilon Team setup a maven repo.

mysql.jdbc.driver class not found exception

I am building an app which connect to MySQL database using intelij idea. I have imported jdbc driver through modules > dependencies and it works great when I run the app through IDE. But when I build an artifact using build > build artifacts > rebuild (tried clean and build also) and I ran it using cmd I get the following error:
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
I have also tried cleaning and rebuilding project but it didnt help.
Any ideas what am I doing wrong?
The JDBC driver JAR file needs to be on the classpath when you run the code. For example, if you are running your application like:
java -jar Application.jar
You should use:
java -classpath /path/to/Driver.jar -jar Application.jar
Found a solution myself. Intelij idea was not adding new library dependency to artifact build path. So the solution is to recreate artifact and then module dependency is added. Or just add it manualy to artifact settings
Try to use maven, it resolve all dependencies for you.
In IDEA you can start maven project:
File->New->Project: chose Maven
You don't need to search & place your dependency jars in classpath manually, just add another one dependency in pom.xml and maven download it for you.
To know which dependency snippet you need you - just search it here

Categories

Resources