Boiling in SDS-PAGE buffer denatures all proteins, while sonication gives you better chance (depending on used protocol) to recover native proteins. Basically, you choose one or the other depending on what you want to do with your sample further on.
You can choose one depending on your objectives. Sonication can also be responsible for speeding up the protein solubilisation process. This can effectively disrupt cellular, genomic nucleic acids. But optimization is very essential for a perfect stability since poor parameters like sonication duration, incubation time, temperature etc. could result irreversible protein damage / degrade protein sample / proteolysis.
I could suggest this article:Article Sonication of proteins causes formation of aggregates that r...
Sonication for the disruption of bacteria depends on cavitation of the bacteria which does not work for many bacteria especially gram positive organisms. This method is ok if you want to do any work with enzymes or the affects of bacterial components on eukaryotic cells or tissues. When you boil the organism you are simply solubilizing everything in the SDS solution (except the peptidoglycan) , so you can forget about any native protein work since most proteins are irreversibly denatured. The best all around method is to use a french press which breaks many more species of bacteria than sonication will.
The previous answerers have explained it so eloquently but just to buttress the point:
The difference is that sonication allows for lysis and the possibility of experimentation with the cell's total protein whereas boiling with SDS buffer gives the protein sample that can only really be used for SDS-PAGE analysis. Ultimately they both get the job done and you have a sample but it really depends on what your goal is; are you trying to purify a protein or assess overall expression?
Sonication is my choice of poison, it keeps relatively proteins intact, it's pretty reliable and straight forward. Similar mechanical methods include using a french press or glass beads, though enzymatic techniques also exist. This gives a relatively unscathed total protein sample which means if you want to isolate and assess a native protein and its function you have that option. However, if you just need to see a snapshot of the proteome boiling with SDS buffer the way to go.
I recommend Ryzsard, Bernard, Surya, and Pam wrote a nice summary. Bernard's recommendation of a French Press (or High Pressure Nitrogen ) is the method of choice to manufacture expressed proteins.
Nice work Dan! That is a very nice summary for breakage of both bacteria and Eukaryotic cell. I would just add that is very important to be sure to measure the cell breakage by either phase contrast microscopy or measuring enzymes that are released by the cells. The drawback to enzymes is determining what is 100% release.