Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Core] Initialize system config in CoreWorkerProcess constructor #14439

Merged
merged 3 commits into from
Mar 4, 2021

Conversation

kfstorm
Copy link
Member

@kfstorm kfstorm commented Mar 2, 2021

Why are these changes needed?

Some system config values may be accessed before connecting to Raylet in the CoreWorker constructor, so we need to initialize the system config in the CoreWorkerProcess constructor.

Related issue number

Checks

  • I've run scripts/format.sh to lint the changes in this PR.
  • I've included any doc changes needed for https://docs.ray.io/en/master/.
  • I've made sure the tests are passing. Note that there might be a few flaky tests, see the recent failures at https://flakey-tests.ray.io/
  • Testing Strategy
    • Unit tests
    • Release tests
    • This PR is not tested :(

Comment on lines 143 to 152
class ConfigInterface {
public:
/// Get the system config from Raylet.
/// \param callback Callback that will be called after raylet replied the system config.
virtual void GetSystemConfig(
const rpc::ClientCallback<rpc::GetSystemConfigReply> &callback) = 0;

virtual ~ConfigInterface(){};
};

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we just add this to the RayletClientInterface instead of adding a new one?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we can fetch the job config here as well.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unless there's a concrete reason to have the interface right now (e.g., to support unit testing) let's omit it, excessive interfaces make making changes more difficult

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I didn't know these interfaces are for unit testing. Will update it.

@kfstorm kfstorm merged commit 5d79821 into ray-project:master Mar 4, 2021
@kfstorm kfstorm deleted the system_config_init branch March 4, 2021 08:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants