-
Update the schema name in DatabaseConnection.java
-
Remove all duplicate code for creating connection in all DAOs first.
-
Just use the
getConnection
method from DatabaseConnection.java At any instance, do not duplicate the connection strings or copy paste connection methods to stay away from trouble. -
Remove duplicate package tags in
pom.xml
If you have,
username = System.getenv("master")
It means the value is being extracted from the environment. If you want to hard code values instead of passing it in the environment,
please replace it with
username="HARD_CODED_VALUE" in Connection or DatabaseConnection file
If you are not doing either of the above, you will end up with NULL pointer exceptions.
Go to your work bench and find it or type the following in your work bench query editor
Show all databases (schemas)
SHOW DATABASES
Get the current database
SELECT DATABASE();
Paste the following into your bash from root
ls
The above should list pom.xml
as one of its files.
Then it means, you are in the right location to
execute the following commands.
mvn clean install
If build is successful proceed below.
Now, you will have an image built in the target folder.
To run the built maven image paste the following in cli Check for the war image name in your target folder and replace the myapp-*.jar with your image
java -jar ./target/myapp-0.0.1-SNAPSHOT.war
- Athul athulmurali@ccs.neu.edu