on 2018 Mar 01 8:20 AM
final ProfilePictureUpdateEvent profilePictureUpdateEvent= new ProfilePictureUpdateEvent(userModel, facebookProfileForm.getPicture(), facebookProfileForm.getId()); eventService.publishEvent(profilePictureUpdateEvent);
In this above line how to make publishEvent as asynch
Help others by sharing your knowledge.
AnswerRequest clarification before answering.
Dear Devi,
According to hybris's official documentation, you can achieve that by implementing ClusterAwareEvent in your class. All Cluster aware events are processed asynchronously.
If you want to ensure that events are published and processed only by the node they come from you can override publish method like this.
@Override
public boolean publish(final int sourceNodeId, final int targetNodeId)
{
return (sourceNodeId == targetNodeId);
}
Kind regards,
Paweł Wrzask
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.