1. There must be a custom ContentBuilder defined. An example definition could be as follows.
@Component(metatype = false)
@Service(ContentBuilder.class)
@Property(name = "name", value = "Custom Content Builder")
public class CustomContentBuilder implements ContentBuilder { public static final String NAME = "Custom Content Builder"; public static final String TITLE = "Custom Content Builder";
public ReplicationContent create(Session session, ReplicationAction action,
ReplicationContentFactory factory) throws ReplicationException { return ReplicationContent.VOID;
}
public String getName() { return TITLE;
}
public String getTitle() { return TITLE;
}
public ReplicationContent create(Session session, ReplicationAction action,
ReplicationContentFactory factory, Map<String, Object> arg3){
// TODO Auto-generated method stub
return ReplicationContent.VOID;
}
}
2. While defining your agent in author agents that uses your custom transport handler, select your custom content builder's name i.e. in above case it is "Custom Content Builder" as a value of Synchronization Type.
In above example instead of default it should be "Custom Content Builder"
Notes: The custom handler can be invoked on the author environment by invoking activate request on the page. This works fine even when the custom handler is configured on the publish side and the request is invoked from author side in case of AEM 6.0 but, this will not work fine in CQ5.6
No comments:
Post a Comment
If you have any doubts or questions, please let us know.