[
https://issues.apache.org/jira/browse/TAJO-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14237586#comment-14237586
]
ASF GitHub Bot commented on TAJO-1221:
--------------------------------------
Github user hyunsik commented on a diff in the pull request:
https://github.com/apache/tajo/pull/286#discussion_r21439057
--- Diff:
tajo-core/src/main/java/org/apache/tajo/master/ha/HAServiceHDFSImpl.java ---
@@ -169,6 +173,48 @@ private void createMasterFile(boolean isActive) throws
IOException {
}
+ private String getHostName(String hostAddress, int type) {
+ String hostName = null;
+ int port = 0;
+
+ switch (type) {
+ case 1:
--- End diff --
I think that the direct use of number makes code readability bad. I'd like
to suggest using some constants or Enum type.
> HA TajoClient should not connect TajoMaster at the first.
> ---------------------------------------------------------
>
> Key: TAJO-1221
> URL: https://issues.apache.org/jira/browse/TAJO-1221
> Project: Tajo
> Issue Type: Improvement
> Components: tajo master
> Reporter: Hyunsik Choi
> Assignee: Jaehwa Jung
> Labels: failure-handling, fault-tolerance, high-availability
> Fix For: 0.9.1
>
>
> *Problem*
> We TajoClient is opened, TajoClient initially tries to connect TajoMaster.
> This manner does not guarantee high availability. A known TajoMaster host may
> be not work anymore. So, this manner still has some failure point.
> Also, this manner prohibits a Tajo cluster to run on some dynamic cluster
> environments like Yarn.
> *Solution*
> Tajo HA client should get directly TajoMaster addresses and others from HA
> component without contacting TajoMaster.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)