Re: Adding JDBC drivers to Clojars
Leinigen uses maven repos to satisfy project clj dependencies, but there is nothing stopping you from putting your jar directly on the classpath. The idiom for local jars is to put them in "libs/". In this case you do *not* mention this dependency in your project.clj, but the jar will be on the classpath at runtime If you still want project.clj to mention the dep but do not want to host the jar somewhere, you can make a local maven repository in your project itself (checked-in), and tell leinigen to use it. This stackoverflow answer describes that process: http://stackoverflow.com/a/9917149/1002469 If you really want to host the jar on a remote, non-private repo, use the full 4-arg form of the lein deploy command. See "lein help deploy" However, make sure this HP even lets you redistribute its jar in this way! On Friday, September 23, 2016 at 10:19:10 AM UTC-5, Eddie wrote: > > Thanks for the reply. > > I was under the impression that the jdbc driver (or any jar you want to > use as a dependency) needs to be hosted on some kind of maven repository. > Am I wrong about that? > > Here is the official download link for the Vertica jdbc driver: > https://my.vertica.com/client_drivers/7.2.x/7.2.3-0/vertica-jdbc-7.2.3-0.jar > As far as I can tell, it isn't in a maven repository. Is there still a way > to tell lein to look at this address to pull the jar? > > Thanks! > > > > > On Friday, September 23, 2016 at 11:02:07 AM UTC-4, Walter van der Laan > wrote: >> >> There is no need to push jdbc drivers to clojars. >> >> I have never used Vertica but perhaps it helps if I show you how to add >> the two jdbc-drivers that I do use. >> >> >> Example 1; postgres >> >> The details for the postgres-driver can be found here: >> http://mvnrepository.com/artifact/org.postgresql/postgresql >> >> The download-link for the jar is; >> http://mvnrepository.com/artifact/org.postgresql/postgresql/9.4.1211.jre7 >> >> This translates to this dependency in my project.clj: >> [org.postgresql/postgresql "9.4.1211"] >> >> >> Example 2; h2 >> >> The details for the h2-driver can be found here: >> http://h2database.com/html/download.html >> >> The download-link for the jar is; >> http://repo2.maven.org/maven2/com/h2database/h2/1.4.192/h2-1.4.192.jar >> >> This translates to this dependency in my project.clj: [com.h2database/h2 >> "1.3.176"] >> >> -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Adding JDBC drivers to Clojars
Good to know! Thanks for the info on the alternatives. I have used lein-localrepo before, but was hoping for something that could be more easily shared with others. Looks like it is still the best course. Thanks! On Friday, September 23, 2016 at 11:58:39 AM UTC-4, Sean Corfield wrote: > > Some JDBC drivers are not available in public Maven-style repositories > (such as Microsoft’s Type 4 SQL Server JDBC driver) and that’s usually > because there are restrictions on distribution, preventing third party > sites from hosting them legally. > > > > I searched Maven and you seem to be correct that Vertica does not have its > drivers there. Check their licensing agreements because I doubt you could > legally put them up on Clojars. > > > > If you only need the driver locally for a project you are working on, then > download the JAR and use lein-localrepo to put it into your local Maven > repository cache (in ~/.m2). > > > > If you need to share the driver with colleagues at work, then you’ll > either have to have your colleagues do the same (and your build server), or > you’ll need a private repository for work. > > > > The latter is relatively easy. We run Archiva on an internal server at > work and all our builds access it from there (just adding the URL to that > repository to our build.boot files – Leiningen also supports this). Or, if > you have a private S3 account, you could host it there via S3 Wagon. > > > > Sean Corfield -- (970) FOR-SEAN -- (904) 302-SEAN > An Architect's View -- http://corfield.org/ > > "If you're not annoying somebody, you're not really alive." > -- Margaret Atwood > > > > On 9/23/16, 8:19 AM, "Eddie"behalf of ededdi...@gmail.com > wrote: > > > > Thanks for the reply. > > > > I was under the impression that the jdbc driver (or any jar you want to > use as a dependency) needs to be hosted on some kind of maven repository. > Am I wrong about that? > > > > Here is the official download link for the Vertica jdbc driver: > https://my.vertica.com/client_drivers/7.2.x/7.2.3-0/vertica-jdbc-7.2.3-0.jar > > As far as I can tell, it isn't in a maven repository. Is there still a way > to tell lein to look at this address to pull the jar? > > > > Thanks! > > > > > > > > On Friday, September 23, 2016 at 11:02:07 AM UTC-4, Walter van der Laan > wrote: > > There is no need to push jdbc drivers to clojars. > > > > I have never used Vertica but perhaps it helps if I show you how to add > the two jdbc-drivers that I do use. > > > > > > Example 1; postgres > > > > The details for the postgres-driver can be found here: > http://mvnrepository.com/artifact/org.postgresql/postgresql > > > > The download-link for the jar is; > http://mvnrepository.com/artifact/org.postgresql/postgresql/9.4.1211.jre7 > > > > This translates to this dependency in my project.clj: > [org.postgresql/postgresql "9.4.1211"] > > > > > > Example 2; h2 > > > > The details for the h2-driver can be found here: > http://h2database.com/html/download.html > > > > The download-link for the jar is; > http://repo2.maven.org/maven2/com/h2database/h2/1.4.192/h2-1.4.192.jar > > > > This translates to this dependency in my project.clj: [com.h2database/h2 > "1.3.176"] > > > > > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Adding JDBC drivers to Clojars
Some JDBC drivers are not available in public Maven-style repositories (such as Microsoft’s Type 4 SQL Server JDBC driver) and that’s usually because there are restrictions on distribution, preventing third party sites from hosting them legally. I searched Maven and you seem to be correct that Vertica does not have its drivers there. Check their licensing agreements because I doubt you could legally put them up on Clojars. If you only need the driver locally for a project you are working on, then download the JAR and use lein-localrepo to put it into your local Maven repository cache (in ~/.m2). If you need to share the driver with colleagues at work, then you’ll either have to have your colleagues do the same (and your build server), or you’ll need a private repository for work. The latter is relatively easy. We run Archiva on an internal server at work and all our builds access it from there (just adding the URL to that repository to our build.boot files – Leiningen also supports this). Or, if you have a private S3 account, you could host it there via S3 Wagon. Sean Corfield -- (970) FOR-SEAN -- (904) 302-SEAN An Architect's View -- http://corfield.org/ "If you're not annoying somebody, you're not really alive." -- Margaret Atwood On 9/23/16, 8:19 AM, "Eddie"wrote: Thanks for the reply. I was under the impression that the jdbc driver (or any jar you want to use as a dependency) needs to be hosted on some kind of maven repository. Am I wrong about that? Here is the official download link for the Vertica jdbc driver: https://my.vertica.com/client_drivers/7.2.x/7.2.3-0/vertica-jdbc-7.2.3-0.jar As far as I can tell, it isn't in a maven repository. Is there still a way to tell lein to look at this address to pull the jar? Thanks! On Friday, September 23, 2016 at 11:02:07 AM UTC-4, Walter van der Laan wrote: There is no need to push jdbc drivers to clojars. I have never used Vertica but perhaps it helps if I show you how to add the two jdbc-drivers that I do use. Example 1; postgres The details for the postgres-driver can be found here: http://mvnrepository.com/artifact/org.postgresql/postgresql The download-link for the jar is; http://mvnrepository.com/artifact/org.postgresql/postgresql/9.4.1211.jre7 This translates to this dependency in my project.clj: [org.postgresql/postgresql "9.4.1211"] Example 2; h2 The details for the h2-driver can be found here: http://h2database.com/html/download.html The download-link for the jar is; http://repo2.maven.org/maven2/com/h2database/h2/1.4.192/h2-1.4.192.jar This translates to this dependency in my project.clj: [com.h2database/h2 "1.3.176"] -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Adding JDBC drivers to Clojars
Thanks for the reply. I was under the impression that the jdbc driver (or any jar you want to use as a dependency) needs to be hosted on some kind of maven repository. Am I wrong about that? Here is the official download link for the Vertica jdbc driver: https://my.vertica.com/client_drivers/7.2.x/7.2.3-0/vertica-jdbc-7.2.3-0.jar As far as I can tell, it isn't in a maven repository. Is there still a way to tell lein to look at this address to pull the jar? Thanks! On Friday, September 23, 2016 at 11:02:07 AM UTC-4, Walter van der Laan wrote: > > There is no need to push jdbc drivers to clojars. > > I have never used Vertica but perhaps it helps if I show you how to add > the two jdbc-drivers that I do use. > > > Example 1; postgres > > The details for the postgres-driver can be found here: > http://mvnrepository.com/artifact/org.postgresql/postgresql > > The download-link for the jar is; > http://mvnrepository.com/artifact/org.postgresql/postgresql/9.4.1211.jre7 > > This translates to this dependency in my project.clj: > [org.postgresql/postgresql "9.4.1211"] > > > Example 2; h2 > > The details for the h2-driver can be found here: > http://h2database.com/html/download.html > > The download-link for the jar is; > http://repo2.maven.org/maven2/com/h2database/h2/1.4.192/h2-1.4.192.jar > > This translates to this dependency in my project.clj: [com.h2database/h2 > "1.3.176"] > > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Adding JDBC drivers to Clojars
There is no need to push jdbc drivers to clojars. I have never used Vertica but perhaps it helps if I show you how to add the two jdbc-drivers that I do use. Example 1; postgres The details for the postgres-driver can be found here: http://mvnrepository.com/artifact/org.postgresql/postgresql The download-link for the jar is; http://mvnrepository.com/artifact/org.postgresql/postgresql/9.4.1211.jre7 This translates to this dependency in my project.clj: [org.postgresql/postgresql "9.4.1211"] Example 2; h2 The details for the h2-driver can be found here: http://h2database.com/html/download.html The download-link for the jar is; http://repo2.maven.org/maven2/com/h2database/h2/1.4.192/h2-1.4.192.jar This translates to this dependency in my project.clj: [com.h2database/h2 "1.3.176"] -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.