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

Add @Override toString() in InstanceInfo #1163

Merged
merged 1 commit into from
Dec 18, 2018

Conversation

phantasmicmeans
Copy link
Contributor

Application(class) can get simple information by @OverRide the toString().

-> toString() in Application.java

@Override
public String toString() {
    return "Application [name=" + name + ", isDirty=" + isDirty
            + ", instances=" + instances + ", shuffledInstances="
            + shuffledInstances + ", instancesMap=" + instancesMap + "]";
}

It is simple to use some information immediately.

But What is more necessary is the information in InstanceInfo(class)?
InstanceInfo provides a detailed information about the eureka client.
InstanceInfo provides a getter, but it has about 30 member variables.

So it seems necessary to provide the overriden toString() of InstanceInfo

Application(Class) can get simple information by @OverRide the toString().

-> toString() in Application.java

    @OverRide
    public String toString() {
        return "Application [name=" + name + ", isDirty=" + isDirty
                + ", instances=" + instances + ", shuffledInstances="
                + shuffledInstances + ", instancesMap=" + instancesMap + "]";
    }

It is simple to use some information immediately.

But What is more necessary is the information in InstanceInfo(Class)?
InstanceInfo provides a getter, but it has about 30 member variables.

So it seems necessary to provide the overriden toString() of InstanceInfo
@elandau elandau merged commit cb21514 into Netflix:master Dec 18, 2018
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.

None yet

2 participants