Debian Codegraph @

upstream/opensuse-tumbleweed/man3/Test2::Manual::Concurrency.3pm

raw
1 .\" -*- mode: troff; coding: utf-8 -*-
2 .\" Automatically generated by Pod::Man v6.0.2 (Pod::Simple 3.45)
3 .\"
4 .\" Standard preamble:
5 .\" ========================================================================
6 .de Sp \" Vertical space (when we can't use .PP)
7 .if t .sp .5v
8 .if n .sp
9 ..
10 .de Vb \" Begin verbatim text
11 .ft CW
12 .nf
13 .ne \\$1
14 ..
15 .de Ve \" End verbatim text
16 .ft R
17 .fi
18 ..
19 .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>.
20 .ie n \{\
21 . ds C` ""
22 . ds C' ""
23 'br\}
24 .el\{\
25 . ds C`
26 . ds C'
27 'br\}
28 .\"
29 .\" Escape single quotes in literal strings from groff's Unicode transform.
30 .ie \n(.g .ds Aq \(aq
31 .el .ds Aq '
32 .\"
33 .\" If the F register is >0, we'll generate index entries on stderr for
34 .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
35 .\" entries marked with X<> in POD. Of course, you'll have to process the
36 .\" output yourself in some meaningful fashion.
37 .\"
38 .\" Avoid warning from groff about undefined register 'F'.
39 .de IX
40 ..
41 .nr rF 0
42 .if \n(.g .if rF .nr rF 1
43 .if (\n(rF:(\n(.g==0)) \{\
44 . if \nF \{\
45 . de IX
46 . tm Index:\\$1\t\\n%\t"\\$2"
47 ..
48 . if !\nF==2 \{\
49 . nr % 0
50 . nr F 2
51 . \}
52 . \}
53 .\}
54 .rr rF
55 .\"
56 .\" Required to disable full justification in groff 1.23.0.
57 .if n .ds AD l
58 .\" ========================================================================
59 .\"
60 .IX Title "Test2::Manual::Concurrency 3pm"
61 .TH Test2::Manual::Concurrency 3pm 2026-03-09 "perl v5.42.1" "Perl Programmers Reference Guide"
62 .\" For nroff, turn off justification. Always turn off hyphenation; it makes
63 .\" way too many mistakes in technical documents.
64 .if n .ad l
65 .nh
66 .SH NAME
67 Test2::Manual::Concurrency \- Documentation for Concurrency support.
68 .SH FORKING
69 .IX Header "FORKING"
70 .SS Test2
71 .IX Subsection "Test2"
72 Test2 supports forking. For forking to work you need to load Test2::IPC.
73 .SS Test::Builder
74 .IX Subsection "Test::Builder"
75 Test::Builder Did not used to support forking, but now that it is based on
76 Test2 it does. Test2::IPC must be loaded just as with Test2.
77 .SS Test2::Suite
78 .IX Subsection "Test2::Suite"
79 Test2::Suite tools should all work fine with \fItrue\fR forking unless
80 otherwise noted. Pseudo\-fork via threads (Windows and a few others) is not
81 supported, but may work.
82 .PP
83 Patches will be accepted to repair any pseudo\-fork issues, but for these to be
84 used or tested they must be requested. Fork tests should not run on pseudo\-fork
85 systems unless they are requested with an environment var, or the
86 AUTHOR_TESTING var. Pseudo\-fork is fragile, and we do not want to block install
87 due to a pseudo\-fork flaw.
88 .SS Test::SharedFork
89 .IX Subsection "Test::SharedFork"
90 Test::SharedFork is currently support and maintained, though it is no longer
91 necessary thanks to Test2::IPC. If usage ever drops off then the module may
92 be deprecated, but for now the policy is to not let it break. Currently it
93 simply loads Test2::IPC if it can, and falls back to the old methods on
94 legacy installs.
95 .SS Others
96 .IX Subsection "Others"
97 Individual authors are free to support or not support forking as they see fit.
98 .SH THREADING
99 .IX Header "THREADING"
100 \&\fBNote\fR This only applies to ithreads.
101 .SS Test2
102 .IX Subsection "Test2"
103 The core of Test2 supports threading so long as Test2::IPC is loaded. Basic
104 threading support (making sure events make it to the parent thread) is fully
105 supported, and must not be broken.
106 .PP
107 Some times perl installs have broken threads (Some 5.10 versions compiled on
108 newer gcc\*(Aqs will segv by simply starting a thread). This is beyond Test2\*(Aqs
109 control, and not solvable in Test2. That said we strive for basic threading
110 support on perl 5.8.1+.
111 .PP
112 If Test2 fails for threads on any perl 5.8 or above, and it is reasonably
113 possible for Test2 to work around the issue, it should. (Patches and bug
114 reports welcome).
115 .SS Test::Builder
116 .IX Subsection "Test::Builder"
117 Test::Builder has had thread support for a long time. With Test2 the
118 mechanism for thread support was switched to Test2::IPC. Test::Builder
119 should still support threads as much as it did before the switch to Test2.
120 Support includes auto\-enabling thread support if threads is loaded before
121 Test::Builder.
122 .PP
123 If there is a deviation between the new and old threading behavior then it is a
124 bug (unless the old behavior itself can be classified as a bug.) Please report
125 (or patch!) any such threading issues.
126 .SS Test2::Suite
127 .IX Subsection "Test2::Suite"
128 Tools in Test2::Suite have minimal threading support. Most of these tools do
129 not care/notice threading and simply work because Test2::IPC handles it.
130 Feel free to report any thread related bugs in Test2::Suite. Be aware though
131 that these tools are not legacy, and have no pre\-existing thread support, we
132 reserve the right to refuse adding thread support to them.
133 .PP
134 \fITest2::Workflow\fR
135 .IX Subsection "Test2::Workflow"
136 .PP
137 Test2::Workflow has been merged into Test2::Suite, so it gets addressed
138 by this policy.
139 .PP
140 Test2::Workflow has thread support, but you must ask for it. Thread tests
141 for Test2::Workflow do not event run without setting either the AUTHOR_TESTING
142 env var, or the T2_DO_THREAD_TESTS env var.
143 .PP
144 To use threads with Test2::Workflow you must set the T2_WORKFLOW_USE_THREADS
145 env var.
146 .PP
147 If you do rely on threads with Test2::Workflow and find a bug please report it,
148 but it will be given an ultra\-low priority. Merging patches that fix threading
149 issues will be given normal priority.
150 .SH "SEE ALSO"
151 .IX Header "SEE ALSO"
152 Test2 \- Test2 itself.
153 .PP
154 Test2::Suite \- Initial tools built using Test2.
155 .PP
156 Test2::Manual \- Primary index of the manual.
157 .SH SOURCE
158 .IX Header "SOURCE"
159 The source code repository for Test2\-Manual can be found at
160 \&\fIhttps://github.com/Test\-More/test\-more/\fR.
161 .SH MAINTAINERS
162 .IX Header "MAINTAINERS"
163 .IP "Chad Granum <[email protected]>" 4
164 .IX Item "Chad Granum <[email protected]>"
165 .SH AUTHORS
166 .IX Header "AUTHORS"
167 .IP "Chad Granum <[email protected]>" 4
168 .IX Item "Chad Granum <[email protected]>"
169 .SH COPYRIGHT
170 .IX Header "COPYRIGHT"
171 Copyright Chad Granum <[email protected]>.
172 .PP
173 This program is free software; you can redistribute it and/or
174 modify it under the same terms as Perl itself.
175 .PP
176 See \fIhttp://dev.perl.org/licenses/\fR