We have completely changed the way a managed package operates and no longer want a legacy global webservice method. I don't want it to be included in future packages/installs. However, I can't seem to figure out how to do this. Is this even possible?
I know I can't simply delete the class because it is a
global class, so I attempted to use the
@deprecated annotation, as indicated by the documentation:
Use the deprecated annotation to identify methods, classes, exceptions, enums, interfaces, or variables that can no longer be referenced in subsequent releases of the managed package in which they reside. This is useful when you are refactoring code in managed packages as the requirements evolve. New subscribers cannot see the deprecated elements, while the elements continue to function for existing subscribers and API integrations.
Alas this fails to work, and I receive the following error messages:
Defining type for webService methods cannot be Deprecated
(when I put the annotation on the enclosing class)
webService methods cannot be Deprecated
(when I put the annotation directly on the method)
A quick look to the
WebService documentation turned up this info:
You cannot deprecate webService methods or variables in managed package code.
But that is all I was able to find. No indication on how I could remove/deprecate a webservice method.
Does anyone know of a way to remove a webservice method from a managed package !?