-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(sandside): #193 notify admins users when user created
close #193
- Loading branch information
Showing
5 changed files
with
49 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
sandside/src/main/java/fr/ght1pc9kc/baywatch/security/domain/ports/NotificationPort.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package fr.ght1pc9kc.baywatch.security.domain.ports; | ||
|
||
import fr.ght1pc9kc.baywatch.notify.api.model.BasicEvent; | ||
import fr.ght1pc9kc.baywatch.notify.api.model.EventType; | ||
|
||
public interface NotificationPort { | ||
<T> BasicEvent<T> send(String userId, EventType type, T data); | ||
} |
14 changes: 14 additions & 0 deletions
14
...c/main/java/fr/ght1pc9kc/baywatch/security/infra/adapters/NotificationServiceAdapter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package fr.ght1pc9kc.baywatch.security.infra.adapters; | ||
|
||
import fr.ght1pc9kc.baywatch.notify.api.NotifyService; | ||
import fr.ght1pc9kc.baywatch.security.domain.ports.NotificationPort; | ||
import lombok.RequiredArgsConstructor; | ||
import lombok.experimental.Delegate; | ||
import org.springframework.stereotype.Component; | ||
|
||
@Component | ||
@RequiredArgsConstructor | ||
public class NotificationServiceAdapter implements NotificationPort { | ||
@Delegate | ||
private final NotifyService delegate; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters