I am getting error while sharing the document types in the gateway.
Please find error log for your reference.
"com.webMethods.messaging.tools.API.core.MessagingToolException: Error: Cannot set the Accept Publish documents of the gateway to “XXXXXXXXTerritory”.
at com.webMethods.messaging.tools.API.broker.resourceobjects.MessageTerritoryGatewayResourceObject.setAcceptPublish(MessageTerritoryGatewayResourceObject.java:1163)
at com.webMethods.caf.msg.msgutil.GatewayAPI.addNewDocTypes(GatewayAPI.java:1454)
at com.webMethods.caf.msg.adddocumenttypes.AddDocumentTypesDefaultviewView.addDoc_action(AddDocumentTypesDefaultviewView.java:133)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at com.sun.faces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:126)
at com.webMethods.caf.faces.application.CAFMethodBinding.invoke---- ---------
First make sure the document is publishable and subscribe on both the brokers of the territory.
If it is not working it may be because the definition of the document varies on two brokers i.e. version. So you can delete/re-import the document into both brokers and try sharing the document.