Missing JAR for micrometer-commons:1.10.0.M1-redhat-00001 - java

io.micrometer:micrometer-core:micrometer-core-1.10.0.M1-redhat-00001.pom defines a dependency on io.micrometer:micrometer-commons:micrometer-commons-1.10.0.M1-redhat-00001
<dependency>
<groupId>io.micrometer</groupId>
<artifactId>micrometer-commons</artifactId>
<version>1.10.0.M1-redhat-00001</version>
<scope>compile</scope>
</dependency>
And io.micrometer:micrometer-commons:micrometer-commons-1.10.0.M1-redhat-00001.pom does not specify <packaging> to be pom. Therefore it is using default packaging type of jar.
However, there is no micrometer-commons-1.10.0.M1-redhat-00001.jar available here.
Is there anything wrong in Micromere 1.10.0.M1-redhat-00001?

The repo that you are using is not the official repo of Micrometer.
Check the docs and the readme, Micrometer artifacts can be found here:
Stable: https://search.maven.org/search?q=g:io.micrometer
Milestone: https://repo.spring.io/ui/native/milestone/io/micrometer
Snapshot: https://repo.spring.io/ui/native/snapshot/io/micrometer
If you want to use the non-official redhat repo, please contact redhat support.

Related

ngdbc.jar equivalent Maven repository

I am using ngdbc.jar to connect Java and HANA. Now I want to build a Web application. So I searched for the equivalent Maven repository but I could not find that one.
I found mostly for the cloud ones and finally found this one:
<dependency>
<groupId>com.sap.cloud</groupId>
<artifactId>neo-java-web-api</artifactId>
<version>1.53.18.2</version>
<scope>provided</scope>
</dependency>
Can any one tell which repository I can use instead of ngdbc.jar? Any help is appreciated
SAP doesn't allowed redistribution of ngdbc.jar in their TC as mentioned here. So you won't find any legal one online.
Your only option is to include the jar from your local. Something like:
<dependency>
<groupId>sample</groupId>
<artifactId>com.sample</artifactId>
<version>1.0</version>
<scope>system</scope>
<systemPath>${project.basedir}/src/main/resources/yourJar.jar</systemPath>
</dependency>
described here here how to deal with the missing ngdbc.jar:
https://github.com/claboran/priceimporter
I tried to install the jar file as a dependency by
install:install-file -Dfile=C:\ngdbc.jar -DgroupId=com.han.driver -DartifactId=hana -Dversion=1.0 -Dpackaging=jar
in Maven which is pretty handy and good way.hope this helps someone dealing with custom jars.

Maven dependency to use com.google.common.graph.ImmutableDirectedGraph

I'd like to use the Guava collection com.google.common.graph.ImmutableDirectedGraph, documented here, with Maven. I can't find the Maven dependency name and version including this particular class/API on the usual repositories.
What would be the correct Maven dependency/ies ?
It doesn't look like this API has been published to Maven central yet, but I see it in the latest snapshot, 20.0-SNAPSHOT on Github:
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>20.0-SNAPSHOT</version>
</dependency>

Maven dependency for Google Spreadsheet

Added the following dependency in pom.xml.
<dependency>
<groupId>com.google.api.client</groupId>
<artifactId>google-api-data-spreadsheet-v3</artifactId>
<version>1.0.10-alpha</version>
</dependency>
But it doesn't seem to work. It doesn't contain any of the required classes. For example, SpreadsheetService, SpreadsheetFeed, SpreadsheetEntryetc.
Is there any other maven repository for Google Spreadsheet?
Also, in this documentation, they haven't mentioned any maven repository. So, do I have to manually download the required JARs and add them to my project?
After some searching and experimentation, I finally found the dependency which contains the required classes to work with Google Spreadsheets. Here it is -
<dependency>
<groupId>com.google.gdata</groupId>
<artifactId>core</artifactId>
<version>1.47.1</version>
</dependency>
To test this, I used the code given here.
As far as getting authorization is concerned, look at this answer.

difference between com.sun.jna and net.java.dev.jna?

I'm looking through the central maven repository and seeing a net.java.dev.jna and a com.sun.jna groupId for JNA. The github for JNA, using the com.sun.jna path as the directories in their source code, indicates that 4.1 has been pushed into the repository as part of a comment, but I'm seeing net.java.dev.jna at 4.1 and com.sun.jna at 3.0.
Obviously, I want to use JNA, but am baffled. What's going on with this package?
The correct 4.1 version to use is net.java.dev.jna:
<dependency>
<groupId>net.java.dev.jna</groupId>
<artifactId>jna</artifactId>
<version>4.1.0</version>
</dependency>
The package name still seems to be com.sun.jna, but if you look in the POM file, the Maven coordinates have become net.java.dev.jna:jna.
They seem to have been that way for quite a long time, based on the MVN respository results.

where can I find maven repository for kafka?

I want to try kafka 0.8 (as I understand it is already released). But where can I find the kafka maven repository.
And what additional repository url should I add?
I've found some blogs with
<dependency>
<groupId>org.apache.kafka</groupId>
<artifactId>kafka_2.8.0</artifactId>
<version>0.8.0-SHA</version>
</dependency>
but it is not works. I'm looking for proper maven dependency. Or should I checkout it from git and deploy in our internal artifactory?
UPDATE
Since November 2013 official Kafka releases can be found on public Maven repository, the latest version in March 2015 being 0.8.2.1:
<dependency>
<groupId>org.apache.kafka</groupId>
<artifactId>kafka_2.10</artifactId>
<version>0.8.2.1</version>
</dependency>
If you created the not.released:kafka artifact detailed below any more you can remove it from the local repository.
Original Answer
Kafka is not released yet to a public Maven repository, but you can add it to your local Maven repository by hand with the install-file command:
mvn install:install-file -Dpackaging=jar -DgroupId=not.released
-DartifactId=kafka -Dversion=0.8.0 -Dfile=kafka.jar
The command line above expects kafka.jar file in the current working directory.
Once installed you can use it with:
<dependency>
<groupId>not.released</groupId>
<artifactId>kafka</artifactId>
<version>0.8.0</version>
</dependency>
Once they release Kafka you can just change the dependency in your POMs and remove / uninstall this file from your local repository.
As of December 2013, Kafka 0.8 Final was released and is available under the following definition:
<dependency>
<groupId>org.apache.kafka</groupId>
<artifactId>kafka_2.10</artifactId>
<version>0.8.0</version>
</dependency>
<dependency>
<groupId>org.apache.kafka</groupId>
<artifactId>kafka_2.9.2</artifactId>
<version>0.8.0-beta1</version>
</dependency>
Even though this is already answered, I think future readers might benefit from a complete simple example that works out of the box. I put one together here >
https://github.com/buildlackey/cep
Like the o.p., I have been fighting to find a Maven pom.xml recipe that will allow me to pull in an official version of Kafka from a public Maven repository. I did manage to get my example working, but for now I have had to hack
my dependencies so that the version of Kafka I use is pulled from a work-in-progress version of a
storm-kafka integration project. I'm concerned the 'wip' versions below will be deprecated.
Then this project will lose its dependencies and fail to build properly. Also, I
really shouldn't be introducing storm for this simple Kafka example at this point in any case.
storm
storm
0.9.0-wip17
storm
storm-core
0.9.0-wip17
storm
storm-kafka
0.9.0-wip16a-scala292
If someone could provide me with a patch for 'the right way' to do this with Maven I will update my project accordingly.... Hopefully it will serve as a useful resource for other beginning Kafka developers.
Just go to http://mvnrepository.com/artifact/org.apache.kafka and choose from the list kafka repository matching to your version.
You can find all the realease version here:
http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22org.apache.kafka%22
Here is another clue:
<dependency>
<groupId>com.sksamuel.kafka</groupId>
<artifactId>kafka_2.10</artifactId>
<version>0.8.0-beta1</version>
</dependency>

Categories