Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
cta
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Harbor Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
dCache
cta
Commits
dc662d14
Commit
dc662d14
authored
5 years ago
by
Michael Davis
Browse files
Options
Downloads
Patches
Plain Diff
[cta-admin] Adds "cta-admin tape ls --fidfile <file>" option
parent
39f4eb7b
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
cmdline/CtaAdminCmd.cpp
+14
-1
14 additions, 1 deletion
cmdline/CtaAdminCmd.cpp
cmdline/CtaAdminCmdParse.hpp
+3
-1
3 additions, 1 deletion
cmdline/CtaAdminCmdParse.hpp
xrootd-ssi-protobuf-interface
+1
-1
1 addition, 1 deletion
xrootd-ssi-protobuf-interface
with
18 additions
and
3 deletions
cmdline/CtaAdminCmd.cpp
+
14
−
1
View file @
dc662d14
...
...
@@ -398,7 +398,20 @@ void CtaAdminCmd::readListFromFile(cta::admin::OptionStrList &str_list, const st
while
(
!
ss
.
eof
())
{
std
::
string
item
;
ss
>>
item
;
if
(
!
item
.
empty
())
{
// skip blank lines or lines consisting only of whitespace
if
(
item
.
empty
())
continue
;
if
(
str_list
.
key
()
==
OptionStrList
::
FILE_ID
)
{
// Special handling for file id lists. The output from "eos find --fid <fid> /path" is:
// path=/path fid=<fid>
// We are only interested in the list of <fid>s
if
(
item
.
substr
(
0
,
4
)
==
"fid="
)
{
str_list
.
add_item
(
item
.
substr
(
4
));
}
else
{
continue
;
}
}
else
{
// default case: add all items
str_list
.
add_item
(
item
);
}
}
...
...
This diff is collapsed.
Click to expand it.
cmdline/CtaAdminCmdParse.hpp
+
3
−
1
View file @
dc662d14
...
...
@@ -328,6 +328,7 @@ const std::map<std::string, OptionString::Key> strOptions = {
* Map string list options to Protocol Buffer enum values
*/
const
std
::
map
<
std
::
string
,
OptionStrList
::
Key
>
strListOptions
=
{
{
"--fidfile"
,
OptionStrList
::
FILE_ID
},
{
"--vidfile"
,
OptionStrList
::
VID
}
};
...
...
@@ -413,6 +414,7 @@ const Option opt_drivename_cmd { Option::OPT_CMD, "--drive",
const
Option
opt_encrypted
{
Option
::
OPT_BOOL
,
"--encrypted"
,
"-e"
,
" <
\"
true
\"
or
\"
false
\"
>"
};
const
Option
opt_encryptionkeyname
{
Option
::
OPT_STR
,
"--encryptionkeyname"
,
"-k"
,
" <encryption_key_name>"
};
const
Option
opt_extended
{
Option
::
OPT_FLAG
,
"--extended"
,
"-x"
,
""
};
const
Option
opt_fidfile
{
Option
::
OPT_STR_LIST
,
"--fidfile"
,
"-i"
,
" <filename>"
};
const
Option
opt_filename
{
Option
::
OPT_STR
,
"--file"
,
"-f"
,
" <filename>"
};
const
Option
opt_firstfseq
{
Option
::
OPT_UINT
,
"--firstfseq"
,
"-f"
,
" <first_fseq>"
};
const
Option
opt_force
{
Option
::
OPT_BOOL
,
"--force"
,
"-f"
,
" <
\"
true
\"
or
\"
false
\"
>"
};
...
...
@@ -573,7 +575,7 @@ const std::map<cmd_key_t, cmd_val_t> cmdOptions = {
{{
AdminCmd
::
CMD_TAPE
,
AdminCmd
::
SUBCMD_LS
},
{
opt_vid
.
optional
(),
opt_mediatype
.
optional
(),
opt_vendor
.
optional
(),
opt_logicallibrary
.
optional
(),
opt_tapepool
.
optional
(),
opt_vo
.
optional
(),
opt_capacity
.
optional
(),
opt_disabled
.
optional
(),
opt_full
.
optional
(),
opt_readonly
.
optional
(),
opt_all
.
optional
()
}},
opt_disabled
.
optional
(),
opt_full
.
optional
(),
opt_readonly
.
optional
(),
opt_fidfile
.
optional
(),
opt_all
.
optional
()
}},
{{
AdminCmd
::
CMD_TAPE
,
AdminCmd
::
SUBCMD_LABEL
},
{
opt_vid
,
opt_force
.
optional
()
}},
/*----------------------------------------------------------------------------------------------------*/
...
...
This diff is collapsed.
Click to expand it.
xrootd-ssi-protobuf-interface
@
dfafb9fb
Subproject commit
877182104dfc54c73724924a98f94350d1aff2a4
Subproject commit
dfafb9fbd6bf91c9040852c20bd30059e0b6ee7b
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment