Skip to content

Commit 829cd87

Browse files
authored
Merge pull request #298 from rhc54/rfc/v4fix
Minor touchups and additions
2 parents ebd0b81 + 7b9d1a6 commit 829cd87

File tree

4 files changed

+38
-22
lines changed

4 files changed

+38
-22
lines changed

Chap_API_NonReserved_Keys.tex

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ \chapter{Process-Related Non-Reserved Keys}
99
application when information needs to be exchanged between processes (e.g.,
1010
where connection information is required and the host environment does not
1111
support the \refterm{instant on} option) or where the host environment does not
12-
provide a required piece of data. Other than the prefix, there are no
13-
restrictions on the use or content of non-reserved keys.
12+
provide a required piece of data. Beyond the restriction on name prefix,
13+
non-reserved keys are required to be unique across conflicting \emph{scopes} as defined in Section \ref{api:nres:scope} - e,g., a non-reserved key cannot be posted by the same process in both the \refconst{PMIX_LOCAL} and \refconst{PMIX_REMOTE} scopes (note that posting the key in the \refconst{PMIX_GLOBAL} scope would have met the desired objective).
1414

1515
\ac{PMIx} provides support for two methods of exchanging non-reserved keys:
1616

@@ -93,6 +93,7 @@ \subsection{\code{PMIx_Put}}
9393
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
9494
\subsubsection{Scope of Put Data}
9595
\declarestruct{pmix_scope_t}
96+
\label{api:nres:scope}
9697

9798
\versionMarker{1.0}
9899
The \refstruct{pmix_scope_t} structure is a \code{uint8_t} type that defines the availability of data passed to \refapi{PMIx_Put}.
@@ -212,9 +213,15 @@ \section{Retrieval rules for non-reserved keys}
212213
\item Check the local \ac{PMIx} client cache for the requested key - if not found and either the \refattr{PMIX_OPTIONAL} or \refattr{PMIX_GET_REFRESH_CACHE} attribute was given, the search will stop at this point and return the \refconst{PMIX_ERR_NOT_FOUND} status.
213214

214215
\item Request the information from the local \ac{PMIx} server. The server
215-
will check its cache for the specified key. If the
216-
value still isn't found and the \refattr{PMIX_IMMEDIATE} attribute was
217-
given, then the library shall return the \refconst{PMIX_ERR_NOT_FOUND}
216+
will check its cache for the specified key within the appropriate scope as
217+
defined by the process that originally posted the key. If the value exists
218+
in a scope that contains the requesting process, then the value shall be
219+
returned. If the value exists, but in a scope that excludes the requesting
220+
process, then the server shall immediately return the
221+
\refconst{PMIX_ERR_EXISTS_OUTSIDE_SCOPE}.
222+
223+
If the value still isn't found and the \refattr{PMIX_IMMEDIATE} attribute
224+
was given, then the library shall return the \refconst{PMIX_ERR_NOT_FOUND}
218225
error constant to the requester. Otherwise, the \ac{PMIx} server library
219226
will take one of the following actions:
220227
\begin{compactitemize}

Chap_API_Struct.tex

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,9 @@ \subsection{PMIx Return Status Constants}
124124
Requested operation would overwrite an existing value - typically returned
125125
when an operation would overwrite an existing file or directory.
126126
%
127+
\declareconstitemNEW{PMIX_ERR_EXISTS_OUTSIDE_SCOPE}
128+
The requested key exists, but was posted in a \emph{scope} (see Section \ref{api:nres:scope}) that does not include the requester
129+
%
127130
\declareconstitem{PMIX_ERR_INVALID_CRED}
128131
Invalid security credentials.
129132
%

Chap_API_Sync_Access.tex

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,7 @@ \section{\code{PMIx_Get}}
210210
\begin{itemize}
211211
\item \refconst{PMIX_SUCCESS} The requested data has been returned in the manner requested (i.e., in a provided static memory location )
212212
\item \refconst{PMIX_ERR_BAD_PARAM} A bad parameter was passed to the function call - e.g., the request included the \refattr{PMIX_GET_STATIC_VALUES} directive, but the provided storage location was \code{NULL}
213+
\item \refconst{PMIX_ERR_EXISTS_OUTSIDE_SCOPE} The requested key exists, but was posted in a \emph{scope} (see Section \ref{api:nres:scope}) that does not include the requester.
213214
\item \refconst{PMIX_ERR_NOT_FOUND} The requested data was not available.
214215
\item a non-zero \ac{PMIx} error constant indicating a reason for the request's failure.
215216
\end{itemize}
@@ -286,14 +287,14 @@ \subsection{\code{PMIx_Get_nb}}
286287

287288
\begin{itemize}
288289
\item \refconst{PMIX_SUCCESS}, indicating that the request is being processed by the host environment - result will be returned in the provided \refarg{cbfunc}. Note that the library must not invoke the callback function prior to returning from the \ac{API}.
289-
\item \refconst{PMIX_OPERATION_SUCCEEDED}, indicating that the request was immediately processed and returned \textit{success} - the \refarg{cbfunc} will \textit{not} be called.
290290
\item a \ac{PMIx} error constant indicating either an error in the input or that the request was immediately processed and failed - the \refarg{cbfunc} will \textit{not} be called.
291291
\end{itemize}
292292

293293
If executed, the status returned in the provided callback function will be one of the following constants:
294294

295295
\begin{itemize}
296296
\item \refconst{PMIX_SUCCESS} The requested data has been returned.
297+
\item \refconst{PMIX_ERR_EXISTS_OUTSIDE_SCOPE} The requested key exists, but was posted in a \emph{scope} (see Section \ref{api:nres:scope}) that does not include the requester.
297298
\item \refconst{PMIX_ERR_NOT_FOUND} The requested data was not available.
298299
\item a non-zero \ac{PMIx} error constant indicating a reason for the request's failure.
299300
\end{itemize}

Chap_Revisions.tex

Lines changed: 21 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -413,32 +413,37 @@ \section{Version 4.0: Sept 2020}
413413

414414
\subsection{Added Constants}
415415

416+
%
417+
\littleheader{General error constants}
418+
\refconst{PMIX_ERR_EXISTS_OUTSIDE_SCOPE} \\
419+
420+
%
416421
\littleheader{Data type constants}
417-
\refconst{PMIX_COORD}
418-
\refconst{PMIX_REGATTR}
419-
\refconst{PMIX_REGEX}
420-
\refconst{PMIX_JOB_STATE}
421-
\refconst{PMIX_LINK_STATE}
422-
\refconst{PMIX_PROC_CPUSET}
423-
\refconst{PMIX_GEOMETRY}
424-
\refconst{PMIX_DEVICE_DIST}
425-
\refconst{PMIX_ENDPOINT}
426-
\refconst{PMIX_TOPO}
427-
\refconst{PMIX_DEVTYPE}
428-
\refconst{PMIX_LOCTYPE}
429-
\refconst{PMIX_DATA_TYPE_MAX}
422+
\refconst{PMIX_COORD} \\
423+
\refconst{PMIX_REGATTR} \\
424+
\refconst{PMIX_REGEX} \\
425+
\refconst{PMIX_JOB_STATE} \\
426+
\refconst{PMIX_LINK_STATE} \\
427+
\refconst{PMIX_PROC_CPUSET} \\
428+
\refconst{PMIX_GEOMETRY} \\
429+
\refconst{PMIX_DEVICE_DIST} \\
430+
\refconst{PMIX_ENDPOINT} \\
431+
\refconst{PMIX_TOPO} \\
432+
\refconst{PMIX_DEVTYPE} \\
433+
\refconst{PMIX_LOCTYPE} \\
434+
\refconst{PMIX_DATA_TYPE_MAX} \\
430435

431436
%
432437
\littleheader{Server constants}
433-
\refconst{PMIX_ERR_REPEAT_ATTR_REGISTRATION}
438+
\refconst{PMIX_ERR_REPEAT_ATTR_REGISTRATION} \\
434439
%
435440
%
436441
\littleheader{Job-Mgmt constants}
437-
\refconst{PMIX_ERR_CONFLICTING_CLEANUP_DIRECTIVES}
442+
\refconst{PMIX_ERR_CONFLICTING_CLEANUP_DIRECTIVES} \\
438443
%
439444
%
440445
\littleheader{Publish constants}
441-
\refconst{PMIX_ERR_DUPLICATE_KEY}
446+
\refconst{PMIX_ERR_DUPLICATE_KEY} \\
442447
%
443448
%
444449
\littleheader{Tool constants}

0 commit comments

Comments
 (0)