I'm using the word necessary the way it's normally understood.
I believe that if we stay IN CHRIST, we will be saved.
IF we remove ourselves from HIm,,,then our soul will surely be in danger.
The following does not sound like discipline...it sounds like our very salvation is at stake, as per Paul:
Colossians 1:21-23
21And although you were formerly alienated and hostile in mind, engaged in evil deeds,
22yet He has now reconciled you in His fleshly body through death, in order to present you before Him holy and blameless and beyond reproach—
23if indeed you continue in the faith firmly established and steadfast, and not moved away from the hope of the gospel that you have heard, which was proclaimed in all creation under heaven, and of which I, Paul, was made a minister.