Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
V
vospace-file-service
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
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
VOSpace INAF
vospace-file-service
Commits
7db753d0
Commit
7db753d0
authored
3 years ago
by
nfcalabria
Browse files
Options
Downloads
Patches
Plain Diff
Minor fix
parent
071f849d
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/main/java/it/inaf/ia2/transfer/service/ArchiveService.java
+33
-29
33 additions, 29 deletions
...ain/java/it/inaf/ia2/transfer/service/ArchiveService.java
with
33 additions
and
29 deletions
src/main/java/it/inaf/ia2/transfer/service/ArchiveService.java
+
33
−
29
View file @
7db753d0
...
@@ -134,8 +134,8 @@ public class ArchiveService {
...
@@ -134,8 +134,8 @@ public class ArchiveService {
// it will be initialized only when necessary
// it will be initialized only when necessary
Map
<
Integer
,
String
>
portalLocationUrls
=
null
;
Map
<
Integer
,
String
>
portalLocationUrls
=
null
;
List
<
ArchiveEntryDescriptor
>
noTargetEntryDescriptors
=
List
<
ArchiveEntryDescriptor
>
noTargetEntryDescriptors
entryDescriptors
.
stream
().
filter
(
ed
->
!
ed
.
isPointingToAnotherNode
())
=
entryDescriptors
.
stream
().
filter
(
ed
->
!
ed
.
isPointingToAnotherNode
())
.
collect
(
Collectors
.
toList
());
.
collect
(
Collectors
.
toList
());
// Start with archive entry descriptors which don't point to another node
// Start with archive entry descriptors which don't point to another node
...
@@ -153,8 +153,8 @@ public class ArchiveService {
...
@@ -153,8 +153,8 @@ public class ArchiveService {
}
}
}
}
List
<
ArchiveEntryDescriptor
>
pointingEntryDescriptors
=
List
<
ArchiveEntryDescriptor
>
pointingEntryDescriptors
entryDescriptors
.
stream
().
filter
(
ed
->
ed
.
isPointingToAnotherNode
())
=
entryDescriptors
.
stream
().
filter
(
ed
->
ed
.
isPointingToAnotherNode
())
.
collect
(
Collectors
.
toList
());
.
collect
(
Collectors
.
toList
());
// Now archive entry descriptors pointing to another node
// Now archive entry descriptors pointing to another node
...
@@ -191,11 +191,15 @@ public class ArchiveService {
...
@@ -191,11 +191,15 @@ public class ArchiveService {
return
;
return
;
}
}
// I
expect
only external links
// I
retrieve
only external links
// local links have been resolved before calling this endpoint
// local links have been resolved before calling this endpoint
// TODO: we need to discuss about internal links in container nodes
if
(
fileInfo
.
isLink
())
{
if
(
fileInfo
.
isLink
())
{
String
target
=
fileInfo
.
getTarget
();
if
(!
target
.
startsWith
(
"vos://"
))
{
downloadExternalLinkIntoArchive
(
fileInfo
,
relPath
,
downloadExternalLinkIntoArchive
(
fileInfo
,
relPath
,
tokenPrincipal
,
handler
,
servletRequest
);
tokenPrincipal
,
handler
,
servletRequest
);
}
return
;
return
;
}
}
...
...
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