I made a couple of attempts. For the first time I just gave myself a vow to be silent more. For about a week I was tormented, in the end it became completely uncomfortable and I successfully scored on this matter. Then I came to the conclusion that at that moment there was a lack of understanding of myself in society.
The second time it was more conscious, I just tried to restrain myself a little more and make sure that the person was really interested in what I was muttering. And as an alternative, I began to keep a diary every day, trying to throw out emotions there. But it so happened that literally after a couple of days of my will-training, a rather "new" friend (they were familiar at that time for about six months) said the following: "You know, I noticed that I began to communicate like you - without expecting any introductory questions and general phrases share what you want. And so convenient, in fact. Have you been like this since childhood? " Well, then everything fell into place. I just lacked a little bit of feedback, but to get it, you also need to say it out loud :)
Therefore, my answer is not at all original and is that there is no way to stop it. Of course, you can set a goal and start talking and behaving differently, but this will no longer be a change in habit, but a breakdown of yourself and the question is how much is needed. It was important for me to understand why I am like this (it is customary in the family - we talk a lot and share our affairs and experiences with each other). And also what kind of reaction I expect from people (either they accept it, or consider it naive / stupid - their right). Well, and the fact that this is not always bad and often just what 'breaks the ice'.
And from personal observations (I first thought about it about five years ago) I can add that over time, the circle of people who really want to tell everything by itself narrows. This does not require any deliberate filtering or harsh "well, from tomorrow I will not tell them about my dog!" It just happens and slowly gets into a comfortable position for existence. :)
Successes in self-knowledge!
I have no answer to the question, but from my own experience I want to say that discussing your problems with people is not so bad. They can sympathize, give practical advice, or, even better, offer help. That's how you complain about something, and the person turns out to be able to help you. I found a dream kitten and tenants)
You know, this question has always worried me myself, and often I also cannot "keep my mouth shut" and, after another burst of information, I remember the phrase: "Happiness loves silence."
To get rid of this, you have to catch yourself thinking "does anyone need to know this at all?" - if you give yourself a negative answer, it will become a habit and stop sharing with someone information about your achievements / failures will be much easier.
Besides, you should always remember that everything can turn over in one second. So, you are going on a trip, bought a ticket and have already managed to tell the good news to a close friend, as the sun outside the window changed into clots of clouds and the weather completely ruined your plans. Absolutely everything can change not in your direction simply because you told her to someone. Yes, it works.
Remember the childish words: "Do not talk about what you have thought - it will not come true." In life, according to my observations, everything happens this way.
Yes, I do not argue, there are things that it is better to tell someone, speak out, get advice, but remember - everyone has their own problems, their own lives and also many unresolved issues. Do everything in moderation, do not be too closed off from society, but do not open your soul to the fullest, many do not appreciate it.