File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Hadoop and the fly likes LZO compression Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » Hadoop
Bookmark "LZO compression" Watch "LZO compression" New topic
Author

LZO compression

Karthik Anant
Greenhorn

Joined: Nov 02, 2009
Posts: 20
Hi all,
Am trying to implement LZO compression algorithm in my program. Please advice where I can download the API jars and may be some sample programs. I've tried googling for almost 10 hours now .

Thanks in advance,
Karthik
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41613
    
  55
Are you sure that a Java API exists? The LZO documentation states that it doesn't have Java bindings yet, and given that it's a fairly obscure algorithm, nobody else may have bothered creating them. You may have to roll your own using JNI.


Ping & DNS - my free Android networking tools app
Karthik Anant
Greenhorn

Joined: Nov 02, 2009
Posts: 20
Thanks Dittmer,

Ulf Dittmer wrote:The LZO documentation states that it doesn't have Java bindings yet


Could you please provide the link of that LZO documentation.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41613
    
  55
Um, did you really search for 10 hours without finding the home page of the algorithm and implementation? It's the first link I get in Google.
Karthik Anant
Greenhorn

Joined: Nov 02, 2009
Posts: 20
I suppose you were referring to oberhumer.com. But I also found a few java sample programs at below url though without any API linked for download and the code also isnt very clear. Thanks a lot for your efforts.

http://www.docjar.com/docs/api/org/apache/hadoop/io/compress/lzo/package-index.html
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41613
    
  55
Good find. Since it seems to be part of Apache Hadoop, why don't you download that, and try to extract the relevant source code?
Karthik Anant
Greenhorn

Joined: Nov 02, 2009
Posts: 20
Ulf Dittmer wrote:Good find. Since it seems to be part of Apache Hadoop, why don't you download that, and try to extract the relevant source code?


most of my 10 hours were spent trying to download the apache hadoop only. Still unable to find org.apache.hadoop.util.NativeCodeLoader.

So I was wondering if anybody has managed to download the complete hadoop package, I would really love to know from where they did it.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41613
    
  55
What did you download? That class is part of the Hadoop core jar file, which is kind of the first thing one encounters on the Hadoop site when looking for downloads, right here: http://apache.mirror.clusters.cc/hadoop/core/hadoop-0.20.1/
Karthik Anant
Greenhorn

Joined: Nov 02, 2009
Posts: 20
thanks Ulf,
But I tried that package download but to no avail. mainly am stuck for one class file org.apache.hadoop.util.NativeCodeLoader.

Thanks in advance,
Karthik
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41613
    
  55
I'm afraid that I can't help, then - the class is in that download. How did you look for it after you extracted the file's contents?
Karthik Anant
Greenhorn

Joined: Nov 02, 2009
Posts: 20
Ulf Dittmer wrote:How did you look for it after you extracted the file's contents?


added all the jars in the eclipse buildpath and used the eclipse to search for me.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41613
    
  55
Not sure what Eclipse does, but using the jar tool (and its "-tf" option) I was able to find that class real quick.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: LZO compression