I found some older posts dealing with this(5 yrs old or more), but I am confused on the process or if this information is out of date, hence my new question. I am on sql 2016 SP2-CU11 enterprise.
I need to enable service broker on a database that is in an availability group. Its 1.8TB in size, so I really don't want to take it totally out of the AG and reseed it all over again with a fresh backup if I can avoid it. Some older posts say you have to completely remove and add the db back in the AG, others reference just running some code to create endpoints, and routes which I have never run across before.
Is the process below the only way to enable service broker on a DB in an AG where it is not enabled?
remove the secondary copy of the DB, then the primary copy from the AG.
Run below code to activate service broker:
ALTER DATABASE XXXXXX SET ENABLE_BROKER; GO
Take a full backup, restore it to the secondary with no recovery.
join the DB to the AG on the secondary.