Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SIEM] [Case] Case workflow api schema #51535

Merged
merged 44 commits into from Jan 8, 2020

Conversation

@stephmilovic
Copy link
Contributor

stephmilovic commented Nov 22, 2019

Summary

To test locally, add the following line to your kibana.dev.yml:

xpack.case.enabled: true

This PR establishes the initial Case Workflow API, including case and comment schema. Please reference this Postman generated documentation of the API.

Case & Comment mappings are in this temp file, see note below: x-pack/legacy/plugins/siem/server/lib/case/saved_object_mappings_temp.ts

Big Time Note

I needed to use the legacy API in order to to write mappings for case as the Saved Object Mappings API is not yet available on the NP. See: #50309
Therefore, I had to create some temporary files in the siem dir. I plan to commit this to master as I may need to change mappings. Eventually, this will get moved to the new platform.

Checklist

For maintainers

stephmilovic added 13 commits Nov 15, 2019
@elasticmachine

This comment has been minimized.

Copy link
Contributor

elasticmachine commented Nov 22, 2019

Pinging @elastic/siem (Team:SIEM)

@stephmilovic stephmilovic changed the title [SIEM] [Case] Case workflow api schema [skip-ci] [SIEM] [Case] Case workflow api schema Nov 22, 2019
@elasticmachine

This comment has been minimized.

Copy link
Contributor

elasticmachine commented Nov 23, 2019

stephmilovic added 2 commits Jan 6, 2020
…tephmilovic/kibana into case-workflow-api-schema
@stephmilovic

This comment has been minimized.

Copy link
Contributor Author

stephmilovic commented Jan 6, 2020

retest

1 similar comment
@stephmilovic

This comment has been minimized.

Copy link
Contributor Author

stephmilovic commented Jan 6, 2020

retest

@tylersmalley

This comment has been minimized.

Copy link
Member

tylersmalley commented Jan 7, 2020

@elasticmachine merge upstream

@stephmilovic

This comment has been minimized.

Copy link
Contributor Author

stephmilovic commented Jan 8, 2020

@elasticmachine merge upstream

.eslintrc.js Outdated Show resolved Hide resolved
stephmilovic added 2 commits Jan 8, 2020
…tephmilovic/kibana into case-workflow-api-schema
// TODO: Remove once while Saved Object Mappings API is programmed for the NP See: https://github.com/elastic/kibana/issues/50309
savedObjectSchemas: {
'case-workflow': {
indexPattern: '.case-testing-ground', // TODO: Change this name and use kibana.yml settings to override it.

This comment has been minimized.

Copy link
@tylersmalley

tylersmalley Jan 8, 2020

Member

What's the reason for having this stored in a separate index? If we can avoid it, we should as a failed migration requires each of these indices to to removed currently and won't be resolved until 8.0.

This comment has been minimized.

Copy link
@stephmilovic

stephmilovic Jan 8, 2020

Author Contributor

i will need it in a separate index, but apparently there is a way to get access to the kibana.yml from this part of the code which I had not believed to be possible. I need to track down an example, brb!

This comment has been minimized.

Copy link
@stephmilovic

stephmilovic Jan 8, 2020

Author Contributor

I removed these lines for now since they will need to be done from the NP side ultimately. could have to do with these failures, we'll see

@tylersmalley

This comment has been minimized.

Copy link
Member

tylersmalley commented Jan 8, 2020

Something is blocking the Kibana server from starting for me, which is probably the cause of the CI failures. If I disable the plugin --xpack.siem.enabled=false all is well again.

Are you able to reproduce this if you remove the configuration from your kibana.dev.yml?

@stephmilovic

This comment has been minimized.

Copy link
Contributor Author

stephmilovic commented Jan 8, 2020

Something is blocking the Kibana server from starting for me, which is probably the cause of the CI failures. If I disable the plugin --xpack.siem.enabled=false all is well again.

Are you able to reproduce this if you remove the configuration from your kibana.dev.yml?

I think this all has to do with creating NP case saved objects from legacy siem. That was a temporary work around anyways. I removed that code, have the kibana server running locally without issues, let's see if we can get a green build

@kibanamachine

This comment has been minimized.

Copy link

kibanamachine commented Jan 8, 2020

💚 Build Succeeded

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@stephmilovic stephmilovic merged commit 303e484 into elastic:master Jan 8, 2020
55 checks passed
55 checks passed
API integration tests node scripts/functional_tests --config test/api_integration/config.js --bail --debug
Details
Browser tests yarn run grunt test:browser-ci
Details
Build kbn_tp_sample_panel_action yarn build
Details
CLA All commits in pull request signed
Details
Check core API changes node scripts/check_core_api_changes
Details
Check file casing node scripts/check_file_casing --quiet
Details
Check licenses node scripts/check_licenses --dev
Details
Example functional tests node scripts/functional_tests --config test/examples/config.js --bail --debug
Details
Firefox smoke test node scripts/functional_tests --bail --debug --kibana-install-dir /dev/shm/workspace/kibana/build/oss/kibana-8.0.0-SNAPSHOT-linux-x86_64 --include-tag smoke --config test/functional/config.firefox.js
Details
Functional tests / Group 1 yarn run grunt run:functionalTests_ciGroup1
Details
Functional tests / Group 10 yarn run grunt run:functionalTests_ciGroup10
Details
Functional tests / Group 11 yarn run grunt run:functionalTests_ciGroup11
Details
Functional tests / Group 12 yarn run grunt run:functionalTests_ciGroup12
Details
Functional tests / Group 2 yarn run grunt run:functionalTests_ciGroup2
Details
Functional tests / Group 3 yarn run grunt run:functionalTests_ciGroup3
Details
Functional tests / Group 4 yarn run grunt run:functionalTests_ciGroup4
Details
Functional tests / Group 5 yarn run grunt run:functionalTests_ciGroup5
Details
Functional tests / Group 6 yarn run grunt run:functionalTests_ciGroup6
Details
Functional tests / Group 7 yarn run grunt run:functionalTests_ciGroup7
Details
Functional tests / Group 8 yarn run grunt run:functionalTests_ciGroup8
Details
Functional tests / Group 9 yarn run grunt run:functionalTests_ciGroup9
Details
Internationalization check node scripts/i18n_check --ignore-missing
Details
Interpreter functional tests node scripts/functional_tests --config test/interpreter_functional/config.ts --bail --debug --kibana-install-dir /dev/shm/workspace/kibana/build/oss/kibana-8.0.0-SNAPSHOT-linux-x86_64-2
Details
Jest integration tests yarn run grunt test:jest_integration
Details
Jest tests yarn run grunt test:jest
Details
Kibana accessibility tests node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/kibana/build/oss/kibana-8.0.0-SNAPSHOT-linux-x86_64 --config test/accessibility/config.ts
Details
Mocha tests node scripts/mocha
Details
Plugin functional tests node scripts/functional_tests --config test/plugin_functional/config.js --bail --debug
Details
Project tests yarn run grunt test:projects
Details
Type check node scripts/type_check
Details
TypeScript - all files belong to a TypeScript project node scripts/check_ts_projects
Details
Verify NOTICE.txt node scripts/notice --validate
Details
Verify dependency versions yarn run grunt verifyDependencyVersions
Details
X-Pack Chrome Functional tests / Group 1 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-2 --include-tag ciGroup1
Details
X-Pack Chrome Functional tests / Group 10 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-11 --include-tag ciGroup10
Details
X-Pack Chrome Functional tests / Group 2 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-3 --include-tag ciGroup2
Details
X-Pack Chrome Functional tests / Group 3 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-4 --include-tag ciGroup3
Details
X-Pack Chrome Functional tests / Group 4 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-5 --include-tag ciGroup4
Details
X-Pack Chrome Functional tests / Group 5 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-6 --include-tag ciGroup5
Details
X-Pack Chrome Functional tests / Group 6 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-7 --include-tag ciGroup6
Details
X-Pack Chrome Functional tests / Group 7 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-8 --include-tag ciGroup7
Details
X-Pack Chrome Functional tests / Group 8 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-9 --include-tag ciGroup8
Details
X-Pack Chrome Functional tests / Group 9 node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-10 --include-tag ciGroup9
Details
X-Pack Jest node scripts/jest --ci --verbose
Details
X-Pack Karma Tests yarn test:browser
Details
X-Pack SIEM cyclic dependency test node legacy/plugins/siem/scripts/check_circular_deps
Details
X-Pack accessibility tests node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana --config test/accessibility/config.ts
Details
X-Pack firefox smoke test node scripts/functional_tests --debug --bail --kibana-install-dir /dev/shm/workspace/install/kibana-1 --include-tag smoke --config test/functional/config.firefox.js
Details
elasticsearch-ci/docs Build finished.
Details
eslint node scripts/eslint --no-cache
Details
kibana-ci Build finished.
Details
prbot:outdated
prbot:release note labels
prbot:release version labels
sasslint node scripts/sasslint
Details
@stephmilovic stephmilovic deleted the stephmilovic:case-workflow-api-schema branch Jan 8, 2020
stephmilovic added a commit to stephmilovic/kibana that referenced this pull request Jan 8, 2020
gmmorris added a commit to gmmorris/kibana that referenced this pull request Jan 9, 2020
* master: (23 commits)
  [Vis: Default editor] Reactify the timelion editor (elastic#52990)
  [Discover] fix histogram min interval (elastic#53979)
  [Telemetry] [Monitoring] Only retry fetching usage once monito… (elastic#54309)
  [docs][APM] Add runtime index config documentation (elastic#53907)
  [SIEM] Detection engine timeline (elastic#53783)
  Filter scripted fields preview field list to source fields (elastic#53826)
  Management - New platform api (elastic#52579)
  Reset region and Account when switching inventory (elastic#54287)
  [SIEM] [Case] Case workflow api schema (elastic#51535)
  Code coverage setup on CI (elastic#49003)
  [ML] DF Analytics Results: adds link to docs (elastic#54189)
  Update schemas boolean, byteSize, and duration to coerce strings (elastic#54177)
  [Metrics UI] Pass relevant shouldAllowEdit capabilities into SettingsPage (elastic#49781)
  [Canvas] Fixes bugs with autoplay and refresh (elastic#53149)
  [ML] DF Analytics Classification: ensure confusion matrix can be fetched (elastic#53629)
  Fix Vega react eslint errors (elastic#54259)
  Remove non existing codeowners (elastic#54274)
  use correct type (elastic#54244)
  [Dashboard] Removing 100% as dshDashboardViewport height (elastic#54263)
  add `examples/` to no-restricted-path config (elastic#54252)
  ...
stephmilovic added a commit that referenced this pull request Jan 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.