forked from pgjdbc/r2dbc-postgresql
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Stream for subscribing to Postgres connection notices
[resolves pgjdbc#570] Postgres may send notice messages through a connection, which may contain log information or metadata related to the submitted commands. Notices travel on the same backend messaging subsystem used by notifications. The implementation processes NoticeResponse in a way similar to NotificationResponse, and exposes a coherent API.
- Loading branch information
Francesco Komauli
committed
Jan 13, 2023
1 parent
87a058e
commit e327091
Showing
9 changed files
with
294 additions
and
10 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
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,23 @@ | ||
package io.r2dbc.postgresql.api; | ||
|
||
import io.r2dbc.postgresql.message.backend.Field; | ||
|
||
import java.util.Map; | ||
|
||
/** | ||
* Postgres notice. | ||
*/ | ||
public class Notice { | ||
|
||
/** | ||
* Notice messages by {@link Field.FieldType}. | ||
*/ | ||
public final Map<Field.FieldType, String> fields; | ||
|
||
/** | ||
* @param fields notice messages by {@link Field.FieldType} | ||
*/ | ||
public Notice(Map<Field.FieldType, String> fields) { | ||
this.fields = fields; | ||
} | ||
} |
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
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
Oops, something went wrong.