The transition from independence to a relatively minor part of a larger union was not easily accepted. To quell uprisings Charles V was struggling to exert his power over the citizens of the city, who had struggled to gain a certain level of independence from the bishops and were not willing to cede this to their new lord. The heavily fortified castle Vredenburg was built to house a large garrison whose main task was to maintain control over the city. The castle would last less than 50 years before it was demolished in an uprising in the early stages of the Dutch Revolt.