Hi guys!
I'm on this journey trying to learn AEM and I got stuck into this error.
I really can't seem to understand what is related to ?!
Let me explain how I get it.
After I register on a website, I get this email with the activation link. Once I follow the link I should get my account activated but when I acces the link i get this error message.
Cannot serve request to /bin/validateEmail in com.blabla.blabla.core.servlets.impl.EmailValidationServlet
I know if I access this link I can get to configure the agents. but I don't understand how things work and what should I configure.
http://localhost:4502/etc/replication/agents.author/publish.html
Any help would be highly appreciated
PS: I am using AEM 6.2
Thanks
Solved! Go to Solution.
Maybe no replication agent is configured with the "on distribute" trigger?
Can you please share the code of "com.blabla.blabla.core.servlets.impl.EmailValidationServlet"?
regards,
Jörg
Views
Replies
Total Likes
Yeah :
private static final String TOKEN = "token";
private static final String REDIRECT_AWAITING_APPROVAL = "/content/demo/login.html?content=waiting_approval";
private static final String REDIRECT_AUTOAPPROVED = "/content/demo/login.html?content=approved;
protected void doGet(SlingHttpServletRequest request, SlingHttpServletResponse response) throws IOException {
Views
Replies
Total Likes
Session session = null;
User user = TokenUtils.getUserByRegistrationToken(session, ServletUtils.getRequiredParameter(TOKEN, request));
replicateWorkflowNode(session, user);
private void replicateWorkflowNode(Session session, User user) throws Exception {
ReplicationOptions replicationOptions = new ReplicationOptions();
replicationOptions.setFilter(new AgentFilter() {
@Override
public boolean isIncluded(Agent agent) {
return agent.getConfiguration().isTriggeredOnDistribute();
}
});
replicationOptions.setSynchronous(true);
replicator.replicate(session, ReplicationActionType.ACTIVATE, WorkflowUtils.createWorkflowNode(session, user).getPath(), replicationOptions);
Views
Replies
Total Likes
Looks like the AgentFilter returns "false" for all agents.
Views
Replies
Total Likes
Hmm, and what does that mean?
My agents are badly configured or inexistent ?
Views
Replies
Total Likes
Maybe no replication agent is configured with the "on distribute" trigger?
As suggested by Jorg , on trigger section select "on distribute" .
Also create logger for both in DEBUG mode
com.day.cq.replication # to analyse issue on Replication
org.apache.sling.event # to analyse issue from Sling end
Please share if still issue not identified .
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies