Epidemic And Contagion Processes In Self-Organizing Systems