Site icon Bugra Parlayan | Oracle Database & Exadata Blog

Jira Service Management and OEM 24AI Test Fail

Oracle Enterprise Manager 24AI and Jira integration is explained clearly in the Oracle documents. If you see an authentication error during the integration, it is most likely related to the way you are doing the authentication.

The documentation is for Jira Cloud version, so it uses the method Authorization: Basic. As you can see in the document, the base64 encoding is done with email + token. But if you are not using Jira Cloud (for example, the Data Center version), the authentication should be done with Authorization: Bearer.

Another point is that if you have not made a different configuration in Jira, you need to log in with your username, not your email address. This is because, by default, Jira uses the local user database.

Sample error;


ExecuteThread: ’22’ for queue: ‘weblogic.kernel.Default (self-tuning)’] ERROR framework.Method logp.269 – REST call returned an unsuccessful status: 401


ExecuteThread: ’22’ for queue: ‘weblogic.kernel.Default (self-tuning)’] ERROR framework.Method logp.269 – REST call returned an unsuccessful status: 403

Below you can see an example of creating a ticket with Curl using Authorization: Bearer. If you update the parameters according to your own configuration, you will see that a sample ticket is created in Jira.

curl -X POST \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer your_token" \
  -d '{
        "fields": {
          "project": { "key": "BGR" },
          "issuetype": { "name": "Task" },
          "summary": "Test Ticket from OEM",
          "priority": { "name": "Minor" },
          "components": [{ "name": "Jira" }],
          "assignee": { "name": "your_token_username" }
        }
      }' \
  https://jira.bugraparlayan.com.tr/rest/api/2/issue

After this, if you change the lines in the Jira templates from Authorization: Basic to Authorization: Bearer, you can easily integrate with Jira.

However, this is still not enough to create tickets automatically. You also need to change other lines in the template according to your Jira setup. These lines are explained inside the template.

If you still have a problem, you can send me an email.

Ref:

https://docs.oracle.com/en/enterprise-manager/cloud-control/enterprise-manager-cloud-control/24.1/jirac/installing-and-configuring-jira-connector.html#GUID-7C078A53-99FA-4303-B48B-F9EF0F0D6032

Exit mobile version