org.apache.nutch.ndfs
Class NDFS.DataNode

java.lang.Object
  extended byorg.apache.nutch.ipc.Client
      extended byorg.apache.nutch.ndfs.NDFS.DataNode
Enclosing class:
NDFS

public static class NDFS.DataNode
extends Client

DataNode controls just one critical table: block-> BLOCK_SIZE stream of bytes This info is stored on disk (the NameNode is responsible for asking other machines to replicate the data). The DataNode reports the table's contents to the NameNode upon startup and every so often afterwards.

Author:
Mike Cafarella

Field Summary
 
Fields inherited from class org.apache.nutch.ipc.Client
LOG
 
Constructor Summary
NDFS.DataNode(String dataDir)
          Create using configured defaults and dataDir.
NDFS.DataNode(String machineName, File dir, InetSocketAddress nameNodeAddr)
          Needs a directory to find its data (and config info)
 
Method Summary
static void main(String[] argv)
           
 void offerService()
          Main loop for the DataNode.
 
Methods inherited from class org.apache.nutch.ipc.Client
call, call, setTimeout, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NDFS.DataNode

public NDFS.DataNode(String dataDir)
              throws IOException
Create using configured defaults and dataDir.


NDFS.DataNode

public NDFS.DataNode(String machineName,
                     File dir,
                     InetSocketAddress nameNodeAddr)
              throws IOException
Needs a directory to find its data (and config info)

Method Detail

offerService

public void offerService()
                  throws Exception
Main loop for the DataNode. Runs until shutdown.

Throws:
Exception

main

public static void main(String[] argv)
                 throws IOException
Throws:
IOException


Copyright © 2006 The Apache Software Foundation