Skip to content

Commit e964195

Browse files
committed
libjob: support f58plain encoding
Problem: flux_job_id_encode() cannot encode a job id using FLUID_STRING_F58_PLAIN. Add support for "f58plain" encoding.
1 parent 24553f6 commit e964195

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/common/libjob/id.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,8 @@ int flux_job_id_encode (flux_jobid_t id,
8888
t = FLUID_STRING_MNEMONIC;
8989
else if (strcasecmp (type, "f58") == 0)
9090
t = FLUID_STRING_F58;
91+
else if (strcasecmp (type, "f58plain") == 0)
92+
t = FLUID_STRING_F58_PLAIN;
9193
else if (strcasecmp (type, "emoji") == 0)
9294
t = FLUID_STRING_EMOJI;
9395
else {

src/common/libjob/job.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ int flux_job_id_parse (const char *s, flux_jobid_t *id);
8484
/* Encode a jobid into encoding "type", writing the result to buffer
8585
* buf of size bufsz.
8686
* Supported encoding types include:
87-
* "dec", "hex", "kvs", "dothex", "words", or "f58".
87+
* "dec", "hex", "kvs", "dothex", "words", "f58", or "f58plain"
8888
* Returns 0 on success, -1 on failure with errno set:
8989
* EPROTO: Invalid encoding type
9090
* EINVAL: Invalid other argument

0 commit comments

Comments
 (0)