Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How AppClient registers Masters

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)05/31 Report--

The content of this article mainly revolves around how AppClient registers Masters. The content of the article is clear and easy to understand, and the organization is clear. It is very suitable for beginners to learn and worth reading. Interested friends can read along with Xiaobian. I hope everyone gets something out of this article!

There are two kinds of registered masters, one is registerWithMaster method, the other is tryRegisterAllMasters method, the former is the case of a single Master, the latter is a multi-master, in general, it is to meet the HA mechanism, let's take a look at registerWithMaster method:

The tryRegisterAllMasters method is called:

We enter the Master's source code:

Take a look at the code for accepting the message RegisterApplication sent by the client as follows:

2、registerApplication:

3.1 changeMaster(masterUrl) in the above code:

3.2.1 Enter the connected method of the implementation class SparkDeployScheduler Backend:

4. Then the schedule method will be called in the Master's message response:

1.1 Enter worker.actor. LaunchDriver(driver.id, driver.desc) Method:

Thank you for reading, I believe you have a certain understanding of "AppClient how to register Masters" this issue, go to practice it quickly, if you want to know more related knowledge points, you can pay attention to the website! The editor will continue to bring better articles to everyone!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report