HDFS-8596. TestDistributedFileSystem et al tests are broken in branch-2 due to incorrect setting of "datanode" attribute. Contributed by Yongjun Zhang.
This commit is contained in:
parent
b8341f1cd8
commit
b0dc291961
@ -1002,6 +1002,9 @@ Release 2.7.1 - UNRELEASED
|
|||||||
HDFS-8572. DN always uses HTTP/localhost@REALM principals in SPNEGO.
|
HDFS-8572. DN always uses HTTP/localhost@REALM principals in SPNEGO.
|
||||||
(wheat9)
|
(wheat9)
|
||||||
|
|
||||||
|
HDFS-8596. TestDistributedFileSystem et al tests are broken in branch-2
|
||||||
|
due to incorrect setting of "datanode" attribute. (Yongjun Zhang)
|
||||||
|
|
||||||
Release 2.7.0 - 2015-04-20
|
Release 2.7.0 - 2015-04-20
|
||||||
|
|
||||||
INCOMPATIBLE CHANGES
|
INCOMPATIBLE CHANGES
|
||||||
|
@ -762,7 +762,7 @@ private void startInfoServer(Configuration conf)
|
|||||||
ServerSocketChannel httpServerChannel = secureResources != null ?
|
ServerSocketChannel httpServerChannel = secureResources != null ?
|
||||||
secureResources.getHttpServerChannel() : null;
|
secureResources.getHttpServerChannel() : null;
|
||||||
|
|
||||||
this.httpServer = new DatanodeHttpServer(conf, httpServerChannel);
|
this.httpServer = new DatanodeHttpServer(conf, this, httpServerChannel);
|
||||||
httpServer.start();
|
httpServer.start();
|
||||||
if (httpServer.getHttpAddress() != null) {
|
if (httpServer.getHttpAddress() != null) {
|
||||||
infoPort = httpServer.getHttpAddress().getPort();
|
infoPort = httpServer.getHttpAddress().getPort();
|
||||||
|
@ -75,6 +75,7 @@ public class DatanodeHttpServer implements Closeable {
|
|||||||
static final Log LOG = LogFactory.getLog(DatanodeHttpServer.class);
|
static final Log LOG = LogFactory.getLog(DatanodeHttpServer.class);
|
||||||
|
|
||||||
public DatanodeHttpServer(final Configuration conf,
|
public DatanodeHttpServer(final Configuration conf,
|
||||||
|
final DataNode datanode,
|
||||||
final ServerSocketChannel externalHttpChannel)
|
final ServerSocketChannel externalHttpChannel)
|
||||||
throws IOException {
|
throws IOException {
|
||||||
this.conf = conf;
|
this.conf = conf;
|
||||||
@ -91,7 +92,7 @@ public DatanodeHttpServer(final Configuration conf,
|
|||||||
|
|
||||||
this.infoServer = builder.build();
|
this.infoServer = builder.build();
|
||||||
|
|
||||||
this.infoServer.setAttribute("datanode", this);
|
this.infoServer.setAttribute("datanode", datanode);
|
||||||
this.infoServer.setAttribute(JspHelper.CURRENT_CONF, conf);
|
this.infoServer.setAttribute(JspHelper.CURRENT_CONF, conf);
|
||||||
this.infoServer.addServlet(null, "/blockScannerReport",
|
this.infoServer.addServlet(null, "/blockScannerReport",
|
||||||
BlockScanner.Servlet.class);
|
BlockScanner.Servlet.class);
|
||||||
|
Loading…
Reference in New Issue
Block a user