Skip to content
Snippets Groups Projects
Commit 121144f4 authored by Maksim Kaitmazian's avatar Maksim Kaitmazian Committed by Maksim Kaitmazian
Browse files

feat: provide a client with some parameters

parent e3d8476b
No related branches found
No related tags found
1 merge request!920pgproto module
......@@ -51,6 +51,10 @@ fn handle_client(client: PgStream<CoIOStream>) -> UnitJoinHandle<'static> {
fn do_handle_client(stream: PgStream<CoIOStream>) -> PgResult<()> {
let mut client = PgClient::accept(stream)?;
client.send_parameter("server_version", "15.0")?;
client.send_parameter("server_encoding", "UTF8")?;
client.send_parameter("client_encoding", "UTF8")?;
client.send_parameter("date_style", "ISO YMD")?;
client.send_parameter("integer_datetimes", "on")?;
client.process_messages_loop()?;
Ok(())
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment