Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
351d1321
Commit
351d1321
authored
Feb 24, 2021
by
Marius Bobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use ETag header received from backend
parent
a7dac970
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
10 deletions
+18
-10
app/assets/javascripts/pipelines/components/graph/graph_component_wrapper.vue
...ts/pipelines/components/graph/graph_component_wrapper.vue
+4
-1
app/assets/javascripts/pipelines/components/graph/linked_pipelines_column.vue
...ts/pipelines/components/graph/linked_pipelines_column.vue
+11
-8
app/assets/javascripts/pipelines/pipeline_details_bundle.js
app/assets/javascripts/pipelines/pipeline_details_bundle.js
+1
-0
app/assets/javascripts/pipelines/pipeline_details_graph.js
app/assets/javascripts/pipelines/pipeline_details_graph.js
+2
-1
No files found.
app/assets/javascripts/pipelines/components/graph/graph_component_wrapper.vue
View file @
351d1321
...
...
@@ -23,6 +23,9 @@ export default {
pipelineProjectPath
:
{
default
:
''
,
},
graphqlResourceEtag
:
{
default
:
''
,
},
},
data
()
{
return
{
...
...
@@ -45,7 +48,7 @@ export default {
},
headers
:
{
'
X-GITLAB-GRAPHQL-FEATURE-CORRELATION
'
:
'
verify/ci/pipeline-graph
'
,
'
X-GITLAB-GRAPHQL-RESOURCE-ETAG
'
:
`pipelines/id/
${
this
.
pipelineIid
}
`
,
'
X-GITLAB-GRAPHQL-RESOURCE-ETAG
'
:
this
.
graphqlResourceEtag
,
'
X-REQUESTED_WITH
'
:
'
XMLHttpRequest
'
,
},
};
...
...
app/assets/javascripts/pipelines/components/graph/linked_pipelines_column.vue
View file @
351d1321
...
...
@@ -72,14 +72,17 @@ export default {
this
.
$apollo
.
addSmartQuery
(
'
currentPipeline
'
,
{
query
:
getPipelineDetails
,
pollInterval
:
10000
,
context
:
{
fetchOptions
:
{
method
:
'
GET
'
,
},
headers
:
{
'
X-GITLAB-GRAPHQL-FEATURE-CORRELATION
'
:
'
verify/ci/pipeline-graph
'
,
'
X-GITLAB-GRAPHQL-RESOURCE-ETAG
'
:
'
pipelines/id/123
'
,
},
context
()
{
return
{
fetchOptions
:
{
method
:
'
GET
'
,
},
headers
:
{
'
X-GITLAB-GRAPHQL-FEATURE-CORRELATION
'
:
'
verify/ci/pipeline-graph
'
,
'
X-GITLAB-GRAPHQL-RESOURCE-ETAG
'
:
this
.
graphqlResourceEtag
,
'
X-REQUESTED_WITH
'
:
'
XMLHttpRequest
'
,
},
}
},
variables
()
{
return
{
...
...
app/assets/javascripts/pipelines/pipeline_details_bundle.js
View file @
351d1321
...
...
@@ -99,6 +99,7 @@ export default async function initPipelineDetailsBundle() {
pipelineProjectPath
,
pipelineIid
,
metricsPath
,
graphqlResourceEtag
,
);
}
catch
{
Flash
(
__
(
'
An error occurred while loading the pipeline.
'
));
...
...
app/assets/javascripts/pipelines/pipeline_details_graph.js
View file @
351d1321
...
...
@@ -16,7 +16,7 @@ const apolloProvider = new VueApollo({
),
});
const
createPipelinesDetailApp
=
(
selector
,
pipelineProjectPath
,
pipelineIid
,
metricsPath
)
=>
{
const
createPipelinesDetailApp
=
(
selector
,
pipelineProjectPath
,
pipelineIid
,
metricsPath
,
graphqlResourceEtag
)
=>
{
// eslint-disable-next-line no-new
new
Vue
({
el
:
selector
,
...
...
@@ -28,6 +28,7 @@ const createPipelinesDetailApp = (selector, pipelineProjectPath, pipelineIid, me
metricsPath
,
pipelineProjectPath
,
pipelineIid
,
graphqlResourceEtag
,
dataMethod
:
GRAPHQL
,
},
errorCaptured
(
err
,
_vm
,
info
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment