[
https://issues.apache.org/jira/browse/HDFS-16842?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18062194#comment-18062194
]
ASF GitHub Bot commented on HDFS-16842:
---------------------------------------
hadoop-yetus commented on PR #8291:
URL: https://github.com/apache/hadoop/pull/8291#issuecomment-3985203993
:broken_heart: **-1 overall**
| Vote | Subsystem | Runtime | Logfile | Comment |
|:----:|----------:|--------:|:--------:|:-------:|
| +0 :ok: | reexec | 0m 0s | | Docker mode activated. |
| -1 :x: | docker | 0m 13s | | Docker failed to build run-specific
yetus/hadoop:tp-10157}. |
| Subsystem | Report/Notes |
|----------:|:-------------|
| GITHUB PR | https://github.com/apache/hadoop/pull/8291 |
| Console output |
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-8291/4/console |
| versions | git=2.34.1 |
| Powered by | Apache Yetus 0.14.1 https://yetus.apache.org |
This message was automatically generated.
> DatanodeHttpServer cannot get the new configuration of the new nameservice
> even after refreshNamenodes is run
> -------------------------------------------------------------------------------------------------------------
>
> Key: HDFS-16842
> URL: https://issues.apache.org/jira/browse/HDFS-16842
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: datanode
> Affects Versions: 3.1.2
> Reporter: Jihye Seo
> Priority: Major
> Labels: patch-available, pull-request-available
> Fix For: 3.1.2
>
> Attachments: HDFS-16842.001.patch
>
>
> 'refreshNamenodes' should be run when a new nameservice is added.
> However, a 'DatanodeHttpServer' cannot get the new configuration of the new
> nameservice even after 'refreshNamenodes' is run.
> Therefore, when a client tries to access the new namespace's data with a
> swebhdfs or REST API request, an error occurs as follows.
> {code:java}
> Does not contain a valid host:port authority: NEW_NAMESPACE{code}
> When 'refreshNamenodes' is executed, a Datanode object reads the new
> configuration file and updates its configuration with 'setConf(new
> Configuration)'.
> {code:java}
> public void refreshNamenodes() throws IOException {
> checkSuperuserPrivilege();
> setConf(new Configuration());
> refreshNamenodes(getConf());
> }{code}
> On the other hand, the configuration of a DatanodeHttpServer object remains
> unchanged after the DatanodeHttpServer object is created.
> When a Datanode object is created, a DatanodeHttpServer is created by copying
> the Datanode's configuration. Since then, there's no way to update its
> configuration.
> {code:java}
> public DatanodeHttpServer(final Configuration conf,
> final DataNode datanode,
> final ServerSocketChannel externalHttpChannel)
> throws IOException {
> this.restCsrfPreventionFilter = createRestCsrfPreventionFilter(conf);
> this.conf = conf;
> ...
> } {code}
> This causes a DatanodeHttpServer to be unable to interpret a request for the
> new name service.
> Therefore, a DatanodeHttpServer also needs to update its configuration to
> handle a request for a new name service.
> I attached a patch based on the trunk.
>
> Thanks!
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]