@@ -1039,6 +1039,11 @@ pgfdw_reject_incomplete_xact_state_change(ConnCacheEntry *entry)
1039
1039
* Cancel the currently-in-progress query (whose query text we do not have)
1040
1040
* and ignore the result. Returns true if we successfully cancel the query
1041
1041
* and discard any pending result, and false if not.
1042
+ *
1043
+ * It's not a huge problem if we throw an ERROR here, but if we get into error
1044
+ * recursion trouble, we'll end up slamming the connection shut, which will
1045
+ * necessitate failing the entire toplevel transaction even if subtransactions
1046
+ * were used. Try to use WARNING where we can.
1042
1047
*/
1043
1048
static bool
1044
1049
pgfdw_cancel_query (PGconn * conn )
@@ -1086,6 +1091,11 @@ pgfdw_cancel_query(PGconn *conn)
1086
1091
* If the query is executed successfully but returns an error, the return
1087
1092
* value is true if and only if ignore_errors is set. If the query can't be
1088
1093
* sent or times out, the return value is false.
1094
+ *
1095
+ * It's not a huge problem if we throw an ERROR here, but if we get into error
1096
+ * recursion trouble, we'll end up slamming the connection shut, which will
1097
+ * necessitate failing the entire toplevel transaction even if subtransactions
1098
+ * were used. Try to use WARNING where we can.
1089
1099
*/
1090
1100
static bool
1091
1101
pgfdw_exec_cleanup_query (PGconn * conn , const char * query , bool ignore_errors )
@@ -1132,11 +1142,6 @@ pgfdw_exec_cleanup_query(PGconn *conn, const char *query, bool ignore_errors)
1132
1142
* be a query that was initiated as part of transaction abort to get the remote
1133
1143
* side back to the appropriate state.
1134
1144
*
1135
- * It's not a huge problem if we throw an ERROR here, but if we get into error
1136
- * recursion trouble, we'll end up slamming the connection shut, which will
1137
- * necessitate failing the entire toplevel transaction even if subtransactions
1138
- * were used. Try to use WARNING where we can.
1139
- *
1140
1145
* endtime is the time at which we should give up and assume the remote
1141
1146
* side is dead. Returns true if the timeout expired, otherwise false.
1142
1147
* Sets *result except in case of a timeout.
0 commit comments