Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Changing any kind of global state is fundamentally not thread safe.

Sure you could use locks, stop the world, etc, but there is no way you can ensure that all the data and information you had derived from the old state is going to be valid.

A better solution is to not rely on global state like this.



Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: