-
Notifications
You must be signed in to change notification settings - Fork 31
Use kibana server hostname for puppeteer to access pages #99
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
import { async } from 'rxjs/internal/scheduler/async'; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Are the changes in this file related to the title of the PR? I feel this is a different optimization refactor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. That's just an unused import There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not just this line, I'm referring to the other changes in the file as well- meant to highlight the whole file There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The other change is just rewriting the import to typescript style. |
||
/* | ||
* Copyright 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. | ||
* | ||
|
@@ -16,9 +15,9 @@ import { async } from 'rxjs/internal/scheduler/async'; | |
|
||
import { DATA_REPORT_CONFIG } from './constants'; | ||
|
||
const esb = require('elastic-builder'); | ||
const moment = require('moment'); | ||
const converter = require('json-2-csv'); | ||
import esb from 'elastic-builder'; | ||
import moment from 'moment'; | ||
import converter from 'json-2-csv'; | ||
|
||
export var metaData = { | ||
saved_search_id: <string>null, | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,4 +15,3 @@ | |
|
||
require('babel-polyfill'); | ||
require('core-js/stable'); | ||
require('axios/lib/adapters/http'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we be hard-coding the host like this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ideally, we should extract the server host/port from
kibana.yml
, but the new platform applies some restrictions to access certain fields. More details can be found in this issue #98There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we get the local host from a
window.location
ordocument
method instead? I think those should be fine to access in the new platform.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That
window.location
won't work on server side. The UI side still keeps the usage ofwindow.location
which is fine.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ack, miss from me- forgot this was on server-side