I am relatively new to managed packages, we have a 1st gen package that I am actively maintaining and I have noticed in one specific area there is a lot of global properties and methods. Which means if I want to change their signatures I basically have to create a new method V2 and change all references in the code to point to that, leaving all the existing signatures in place. I understand the danger of deprecating, so I haven't been doing that, simply commenting out the internals of those methods and returning null. But there has got to be a better way to design these.
I thought about changing the methods to all accept a Map<string, sObject> signature and then passing in the parameter name as the key and the parameter value as the object. This would, I believe, remove the issues, but am not sure that is actually the best design.
Anyone know a place where I can find best practices around design patterns specifically for dealing with managed package restrictions?
Thanks!