我运行包含无限循环的goroutine,如何终止该goroutine? [重复]

I have a server that runs on go and it uses goroutines, sometimes happens that goorutine gets stuck (ex. infinite loop). How do I end this goroutine?

/// code

go func(){
for{} // infinite loop ; i need to kill this
}()
/// code

I expect to find a way to kill/stop this goroutine from another goroutine or in some other way

</div>