java.lang.Runnable, SecondaryNameNodeInfoMXBean, VersionInfoMXBean@Private public class SecondaryNameNode extends java.lang.Object implements java.lang.Runnable, SecondaryNameNodeInfoMXBean
| Modifier and Type | Field | Description |
|---|---|---|
static org.slf4j.Logger |
LOG |
| Constructor | Description |
|---|---|
SecondaryNameNode(org.apache.hadoop.conf.Configuration conf) |
Create a connection to the primary namenode.
|
SecondaryNameNode(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode.CommandLineOpts commandLineOpts) |
| Modifier and Type | Method | Description |
|---|---|---|
boolean |
doCheckpoint() |
Create a new checkpoint
|
void |
doWork() |
|
java.lang.String[] |
getCheckpointDirectories() |
|
java.lang.String[] |
getCheckpointEditlogDirectories() |
|
java.lang.String |
getCompileInfo() |
|
FSNamesystem |
getFSNamesystem() |
|
java.lang.String |
getHostAndPort() |
Gets the host and port colon separated.
|
static java.net.InetSocketAddress |
getHttpAddress(org.apache.hadoop.conf.Configuration conf) |
|
long |
getLastCheckpointDeltaMs() |
|
long |
getLastCheckpointTime() |
|
java.lang.String |
getSoftwareVersion() |
|
long |
getStartTime() |
|
boolean |
isSecurityEnabled() |
Gets if security is enabled.
|
static void |
main(java.lang.String[] argv) |
main() has some simple utility methods.
|
void |
run() |
|
void |
shutdown() |
Shut down this instance of the secondary namenode.
|
void |
startCheckpointThread() |
|
void |
startInfoServer() |
Start the web server.
|
java.lang.String |
toString() |
public SecondaryNameNode(org.apache.hadoop.conf.Configuration conf)
throws java.io.IOException
java.io.IOExceptionpublic SecondaryNameNode(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode.CommandLineOpts commandLineOpts)
throws java.io.IOException
java.io.IOExceptionpublic java.lang.String toString()
toString in class java.lang.Object@VisibleForTesting public FSNamesystem getFSNamesystem()
public static java.net.InetSocketAddress getHttpAddress(org.apache.hadoop.conf.Configuration conf)
public void shutdown()
public void run()
run in interface java.lang.Runnablepublic void doWork()
@VisibleForTesting
public void startInfoServer()
throws java.io.IOException
java.io.IOException@VisibleForTesting
public boolean doCheckpoint()
throws java.io.IOException
java.io.IOExceptionpublic static void main(java.lang.String[] argv)
throws java.lang.Exception
argv - Command line parameters.java.lang.Exception - if the filesystem does not exist.public void startCheckpointThread()
public java.lang.String getHostAndPort()
SecondaryNameNodeInfoMXBeangetHostAndPort in interface SecondaryNameNodeInfoMXBeanpublic boolean isSecurityEnabled()
SecondaryNameNodeInfoMXBeanisSecurityEnabled in interface SecondaryNameNodeInfoMXBeanpublic long getStartTime()
getStartTime in interface SecondaryNameNodeInfoMXBeanpublic long getLastCheckpointTime()
getLastCheckpointTime in interface SecondaryNameNodeInfoMXBeanpublic long getLastCheckpointDeltaMs()
getLastCheckpointDeltaMs in interface SecondaryNameNodeInfoMXBeanpublic java.lang.String[] getCheckpointDirectories()
getCheckpointDirectories in interface SecondaryNameNodeInfoMXBeanpublic java.lang.String[] getCheckpointEditlogDirectories()
getCheckpointEditlogDirectories in interface SecondaryNameNodeInfoMXBeanpublic java.lang.String getCompileInfo()
getCompileInfo in interface VersionInfoMXBeanpublic java.lang.String getSoftwareVersion()
getSoftwareVersion in interface VersionInfoMXBeanCopyright © 2008–2025 Apache Software Foundation. All rights reserved.