Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit1b92aeb

Browse files
committed
Improve comment about why sleep is used by pg_standby to handle 'copy'
file size problem.
1 parent30c6202 commit1b92aeb

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

‎contrib/pg_standby/pg_standby.c

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* $PostgreSQL: pgsql/contrib/pg_standby/pg_standby.c,v 1.15 2008/12/1521:39:25 momjian Exp $
2+
* $PostgreSQL: pgsql/contrib/pg_standby/pg_standby.c,v 1.16 2008/12/1522:13:02 momjian Exp $
33
*
44
*
55
* pg_standby.c
@@ -179,12 +179,11 @@ CustomizableNextWALFileReady()
179179
#ifdefWIN32
180180

181181
/*
182-
* Windows reports that the file has the right number of bytes
183-
* even though the file is still being copied and cannot be opened
184-
* by pg_standby yet. So we wait for sleeptime secs before
185-
* attempting to restore. If that is not enough, we will rely on
186-
* the retry/holdoff mechanism. GNUWin32's cp does not have
187-
* this problem.
182+
* Windows 'cp' sets the final file size before the copy is
183+
* complete, and not yet ready to be opened by pg_standby.
184+
* So we wait for sleeptime secs before attempting to restore.
185+
* If that is not enough, we will rely on the retry/holdoff
186+
* mechanism. GNUWin32's cp does not have this problem.
188187
*/
189188
pg_usleep(sleeptime*1000000L);
190189
#endif

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp