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

Write and add linter to M3DB for detecting locks that are locked and then never unlocked #581

Closed
richardartoul opened this issue May 4, 2018 · 1 comment
Assignees
Labels
area:db All issues pertaining to dbnode P: Medium T: Misc

Comments

@richardartoul
Copy link
Contributor

richardartoul commented May 4, 2018

I.E the linter should be able to detect simple errors like this

func (s *someStruct) someMethod() error {
    s.Lock()
    err := s.doSomeWork()
    if err != nil {
        return err
    }
    s.Unlock()
    return nil
}

This will allow us to avoid defer's in hot-paths, but still be confident our code isn't buggy.

@prateek
Copy link
Collaborator

prateek commented May 4, 2018

Did a little research on this a while back, more details here: m3db/build-tools#14

@prateek prateek added the area:db All issues pertaining to dbnode label May 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:db All issues pertaining to dbnode P: Medium T: Misc
Projects
None yet
Development

No branches or pull requests

4 participants