All Downloads are FREE. Search and download functionalities are using the official Maven repository.

web-interface.assets.6e61897c-63.472622149827c1587209.js.map Maven / Gradle / Ivy

There is a newer version: 6.0.2
Show newest version
{"version":3,"sources":["webpack:///./src/components/indexers/IndexerFailuresComponent.jsx","webpack:///./src/pages/IndexSetPage.tsx","webpack:///./src/components/indexers/IndexerClusterHealth.jsx","webpack:///./src/components/indexers/IndexerClusterHealthSummary.jsx","webpack:///./src/components/indexers/IndexerFailure.jsx","webpack:///./src/components/indexers/IndexerFailuresList.jsx"],"names":["IndexerFailuresStore","StoreProvider","getStore","IndexerFailuresComponent","bsStyle","state","total","name","_iconForFailureCount","_formatTextForFailureCount","to","Routes","SYSTEM","INDICES","FAILURES","bsSize","className","count","numeral","format","since","moment","subtract","then","response","setState","content","undefined","this","_formatFailuresSummary","md","page","DocsHelper","PAGES","INDEXER_FAILURES","text","React","Component","CombinedProvider","get","IndexSetsStore","IndexSetsActions","IndicesStore","IndicesActions","IndexerOverviewStore","IndexerOverviewActions","IndexSetPage","props","indices","indexerOverview","Object","keys","length","mdOffset","header","indexSet","timerId","indexSetId","params","list","setInterval","multiple","clearInterval","_isLoading","indicesInfo","indicesOverview","indexerOverviewError","indexDetails","indexDetailsIndices","indexDetailsClosedIndices","closedIndices","pageHeader","title","INDEX_MODEL","LIST","INDEX_SETS","CONFIGURATION","id","_renderElasticsearchUnavailableInformation","deflectorInfo","deflector","style","marginTop","_totalIndexCount","counts","events","current_target","health","indexer_cluster","PropTypes","shape","string","isRequired","object","connect","withParams","indexSets","IndexerClusterStore","IndexerClusterHealth","createReactClass","displayName","mixins","Reflux","componentDidMount","update","render","CONFIGURING_ES","ESClusterStatus","styled","Alert","IndexerClusterHealthSummary","status","toLowerCase","_formatHealthStatus","_alertClassForHealth","_iconNameForHealth","_formatTextForHealth","shards","active","initializing","relocating","unassigned","CLUSTER_STATUS_EXPLAINED","IndexerFailure","failure","timestamp","dateTime","relative","index","letter_id","message","IndexerFailuresList","failures","striped","hover","condensed","width","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,KAAK,iBAApC,gDAKF,yBAAKS,UAAU,oBACb,kBAAC,IAAD,CAAOA,UAAU,mBAAmBqH,SAAO,EAACC,OAAK,EAACC,WAAS,GACzD,+BACE,4BACE,wBAAItD,MAAO,CAAEuD,MAAO,MAApB,aACA,qCACA,yCACA,+CAGJ,+BACG5G,KAAKmB,MAAMqF,SAASK,KAAI,SAACb,GAAD,OAAa,kBAAC,EAAD,CAAgBc,IAAG,0BAAqBd,EAAQK,WAAaL,QAASA,e,8BAxBtFxF,IAAMC,Y,8GAAlC8F,E,YACe,CACjBC,SAAU3C,IAAUkD,QAAQlD,IAAUI,QAAQD,aA8BnCuC","file":"6e61897c-63.472622149827c1587209.js","sourcesContent":["/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport React from 'react';\nimport numeral from 'numeral';\nimport moment from 'moment';\n\nimport { LinkContainer } from 'components/graylog/router';\nimport { Alert, Col, Row, Button } from 'components/graylog';\nimport { Icon, Spinner } from 'components/common';\nimport StoreProvider from 'injection/StoreProvider';\nimport DocsHelper from 'util/DocsHelper';\nimport Routes from 'routing/Routes';\nimport { SmallSupportLink, DocumentationLink } from 'components/support';\n\nconst IndexerFailuresStore = StoreProvider.getStore('IndexerFailures');\n\nclass IndexerFailuresComponent extends React.Component {\n  state = {};\n\n  componentDidMount() {\n    const since = moment().subtract(24, 'hours');\n\n    IndexerFailuresStore.count(since).then((response) => {\n      this.setState({ total: response.count });\n    });\n  }\n\n  _formatFailuresSummary = () => {\n    return (\n      \n         {this._formatTextForFailureCount(this.state.total)}\n\n        \n          \n        \n      \n    );\n  };\n\n  _formatTextForFailureCount = (count) => {\n    if (count === 0) {\n      return 'No failed indexing attempts in the last 24 hours.';\n    }\n\n    return There were {numeral(count).format('0,0')} failed indexing attempts in the last 24 hours.;\n  };\n\n  _iconForFailureCount = (count) => {\n    if (count === 0) {\n      return 'check-circle';\n    }\n\n    return 'ambulance';\n  };\n\n  render() {\n    let content;\n\n    if (this.state.total === undefined) {\n      content = ;\n    } else {\n      content = this._formatFailuresSummary();\n    }\n\n    return (\n      \n        \n          

Indexer failures

\n\n \n Every message that was not successfully indexed will be logged as an indexer failure. You can learn more about this feature in the{' '}\n .\n \n\n {content}\n \n
\n );\n }\n}\n\nexport default IndexerFailuresComponent;\n","/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport numeral from 'numeral';\n\nimport HideOnCloud from 'util/conditional/HideOnCloud';\nimport { LinkContainer } from 'components/graylog/router';\nimport { Alert, Row, Col, Panel, Button } from 'components/graylog';\nimport { DocumentTitle, PageHeader, Spinner, Icon } from 'components/common';\nimport { IndicesMaintenanceDropdown, IndicesOverview, IndexSetDetails } from 'components/indices';\nimport { IndexerClusterHealthSummary } from 'components/indexers';\nimport { DocumentationLink } from 'components/support';\nimport DocsHelper from 'util/DocsHelper';\nimport CombinedProvider from 'injection/CombinedProvider';\nimport Routes from 'routing/Routes';\nimport withParams from 'routing/withParams';\nimport connect from 'stores/connect';\nimport type { IndexerOverview } from 'stores/indexers/IndexerOverviewStore';\nimport type { Indices } from 'stores/indices/IndicesStore';\nimport { IndexSet } from 'components/indices/Types';\n\nconst { IndexSetsStore, IndexSetsActions } = CombinedProvider.get('IndexSets');\nconst { IndicesStore, IndicesActions } = CombinedProvider.get('Indices');\nconst { IndexerOverviewStore, IndexerOverviewActions } = CombinedProvider.get('IndexerOverview');\n\nconst REFRESH_INTERVAL = 2000;\n\ntype Props = {\n params: {\n indexSetId?: string,\n },\n indexSet?: IndexSet,\n indexerOverview?: IndexerOverview,\n indexerOverviewError?: string,\n indexDetails: {\n closedIndices?: Indices,\n indices?: Indices,\n },\n};\n\ntype State = {\n timerId?: NodeJS.Timeout,\n};\n\nclass IndexSetPage extends React.Component {\n static propTypes = {\n params: PropTypes.shape({\n indexSetId: PropTypes.string,\n }).isRequired,\n indexSet: PropTypes.object,\n indexerOverview: PropTypes.object,\n indexerOverviewError: PropTypes.object,\n indexDetails: PropTypes.object,\n };\n\n static defaultProps = {\n indexerOverview: undefined,\n indexerOverviewError: undefined,\n indexSet: undefined,\n indexDetails: {\n indices: undefined,\n closedIndices: undefined,\n },\n }\n\n constructor(props) {\n super(props);\n\n this.state = {\n timerId: undefined,\n };\n }\n\n componentDidMount() {\n const { params: { indexSetId } } = this.props;\n IndexSetsActions.get(indexSetId);\n IndicesActions.list(indexSetId);\n\n const timerId = setInterval(() => {\n IndicesActions.multiple();\n IndexerOverviewActions.list(indexSetId);\n }, REFRESH_INTERVAL);\n this.setState({ timerId: timerId });\n }\n\n componentWillUnmount() {\n const { timerId } = this.state;\n\n if (timerId) {\n clearInterval(timerId);\n }\n }\n\n _totalIndexCount = () => {\n const { indexerOverview: { indices } } = this.props;\n\n return indices ? Object.keys(indices).length : null;\n };\n\n _renderElasticsearchUnavailableInformation = () => {\n return (\n \n \n
\n Indices overview unavailable}>\n

\n We could not get the indices overview information. This usually means there was a problem\n connecting to Elasticsearch, and\n you should ensure Elasticsearch is up and reachable from\n Graylog\n .\n

\n

\n Graylog will continue storing your messages in its journal, but you will not be able to search on them\n until Elasticsearch is reachable again.\n

\n
\n
\n \n
\n );\n };\n\n _isLoading = () => {\n const { indexSet } = this.props;\n\n return !indexSet;\n };\n\n render() {\n if (this._isLoading()) {\n return ;\n }\n\n const { indexSet, indexerOverview, indexerOverviewError, params: { indexSetId }, indexDetails: { indices: indexDetailsIndices, closedIndices: indexDetailsClosedIndices } } = this.props;\n\n const pageHeader = indexSet && (\n \n \n This is an overview of all indices (message stores) in this index set Graylog is currently taking in account\n for searches and analysis.\n \n\n \n You can learn more about the index model in the{' '}\n \n \n\n \n \n \n \n  \n \n \n \n  \n \n \n \n );\n\n if (indexerOverviewError) {\n return (\n \n {pageHeader}\n {this._renderElasticsearchUnavailableInformation()}\n \n );\n }\n\n let indicesInfo;\n let indicesOverview;\n\n if (indexerOverview && indexDetailsClosedIndices) {\n const deflectorInfo = indexerOverview.deflector;\n\n indicesInfo = (\n \n \n  {this._totalIndexCount()} indices with a total of{' '}\n {numeral(indexerOverview.counts.events).format('0,0')} messages under management,\n current write-active index is {deflectorInfo.current_target}.\n \n \n \n \n \n );\n\n indicesOverview = (\n \n );\n } else {\n indicesInfo = ;\n indicesOverview = ;\n }\n\n return (\n \n
\n {pageHeader}\n\n \n \n \n \n \n\n \n \n {indicesInfo}\n \n \n\n {indicesOverview}\n
\n
\n );\n }\n}\n\nexport default connect(\n withParams(IndexSetPage),\n {\n indexSets: IndexSetsStore,\n indexerOverview: IndexerOverviewStore,\n indices: IndicesStore,\n },\n ({ indexSets, indexerOverview, indices }) => ({\n // @ts-ignore\n indexSet: indexSets ? indexSets.indexSet : undefined,\n // @ts-ignore\n indexerOverview: indexerOverview && indexerOverview.indexerOverview,\n // @ts-ignore\n indexerOverviewError: indexerOverview && indexerOverview.indexerOverviewError,\n indexDetails: indices,\n }),\n);\n","/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport React from 'react';\nimport createReactClass from 'create-react-class';\nimport Reflux from 'reflux';\n\nimport { Row, Col } from 'components/graylog';\nimport StoreProvider from 'injection/StoreProvider';\nimport { Spinner } from 'components/common';\nimport { DocumentationLink, SmallSupportLink } from 'components/support';\nimport DocsHelper from 'util/DocsHelper';\nimport { IndexerClusterHealthSummary } from 'components/indexers';\n\nconst IndexerClusterStore = StoreProvider.getStore('IndexerCluster');\n\nconst IndexerClusterHealth = createReactClass({\n displayName: 'IndexerClusterHealth',\n mixins: [Reflux.connect(IndexerClusterStore)],\n\n componentDidMount() {\n IndexerClusterStore.update();\n },\n\n render() {\n const { health } = this.state;\n\n let content;\n\n if (health) {\n content = ;\n } else {\n content = ;\n }\n\n return (\n \n \n

Elasticsearch cluster

\n\n \n The possible Elasticsearch cluster states and more related information is available in the{' '}\n .\n \n\n {content}\n \n
\n );\n },\n});\n\nexport default IndexerClusterHealth;\n","/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport styled from 'styled-components';\n\nimport { Alert } from 'components/graylog';\nimport { Icon } from 'components/common';\nimport { DocumentationLink } from 'components/support';\nimport DocsHelper from 'util/DocsHelper';\n\nconst ESClusterStatus = styled(Alert)`\n margin-top: 10px;\n margin-bottom: 5px;\n`;\n\nclass IndexerClusterHealthSummary extends React.Component {\n static propTypes = {\n health: PropTypes.object.isRequired,\n };\n\n _formatHealthStatus = ({ status }) => {\n return status.toLowerCase();\n };\n\n _alertClassForHealth = (health) => {\n switch (this._formatHealthStatus(health)) {\n case 'green': return 'success';\n case 'yellow': return 'warning';\n case 'red': return 'danger';\n default: return 'success';\n }\n };\n\n _formatTextForHealth = (health) => {\n const text = `Elasticsearch cluster is ${this._formatHealthStatus(health)}.`;\n\n switch (this._formatHealthStatus(health)) {\n case 'green': return text;\n case 'yellow':\n case 'red': return {text};\n default: return text;\n }\n };\n\n _iconNameForHealth = (health) => {\n switch (this._formatHealthStatus(health)) {\n case 'green': return 'check-circle';\n case 'yellow': return 'exclamation-triangle';\n case 'red': return 'ambulance';\n default: return 'check-circle';\n }\n };\n\n render() {\n const { health } = this.props;\n\n return (\n \n  {this._formatTextForHealth(health)}{' '}\n Shards:{' '}\n {health.shards.active} active,{' '}\n {health.shards.initializing} initializing,{' '}\n {health.shards.relocating} relocating,{' '}\n {health.shards.unassigned} unassigned,{' '}\n \n \n );\n }\n}\n\nexport default IndexerClusterHealthSummary;\n","/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport PropTypes from 'prop-types';\nimport React from 'react';\n\nimport { Timestamp } from 'components/common';\n\nclass IndexerFailure extends React.Component {\n static propTypes = {\n failure: PropTypes.object.isRequired,\n };\n\n render() {\n const { failure } = this.props;\n\n return (\n \n \n {failure.index}\n {failure.letter_id}\n {failure.message}\n \n );\n }\n}\n\nexport default IndexerFailure;\n","/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport PropTypes from 'prop-types';\nimport React from 'react';\n\nimport { Alert, Table } from 'components/graylog';\nimport { Icon } from 'components/common';\nimport { IndexerFailure } from 'components/indexers';\n\nclass IndexerFailuresList extends React.Component {\n static propTypes = {\n failures: PropTypes.arrayOf(PropTypes.object).isRequired,\n };\n\n render() {\n if (this.props.failures.length === 0) {\n return (\n Hurray! There are not any indexer failures.\n );\n }\n\n return (\n
\n \n \n \n \n \n \n \n \n \n \n {this.props.failures.map((failure) => )}\n \n
TimestampIndexLetter IDError message
\n
\n );\n }\n}\n\nexport default IndexerFailuresList;\n"],"sourceRoot":""}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy