You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
hi @justinmclean , GRAVITINO_MANAGED_ENTITY is a static field of the parent class, and It is legal to access the static member of the parent class through the subclass name. So I think it's not a problem.
While this is a minor issue and while It is legal it is not best practice. Static members are associated with the class itself, not with any of its child classes. Accessing it via the wrong method possible suggests a misunderstanding of how OO works. It is best practice to use the base class for clarity.
While this is a minor issue and while It is legal it is not best practice. Static members are associated with the class itself, not with any of its child classes. Accessing it via the wrong method possible suggests a misunderstanding of how OO works. It is best practice to use the base class for clarity.
…or HadoopCatalogOperations (#2336)
### What changes were proposed in this pull request?
- fix incorrect static field reference for HadoopCatalogOperations
### Why are the changes needed?
Fix: #2188
### Does this PR introduce _any_ user-facing change?
N/A
### How was this patch tested?
No
What would you like to be improved?
In HadoopCatalogOperations.java GRAVITINO_MANAGED_ENTITY in not a static field, it belongs to it's parent.
How should we improve?
Reference GRAVITINO_MANAGED_ENTITY correctly using the parent class.
The text was updated successfully, but these errors were encountered: