summaryrefslogtreecommitdiff
path: root/usr/src/man/man3dat/dat_psp_create.3dat
blob: ea42c05a0393a3e60fb3052c76e6dfaa5c960d30 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
'\" te
.\" This manual page is derived from the DAT/uDAPL 1.2 specification.
.\" Portions Copyright (c) 2007, Sun Microsystems, Inc. All Rights Reserved.
.\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
.\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
.TH dat_psp_create 3DAT "16 Jul 2004" "SunOS 5.11" "Direct Access Transport Library Functions"
.SH NAME
dat_psp_create \- create a persistent Public Service Point
.SH SYNOPSIS
.LP
.nf
cc [ \fIflag\fR\&.\|.\|. ] \fIfile\fR\&.\|.\|. \fB-ldat\fR [ \fIlibrary\fR\&.\|.\|. ] 
#include <\fBdat/udat.h\fR>

DAT_RETURN
    dat_psp_create(
    IN    DAT_IA_HANDLE    \fIia_handle\fR,
    IN    DAT_CONN_QUAL    \fIconn_qual\fR,
    IN    DAT_EVD_HANDLE   \fIevd_handle\fR,
    IN    DAT_PSP_FLAGS    \fIpsp_flags\fR,
    OUT   DAT_PSP_HANDLE   *\fIpsp_handle\fR
    )
.fi

.SH PARAMETERS
.sp
.ne 2
.mk
.na
\fB\fIia_handle\fR\fR
.ad
.RS 14n
.rt  
Handle for an instance of DAT IA.
.RE

.sp
.ne 2
.mk
.na
\fB\fIconn_qual\fR\fR
.ad
.RS 14n
.rt  
Connection Qualifier of the IA on which the Public Service Point is listening.
.RE

.sp
.ne 2
.mk
.na
\fB\fIevd_handle\fR\fR
.ad
.RS 14n
.rt  
Event Dispatcher that provides the Connection Requested Events to the Consumer.
The size of the event queue for the Event Dispatcher controls the size of the
backlog for the created Public Service Point.
.RE

.sp
.ne 2
.mk
.na
\fB\fIpsp_flags\fR\fR
.ad
.RS 14n
.rt  
Flag that indicates whether the Provider or Consumer creates an Endpoint per
arrived Connection Request. The value of \fBDAT_PSP_PROVIDER\fR indicates that
the Consumer wants to get an Endpoint from the Provider; a value of
\fBDAT_PSP_CONSUMER\fR means the Consumer does not want the Provider to provide
an Endpoint for each arrived Connection Request.
.RE

.sp
.ne 2
.mk
.na
\fB\fIpsp_handle\fR\fR
.ad
.RS 14n
.rt  
Handle to an opaque Public Service Point.
.RE

.SH DESCRIPTION
.sp
.LP
The \fBdat_psp_create()\fR function creates a persistent Public Service Point
that can receive multiple requests for connection and generate multiple
Connection Request instances that are delivered through the specified Event
Dispatcher in Notification events.
.sp
.LP
The \fBdat_psp_create()\fR function is blocking. When the Public Service Point
is created, \fBDAT_SUCCESS\fR is returned and \fIpsp_handle\fR contains a
handle to an opaque Public Service Point Object.
.sp
.LP
There is no explicit backlog for a Public Service Point. Instead, Consumers can
control the size of backlog through the queue size of the associated Event
Dispatcher.
.sp
.LP
The \fIpsp_flags\fR parameter allows Consumers to request that the Provider
create an implicit Endpoint for each incoming Connection Request, or request
that the Provider should not create one per Connection Request. If the Provider
cannot satisfy the request, the operation shall fail and
\fBDAT_MODEL_NOT_SUPPORTED\fR is returned.
.sp
.LP
All Endpoints created by the Provider have \fBDAT_HANDLE_NULL\fR  for the
Protection Zone and all Event Dispatchers. The Provider sets up Endpoint
attributes to match the Active side connection request. The Consumer can change
Endpoint parameters. Consumers should change Endpoint parameters, especially PZ
and EVD, and are advised to change parameters for local accesses prior to the
connection request acceptance with the Endpoint.
.SH RETURN VALUES
.sp
.ne 2
.mk
.na
\fB\fBDAT_SUCCESS\fR\fR
.ad
.RS 30n
.rt  
The operation was successful.
.RE

.sp
.ne 2
.mk
.na
\fB\fBDAT_INSUFFICIENT_RESOURCES\fR\fR
.ad
.RS 30n
.rt  
The operation failed due to resource limitations.
.RE

.sp
.ne 2
.mk
.na
\fB\fBDAT_INVALID_HANDLE\fR\fR
.ad
.RS 30n
.rt  
The \fIia_handle\fR or \fIevd_handle\fR parameter is invalid.
.RE

.sp
.ne 2
.mk
.na
\fB\fBDAT_INVALID_PARAMETER\fR\fR
.ad
.RS 30n
.rt  
The \fIconn_qual\fR or \fIpsp_flags\fR parameter is invalid.
.RE

.sp
.ne 2
.mk
.na
\fB\fBDAT_CONN_QUAL_IN_USE\fR\fR
.ad
.RS 30n
.rt  
The specified Connection Qualifier was in use.
.RE

.sp
.ne 2
.mk
.na
\fB\fBDAT_MODEL_NOT_SUPPORTED\fR\fR
.ad
.RS 30n
.rt  
The requested Model was not supported by the Provider.
.RE

.SH USAGE
.sp
.LP
Two uses of a Public Service Point are as follows:
.sp
.ne 2
.mk
.na
\fBModel 1\fR
.ad
.RS 11n
.rt  
For this model, the Provider manipulates a pool of Endpoints for a Public
Service Point. The Provider can use the same pool for more than one Public
Service Point.
.RS +4
.TP
.ie t \(bu
.el o
The DAT Consumer creates a Public Service Point with a \fIflag\fR set to
\fBDAT_PSP_PROVIDER\fR.
.RE
.RS +4
.TP
.ie t \(bu
.el o
The Public Service Point does the following:
.RS +4
.TP
.ie t \(bu
.el o
Collects native transport information reflecting a received Connection Reques
.RE
.RS +4
.TP
.ie t \(bu
.el o
Creates an instance of Connection Reques
.RE
.RS +4
.TP
.ie t \(bu
.el o
Creates a Connection Request Notice (event) that includes the Connection
Request instance (thatwhich includes, among others, Public Service Point, its
Connection Qualifier, Provider-generated Local Endpoint, and information about
remote Endpoint)
.RE
.RS +4
.TP
.ie t \(bu
.el o
Delivers the Connection Request Notice to the Consumer-specified target (CNO)
\fIevd_handle\fR
.sp
The Public Service Point is persistent and continues to listen for incoming
requests for connection.
.RE
.RE
.RS +4
.TP
.ie t \(bu
.el o
Upon receiving a connection request, or at some time subsequent to that, the
DAT Consumer can modify the provided local Endpoint to match the Connection
Request and must either \fBaccept()\fR or \fBreject()\fR the pending Connection
Request.
.RE
.RS +4
.TP
.ie t \(bu
.el o
If accepted, the provided Local Endpoint is now in a "connected" state and is
fully usable for this connection, pending only any native transport mandated
RTU (ready-to-use) messages. This includes binding it to the IA port if that
was not done previously. The Consumer is notified that the Endpoint is in
Connected state by a Connection Established Event on the Endpoint
\fIconnect_evd_handle\fR.
.RE
.RS +4
.TP
.ie t \(bu
.el o
If rejected, control of the Local Endpoint point is returned back to the
Provider and its \fIep_handle\fR is no longer usable by the Consumer.
.RE
.RE

.sp
.ne 2
.mk
.na
\fBModel 2\fR
.ad
.RS 11n
.rt  
For this model, the Consumer manipulates a pool of Endpoints. Consumers can use
the same pool for more than one Service Point.
.RS +4
.TP
.ie t \(bu
.el o
DAT Consumer creates a Public Service Point with a \fIflag\fR set to
\fBDAT_PSP_CONSUMER\fR.
.RE
.RS +4
.TP
.ie t \(bu
.el o
Public Service Point:
.RS +4
.TP
.ie t \(bu
.el o
Collects native transport information reflecting a received Connection Request
.RE
.RS +4
.TP
.ie t \(bu
.el o
Creates an instance of Connection Request
.RE
.RS +4
.TP
.ie t \(bu
.el o
Creates a Connection Request Notice (event) that includes the Connection
Request instance (which includes, among others, Public Service Point, its
Connection Qualifier, Provider-generated Local Endpoint and information about
remote Endpoint)
.RE
.RS +4
.TP
.ie t \(bu
.el o
Delivers the Connection Request Notice to the Consumer-specified target (CNO)
\fIevd_handle\fR
.sp
The Public Service Point is persistent and continues to listen for incoming
requests for connection.
.RE
.RE
.RS +4
.TP
.ie t \(bu
.el o
The Consumer creates a pool of Endpoints that it uses for accepting Connection
Requests. Endpoints can be created and modified at any time prior to accepting
a Connection Request with that Endpoint.
.RE
.RS +4
.TP
.ie t \(bu
.el o
Upon receiving a connection request or at some time subsequent to that, the DAT
Consumer can modify its local Endpoint to match the Connection Request and must
either \fBaccept()\fR or \fBreject()\fR the pending Connection Request.
.RE
.RS +4
.TP
.ie t \(bu
.el o
If accepted, the provided Local Endpoint is now in a "connected" state and is
fully usable for this connection, pending only any native transport mandated
RTU messages. This includes binding it to the IA port if that was not done
previously. The Consumer is notified that the Endpoint is in Connected state by
a Connection Established Event on the Endpoint \fIconnect_evd_handle\fR.
.RE
.RS +4
.TP
.ie t \(bu
.el o
If rejected, the Consumer does not have to provide any Endpoint for
\fBdat_cr_reject\fR(3DAT).
.RE
.RE

.SH ATTRIBUTES
.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp

.sp
.TS
tab() box;
cw(2.75i) |cw(2.75i) 
lw(2.75i) |lw(2.75i) 
.
ATTRIBUTE TYPEATTRIBUTE VALUE
_
Interface StabilityStandard: uDAPL, 1.1, 1.2
_
MT-LevelSafe
.TE

.SH SEE ALSO
.sp
.LP
\fBdat_cr_reject\fR(3DAT), \fBlibdat\fR(3LIB), \fBattributes\fR(5)