Task #692
closedAbstractNotificationSender send by topic, level and type possible bug
100%
Description
Please check method send(String topic, IdmMessageDto message, List<IdmIdentityDto> recipients) in AbstractNotificationSender.
Template is not solved correctly. When create and send message with only filled topic (topic=some:example), was not found template by configuration.
configuration settings:
topic=some:example
level=null
type=email
If you have some problem with task consult with VS :-)
Updated by Ondřej Kopr over 7 years ago
- % Done changed from 0 to 50
How to simulate problem:
send notification to topic with two similar configurations, message should be sent twice..
IdmIdentityDto dto = identityService.getByUsername("testUser"); notificationManager.send("test", new IdmMessageDto.Builder().build(), dto);
Message will not be send because method resolveTemplate in class DefaultIdmNotificationTemplateService was not resolve wild card correctly.
I started with refactor this method and all AbstractNotificationSender api.
Updated by Ondřej Kopr about 7 years ago
- Status changed from In Progress to Needs feedback
- Assignee changed from Ondřej Kopr to Radek Tomiška
- % Done changed from 50 to 90
All send method in AbstractNotificationSender now return List of N that extends from IdmNotificationDto. All test updated.
Tests for send message to wildcard and more than one topic added.
change log: https://github.com/bcvsolutions/CzechIdMng/blob/develop/CHANGELOG.md#notifications
commit: https://github.com/bcvsolutions/CzechIdMng/commit/411bab7d9bb282b413b390cb46eb10bf54cc1a39
tests: https://github.com/bcvsolutions/CzechIdMng/commit/319c1cd370384f8001aa80fc2c518690ee66909e
Sending notification via method List<N> send(String topic, IdmMessageDto message, List<IdmIdentityDto> recipients) works correctly, but send via FE agenda send message directly to end senders, method: N send(IdmNotificationDto notification), is necessary change behavior sending message via FE?
Please Radek could you make a review?
Updated by Radek Tomiška about 7 years ago
- Status changed from Needs feedback to Closed
- Assignee changed from Radek Tomiška to Ondřej Kopr
- % Done changed from 90 to 100
I did review, test and fixed some issues with sending duplicate notifications (configuration with different template).