Home > Uncategorized > Creating scala uber jar executable

Creating scala uber jar executable

Currently we want to have a single jar that contains all the library so it can be run as standalone tools. This can be done with sbt assembly.

If you are using sbt with IntellijIDEA you should add assembly.sbt under project directory.




Enter the following line into assembly.sbt

addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.4")


Refresh the sbt files from the right hand corner. If you don’t see the SBT pane, you can activate from View-> Tool Windows –> SBT



It will download the plugin to your project.

After it finished downloading. You can then run the sbt assembly command from terminal.


After that you can execute your jar by entering the following command. Please adjust that with your jar name and location

java -jar target\scala-2.10\hive-jdbc-assembly-1.0.jar


Congrats you now have standalone tools in the single uber jar.



Categories: Uncategorized
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: