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

[ResponseOps][Connectors] Support of Jira Data center #189017

Closed
n0othing opened this issue Jul 23, 2024 · 19 comments
Closed

[ResponseOps][Connectors] Support of Jira Data center #189017

n0othing opened this issue Jul 23, 2024 · 19 comments
Assignees
Labels
enhancement New value added to drive a business result Feature:Actions/ConnectorTypes Issues related to specific Connector Types on the Actions Framework Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams)

Comments

@n0othing
Copy link
Member

n0othing commented Jul 23, 2024

Describe the feature:

Today the Jira Connector only supports cloud/SaaS [1]. It'd be helpful if we supported on-prem installs of Jira Data Center.

[1] #154435

@n0othing n0othing added enhancement New value added to drive a business result Feature:Actions/ConnectorTypes Issues related to specific Connector Types on the Actions Framework labels Jul 23, 2024
@botelastic botelastic bot added the needs-team Issues missing a team label label Jul 23, 2024
@dmlemeshko dmlemeshko added the Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams) label Jul 29, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/response-ops (Team:ResponseOps)

@botelastic botelastic bot removed the needs-team Issues missing a team label label Jul 29, 2024
@cnasikas
Copy link
Member

Hey! Jira ended the support of self-managed server offerings on February 15, 2024. You can read more about it here https://www.atlassian.com/blog/announcements/journey-to-cloud. We do not plan to add support to a product that Jira does not support.

@n0othing
Copy link
Member Author

n0othing commented Jul 30, 2024

@cnasikas This was for Jira Data Center with 9.12.7 (based on that blog post, I believe Data Center is Atlassian's self-managed enterprise version of Jira, which they'll continue to support?)

@cnasikas
Copy link
Member

Thanks for the update @n0othing. I see, yes this is something we could consider support. Could you please update the issues to reflect the Jira Data Center to avoid any confusion in the future? Out of curiosity, did they try to use the existing connector with their deployment of Jira? If yes, did they encounter any issues? cc @shanisagiv1 @heespi

@cnasikas cnasikas changed the title [Jira Connector] Support on-prem installs of Jira [ResponseOps][Connectors] Support of Jira Data center Jul 31, 2024
@n0othing
Copy link
Member Author

@cnasikas They did, they hit a 503 response when the connector made a "get capabilities" API call:

"tags":[".jira","cc84d31b-e005-428e-a332-80d695c00278","action-run-failed"],"error":{"stack_trace":"Error: [Action][Jira]: Unable to get capabilities. Error: Request failed with status code 503. Reason: unknown: errorResponse.errors was null\n at getCapabilities (/usr/share/kibana/node_modules/@kbn/stack-connectors-plugin/server/connector_types/jira/service.js:326:13)\n at processTicksAndRejections (node:internal/process/task_queues:95:5)\n at Object.getIssueTypes (/usr/share/kibana/node_modules/@kbn/stack-connectors-plugin/server/connector_types/jira/service.js:330:34)\n at Object.getIssueTypesHandler [as issueTypes].... 

@heespi
Copy link

heespi commented Aug 7, 2024

We'll be looking into the prioritization of this ask this week @n0othing

@shanisagiv1
Copy link

Hi, we're considering adding it to one of the next minors. The need is clear. but not high-priority for the team (given other active initiatives). Did you try to use Webhook to walkaround the lack of native integration ? thanks @n0othing

@anuj-elastic
Copy link

anuj-elastic commented Sep 24, 2024

Hi @shanisagiv1 We have a same requirement from another customer (https://github.com/elastic/enhancements/issues/22007). This feature is critically important for them. Last year, they implemented a workaround by using Splunk to create Jira tickets based on Elasticsearch alerts. They were able to do this because they had a small Splunk license available, but that license is set to expire soon, so now they have reached to the state where they need this feature urgently.

@chintanjs
Copy link

@shanisagiv1 - Adding to @anuj-elastic comment that this has been situation where our existing customer has been struggling as well. We are not sure if any workaround has worked here but urge you prioritise this release request and also suggest timelines if any.

@heespi
Copy link

heespi commented Sep 30, 2024

We are tentatively considering this for the 8.18 timeframe.

@jcger
Copy link
Contributor

jcger commented Oct 24, 2024

Hi @n0othing @anuj-elastic @chintanjs, we have deployed a Jira Data Center instance in our cloud infra and tested the connector. It did work, also the capabilities API returned data. This might indicate that there is a non-elastic/kibana related issue or that it's not happening anymore.

@chintanjs
Copy link

Thanks for the update @jcger

@anuj-elastic
Copy link

Hey @jcger Thanks for the update. Can you please confirm which Elasticsearch, Jira and Connector version you tested with?

@jcger
Copy link
Contributor

jcger commented Oct 24, 2024

@chintanjs @anuj-elastic I might have sent that previous message too soon. We've seen that 503 might mean that we are hitting a rate limit. We are trying to figure out how to approach this. Sorry for the inconvenience. I'll come back to you ASAP

@anuj-elastic
Copy link

Hi @jcger Sure, no worries. Please check and let us know.

Actually we shared the update with the customer, and they quickly tested it on Elasticsearch version 8.14.2. However, they encountered the following error.

[Action][Jira]: Unable to get capabilities. Error: unable to get local issuer certificate. Reason: unknown: errorResponse was null

URL they entered while configuring was https://qualys-internal-jira.qualys.com/

If you have any document or details you can share what details you entered, it would be helpful for them.Image

@cnasikas
Copy link
Member

@anuj-elastic This does not seem to be related to the Jira connector. I assume they use a self-signed certificate on their Jira data center and probably why they are getting this error. Could you please verify that they have configured correctly the xpack.actions.customHostSettings for their self-signed certificates and hosts?

@anuj-elastic
Copy link

Hi @cnasikas @jcger Thank you for your support. The customer can now successfully create tickets in Jira from the Kibana UI using the Jira connector. They are currently running tests based on their use cases and will reach out if they encounter any issues; I’ll inform you if any assistance from Dev/Eng is needed.

At this time, when they create a case in Kibana and add comments, those sync to Jira. However, comments updated in Jira do not sync back to the Kibana UI. If two-way communication were possible, they could fully manage Jira ticket activities from within Kibana. I searched for documentation on this feature but couldn't locate relevant information—could you confirm if this functionality is supported and provide any available documentation?

@cnasikas
Copy link
Member

Hey, @anuj-elastic! I'm glad to hear that it's working as expected. We don't support two-way communication, but we plan to. No concrete timelines at the moment. Here is a public issue to track #188098.

@cnasikas
Copy link
Member

cnasikas commented Nov 1, 2024

I am closing the issue as Jira Data Center is already supported by the current connector. This PR (#197787) is going to make some improvements to reduce the change of the 503 rate limit errors noticed in this issue.

@cnasikas cnasikas closed this as completed Nov 1, 2024
adcoelho added a commit that referenced this issue Nov 7, 2024
…only (#197787)

## Summary

Jira Cloud and Datacenter work using the same API urls. In this PR we
remove the calls to the capabilities API which was being used to know
the API url we needed to hit

To test it:
- Create Jira Cloud and Datacenter connectors
- Test all use cases related to them

Related to #189017

## Research Work

**getCapabilities, createIncident and getIncident** are always the same,
therefore ignored for the rest of this document

- getCapabilities: `/rest/capabilities`
- createIncident: `/rest/api/2/issue`
- getIncident: `/rest/api/2/issue`

## API links

- Cloud:
https://developer.atlassian.com/cloud/jira/platform/rest/v2/intro/#version
- DC: https://docs.atlassian.com/software/jira/docs/api/REST/9.17.0/

### Expected API urls based on the API links

- Get issue types

- Cloud: `GET /rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes`
  - DC:`GET /rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes`

- Get fields by issue type
- Cloud: `GET
/rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes/{issueTypeId}`
- DC:
`GET /rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes/{issueTypeId}`

### API we hit

- Get issue types

- Cloud `GET
/rest/api/2/issue/createmeta?projectKeys=ROC&expand=projects.issuetypes.fields`
(variable name we are using is `getIssueTypesOldAPIURL`)
- DC `GET /rest/api/2/issue/createmeta/RES/issuetypes` (variable name is
`getIssueTypesUrl`)

- Get fields by issue type
- Cloud `GET
/rest/api/2/issue/createmeta?projectKeys=ROC&issuetypeIds={issueTypeId}&expand=projects.issuetypes.fields`
(variable name is `getIssueTypeFieldsOldAPIURL`)
- DC `GET /rest/api/2/issue/createmeta/RES/issuetypes/{issueTypeId}`
(variable name is `getIssueTypeFieldsUrl`)

#### Analysed use cases to retrieve API urls we hit

- created a case with JIRA Cloud as Connector
- did a connector test with JIRA Cloud as connector
- created a case with JIRA DC as connector
- did a connector test with JIRA DC as connector

### Conclusions

- We are not using the right endpoints for Cloud, we should update them
to use the same endpoints.

---------

Co-authored-by: Elastic Machine <[email protected]>
Co-authored-by: Christos Nasikas <[email protected]>
Co-authored-by: adcoelho <[email protected]>
Co-authored-by: Antonio <[email protected]>
Co-authored-by: Lisa Cawley <[email protected]>
kibanamachine pushed a commit to kibanamachine/kibana that referenced this issue Nov 7, 2024
…only (elastic#197787)

## Summary

Jira Cloud and Datacenter work using the same API urls. In this PR we
remove the calls to the capabilities API which was being used to know
the API url we needed to hit

To test it:
- Create Jira Cloud and Datacenter connectors
- Test all use cases related to them

Related to elastic#189017

## Research Work

**getCapabilities, createIncident and getIncident** are always the same,
therefore ignored for the rest of this document

- getCapabilities: `/rest/capabilities`
- createIncident: `/rest/api/2/issue`
- getIncident: `/rest/api/2/issue`

## API links

- Cloud:
https://developer.atlassian.com/cloud/jira/platform/rest/v2/intro/#version
- DC: https://docs.atlassian.com/software/jira/docs/api/REST/9.17.0/

### Expected API urls based on the API links

- Get issue types

- Cloud: `GET /rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes`
  - DC:`GET /rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes`

- Get fields by issue type
- Cloud: `GET
/rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes/{issueTypeId}`
- DC:
`GET /rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes/{issueTypeId}`

### API we hit

- Get issue types

- Cloud `GET
/rest/api/2/issue/createmeta?projectKeys=ROC&expand=projects.issuetypes.fields`
(variable name we are using is `getIssueTypesOldAPIURL`)
- DC `GET /rest/api/2/issue/createmeta/RES/issuetypes` (variable name is
`getIssueTypesUrl`)

- Get fields by issue type
- Cloud `GET
/rest/api/2/issue/createmeta?projectKeys=ROC&issuetypeIds={issueTypeId}&expand=projects.issuetypes.fields`
(variable name is `getIssueTypeFieldsOldAPIURL`)
- DC `GET /rest/api/2/issue/createmeta/RES/issuetypes/{issueTypeId}`
(variable name is `getIssueTypeFieldsUrl`)

#### Analysed use cases to retrieve API urls we hit

- created a case with JIRA Cloud as Connector
- did a connector test with JIRA Cloud as connector
- created a case with JIRA DC as connector
- did a connector test with JIRA DC as connector

### Conclusions

- We are not using the right endpoints for Cloud, we should update them
to use the same endpoints.

---------

Co-authored-by: Elastic Machine <[email protected]>
Co-authored-by: Christos Nasikas <[email protected]>
Co-authored-by: adcoelho <[email protected]>
Co-authored-by: Antonio <[email protected]>
Co-authored-by: Lisa Cawley <[email protected]>
(cherry picked from commit 953d877)
mbondyra pushed a commit to mbondyra/kibana that referenced this issue Nov 8, 2024
…only (elastic#197787)

## Summary

Jira Cloud and Datacenter work using the same API urls. In this PR we
remove the calls to the capabilities API which was being used to know
the API url we needed to hit

To test it:
- Create Jira Cloud and Datacenter connectors
- Test all use cases related to them

Related to elastic#189017

## Research Work

**getCapabilities, createIncident and getIncident** are always the same,
therefore ignored for the rest of this document

- getCapabilities: `/rest/capabilities`
- createIncident: `/rest/api/2/issue`
- getIncident: `/rest/api/2/issue`

## API links

- Cloud:
https://developer.atlassian.com/cloud/jira/platform/rest/v2/intro/#version
- DC: https://docs.atlassian.com/software/jira/docs/api/REST/9.17.0/

### Expected API urls based on the API links

- Get issue types

- Cloud: `GET /rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes`
  - DC:`GET /rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes`

- Get fields by issue type
- Cloud: `GET
/rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes/{issueTypeId}`
- DC:
`GET /rest/api/2/issue/createmeta/{projectIdOrKey}/issuetypes/{issueTypeId}`

### API we hit

- Get issue types

- Cloud `GET
/rest/api/2/issue/createmeta?projectKeys=ROC&expand=projects.issuetypes.fields`
(variable name we are using is `getIssueTypesOldAPIURL`)
- DC `GET /rest/api/2/issue/createmeta/RES/issuetypes` (variable name is
`getIssueTypesUrl`)

- Get fields by issue type
- Cloud `GET
/rest/api/2/issue/createmeta?projectKeys=ROC&issuetypeIds={issueTypeId}&expand=projects.issuetypes.fields`
(variable name is `getIssueTypeFieldsOldAPIURL`)
- DC `GET /rest/api/2/issue/createmeta/RES/issuetypes/{issueTypeId}`
(variable name is `getIssueTypeFieldsUrl`)

#### Analysed use cases to retrieve API urls we hit

- created a case with JIRA Cloud as Connector
- did a connector test with JIRA Cloud as connector
- created a case with JIRA DC as connector
- did a connector test with JIRA DC as connector

### Conclusions

- We are not using the right endpoints for Cloud, we should update them
to use the same endpoints.

---------

Co-authored-by: Elastic Machine <[email protected]>
Co-authored-by: Christos Nasikas <[email protected]>
Co-authored-by: adcoelho <[email protected]>
Co-authored-by: Antonio <[email protected]>
Co-authored-by: Lisa Cawley <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New value added to drive a business result Feature:Actions/ConnectorTypes Issues related to specific Connector Types on the Actions Framework Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams)
Projects
None yet
Development

No branches or pull requests

9 participants