youngmon/atlassian-qna huggingface dataset:
Azure severity not mapping to Opsgenie priority
Asked by Emil Varona:

I'm working on alerting from Azure to Opsgenie. The severity options on the Azure side map from 0-4 while the Opsgenie priority maps from P1-P5. I tried setting "Priority" in the integration to "Custom value to Opsgenie priority" and then setting the mapped priority value to {{severity}} doesn't seem to work. All alerts come into Opsgenie as P3. I can confirm also that my Azure action group is set to disable the common alert schema, as mentioned in a another post.

Does anyone have a suggestion for how to properly map these to disparate values?


Answers:
author: Wei Wung
body: Hi [@Emil Varona](/t5/user/viewprofilepage/user-id/5008522),

How are you doing? Thank you for reaching out!

Please take a look at the following articles on how you can extract the severity value:

<https://community.atlassian.com/t5/Opsgenie-questions/OpsGenie-AWS-Cloudwatch-Alarms-Map-priority/qaq-p/1440305>

<https://community.atlassian.com/t5/Opsgenie-articles/How-to-Map-Alert-Priorities-in-Opsgenie/ba-p/2044304>

<https://community.atlassian.com/t5/Opsgenie-questions/How-to-parse-the-subject-and-the-properties-from-aws-cloudwatch/qaq-p/2097135>

To determine which field the incoming alert's severity value is parsed into (or if it is just in the incoming payload), you would want to search the Debug Logs (under Settings) using the value of the incomingDataId from the bottom of the alert's Activity Logs tab found in the "Alert created via ..." log entry.

Like in this [community post](https://community.atlassian.com/t5/Opsgenie-questions/How-to-parse-the-subject-and-the-properties-from-aws-cloudwatch/qaq-p/2097135), you would want to look at the "Processed incomingData" log entry to determine how the payload is parsed and to which field the severity value is captured into, if it is.

Then use one of the applicable methods mentioned in this [community post](https://community.atlassian.com/t5/Opsgenie-articles/How-to-Map-Alert-Priorities-in-Opsgenie/ba-p/2044304) to extract this value.

The next step would be how you would map 0 to P1, 1 to P2, 2 to P3, etc. We currently do not have a match-replace function in our implementation of regex, so you would need to use an Alert Policy to do that. Alert Policies are available in Opsgenie's Standard plan or in JSM Premium plan and higher.

Hope the above helps or please feel free to open up an in-app chat (where available) or a ticket at support.atlassian.com so we can help take a look more closely.

comments: author: Emil Varona
body: Thanks for your response. I can report that the second [community post](https://community.atlassian.com/t5/Opsgenie-articles/How-to-Map-Alert-Priorities-in-Opsgenie/ba-p/2044304) did the trick. I appreciate your assistance.

In short, I created an IF-THEN-ELSE scenario within the integration that mapped the severity to the related priority as described in the aforementioned post.


Tags: azure

cloud

priority
How to extract spesific chareters in below string?
Asked by Jugal_Shroff:

**I want to extract charecter from below string and use in Tag**

**tun-charectertoextract-xxx-"Charetertoextact"-xxx-xxx**


Answers:
author: Wei Wung
body: Hi [@Jugal_Shroff](/t5/user/viewprofilepage/user-id/5002746),

Using the examples in our [Regex doc](https://support.atlassian.com/opsgenie/docs/regular-expressions-for-improved-alert-filtering/), you can try the following for tag1 and tag2:

```
For Tag1: {{message.extract(/tun-(\S+)\-.*\-\"(\S+)\"-.*/, 1)}}
For Tag2: {{message.extract(/tun-(\S+)\-.*\-\"(\S+)\"-.*/, 2)}}
```

In the example text you gave, I am assuming the word "tun-" and the dashes following are "static".

The other option to try would be:

```
For Tag1: {{message.extract(/tun-(\S+)\-.*\-\"\S+\"-.*/)}}
For Tag2: {{message.extract(/tun-\S+\-.*\-\"(\S+)\"-.*/)}}
```

You can test the 2nd method in regex101.com as well, for example:

![regex101-example.png](https://community.atlassian.com/t5/image/serverpage/image-id/228806i771BC5B8648B255F/image-size/large?v=v2&px=999 "regex101-example.png")

This is how I had tested:  
![AlertwithRegexExample.png](https://community.atlassian.com/t5/image/serverpage/image-id/228807i9DC269B425E9082B/image-size/large?v=v2&px=999 "AlertwithRegexExample.png")

Hope the above point you in the right direction. All the best!

comments: author: Jugal_Shroff
body: Thanks for your help. Its not workking for me.

I want to tag details after tun-++thiswillchange with new alert **(my first tag)**++ **-xxx(not static)-++thiswillchange with new alert (my second tag)-xxx(not static)-xxx(not static)++**

![Example.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/228818i3FC1AE51D3C6F074/image-size/large?v=v2&px=999 "Example.jpg")


author: Jugal_Shroff
body: my second tag contents charector and number combination minimum 2 and maximum 3 charector and number combinations


Tags: cloud
Is there a way to export Opsgenie user lists
Asked by Ste404:

Hi there,

I can see the users page but I would like to export the all users to chuck into Excel to be able to filter against the various status (Active, unverified etc). Need to just show this with some other data and can't see a way to get the information out of Opsgenie.

Also, if someone is Not Verified does that mean they have never access Opsgenie?

ta


Answers:
author: Howard Nedd
body: Hi [@Ste404](/t5/user/viewprofilepage/user-id/4984517) ,

There is no report for that, but the [Get User API](https://docs.opsgenie.com/docs/user-api#get-user)will list the user contact number and method for individual users.

You could use the [List User API](https://docs.opsgenie.com/docs/user-api#list-user) first to get all user IDs (which are needed for the Get User API) and then have the Get User API loop through them to list all users and their contact number/methods. Not sure either if you can get their statuses via API..

I agree that their should be a simpler way to get these exports similar to the export list for Jira, JSM and Confluence.

Regards

Howard

comments: author: Howard Nedd
body: Also if someone is not verified, they have never accessed Opsgenie. To access Opsgenie you need to verify your account first.

Regards

Howard


author: Ste404
body: Thanks [@Howard Nedd](/t5/user/viewprofilepage/user-id/4566707) I'll have a look at the API side of things and see what I can pull down.

Appreciate the reply.


author: Ramachandra Prabhu
body: Hi,   
I found a report from where you can get all the users list from Opsgenie

you can access the **User Management Report** at the **Analytics** tab to get Last login or active / inactive user list   
Thanks

comments: author: goran.kostadinovic
body: Where? There's no link in your answer.


author: Howard Nedd
body: [@goran.kostadinovic](/t5/user/viewprofilepage/user-id/4899144) ,

Go to analytics in Opsgenie and click on User Management report.

Regards

Howard


Tags: cloud
How can we change the PO in Opsgenie invoice in a more efficient way?
Asked by Carina Freitas Lindberg:

Since it is reoccurring every month and we need to create tickets to change the PO, it is time consuming and inefficient. I wish it would be as easy as for the other products Atlassian offers, just update it in My Atlassian.


Answers:
author: Rafael Meira
body: Hey Carina! My name is Rafa from the Technical Support Team!  

I am so sorry for this inconvenience, the need to create tickets every time in order to change the PO.  
I have talked to our billing team and this is a topic handled by our Account Receivable, it would be great if you could create a formal ticket with our support [Support](https://support.atlassian.com/opsgenie/) /contact support - so we could move this issue within our teams o get a workaround or a solution for you.  

You could also send an email to accountsreceivable@atlassian.com, they would be able to connect you with a solution on this matter.  

Hope this helped.  

Best,  
Rafa


Tags: billing

cloud
Any Opsgenie api's to get list of alerts based on the time range
Asked by Ashok Simma:

I'm trying to query the Opsgenie python API based on time range but I don't see any API that supports the action.


Answers:
author: Nick H
body: Hi [@Ashok Simma](/t5/user/viewprofilepage/user-id/4747391) ,

Not a Python expert myself, but this is possible via the [alert API](https://docs.opsgenie.com/docs/alert-api#list-alerts) using something like Postman - so I have to *assume*it should be possible with Python as well.

You can [query](https://support.atlassian.com/opsgenie/docs/search-queries-for-alerts/) between date ranges. For example if you wanted to pull alerts created in the month of November, you might use something like this:

```
https://api.opsgenie.com/v2/alerts?query=createdAt%3E31-10-2022%20AND%20createdAt%3C01-12-2022
```

![queryapi1.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/228379i28381DC1132F5102/image-size/large?v=v2&px=999 "queryapi1.jpg")

I typically use a site like [URL Encoder](https://www.urlencoder.org/) to help, but not sure what the Python format / query might be. I'm not sure if any of that helps, but again leads me to believe it *should* be possible.

comments: author: Ashok Simma
body: Hi [@Nick H](/t5/user/viewprofilepage/user-id/2540930) thank you for the reply. its working for me


Tags: cloud
Schedule Start Notification
Asked by Carol Saldanha:

Our on-call schedule rotates at midnight. I've been trying to create a notification rule for Schedule Start notifications that only notifies the person on-call on the previous day during business hours.

I have ticked "1 day" in the "Notify before schedule starts"

and "Restrict to Time Intervals"

where I have selected "Time of Day" and restricted this to our business hours.

I have checked the notification method is correct.

This does not work - we are not getting notified for schedule start.

Any suggestions?

Carol


Answers:
author: Egor
body: Hey Carol,  

Thanks for reaching out to Atlassian Community!  

May I ask you please specify why you would need to restrict it to time intervals?  

Also, if you select the business hours and you want to get a notification 1 day before the schedule starts, then it will not match, since you mentioned that you do the rotations at midnight.   

In case you remove the option to restrict it to time intervals, then a notification will be triggered 1 day before the schedule starts.   

Please let me know if it helps.   

Best Regards,  
Egor

comments: author: Carol Saldanha
body: Hi Egor,

Apologies for having missed your question. We want to restrict notifications to business hours so that the person on call does not receive schedule start notifications at (or around) midnight.

Carol


Tags: notification

schedule
Is it possible to alert only the 1st rotation and then 2nd rotation after given time?
Asked by Blake_Wright:

We see there is a "notify next user (in rotation)" but this isn't quite what we are looking for.

For example, say we want the primary rotation to be a senior developer role and the backup rotation to be a junior developer role.

Senior Senior Senior (Primary rotation)

Junior Junior Junior (Backup rotation)

We want our escalation rule to first notify the senior developer. If the senior developer doesn't acknowledge then we want to notify the junior developer.

However, we don't want to put the senior developer in a rotation followed by a junior developer, this prevents us from using "notify next user (in rotation)." This would look like:

Senior Junior Senior (Primary rotation)

Junior Senior Junior (Backup rotation)

There is possibly another solution we can create to achieve this maybe?

Possible solution: I believe the best possible way is to create a primary and backup schedule, if not acknowledged by first schedule, notify second schedule.


Answers:
author: Nick H
body: Hi [@Blake_Wright](/t5/user/viewprofilepage/user-id/5090592) ,

It's **not** possible to notify a specific rotation of a schedule - FYI [@Andrew Laden](/t5/user/viewprofilepage/user-id/744425)

When an escalation rule is set to notify the on-call user(s) in a schedule, it will notify whoever is on-call determined by the red vertical line - regardless of the rotation(s).

So for this use case, you may want to break each rotation into its own individual schedule like a Primary vs. Secondary (or Senior vs. Junior).

The first rule of the escalation would notify the on-call user(s) of the Senior schedule, and the second rule would notify the on-call user(s) of the Junior schedule:

![senjun1.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/228197iC487C58308650ABC/image-size/large?v=v2&px=999 "senjun1.jpg")![senjun2.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/228196i73798650ACEDCF44/image-size/large?v=v2&px=999 "senjun2.jpg")

comments: author: Andrew Laden
body: [@Nick H](/t5/user/viewprofilepage/user-id/2540930) Sorry, I used the wrong word. Fixed my answer below.

You can use multiple schedules, and then in the notification rule in your escalation rule, you can select what schedule to use.

![Capture.JPG](https://community.atlassian.com/t5/image/serverpage/image-id/228202iCED0158AD26BD44F/image-size/large?v=v2&px=999 "Capture.JPG")


author: Andrew Laden
body: Yes, you can create multiple ~~rotations~~ schedules, And set your escalation rules first contact the on call in ~~rotation~~ schedule "senior" and then contact the on-call in ~~rotation~~ schedule "junior"
Build failure because of "class file has wrong version 52.0, should be 49.0
Asked by sai sravya:

Bamboo build failing because of the error "class file has wrong version 52.0, should be 49.0

If the compiler version has to be changed to the latest, how can we do that.![pom.PNG](https://community.atlassian.com/t5/image/serverpage/image-id/193730i88E94758C6DF5F19/image-size/large?v=v2&px=999 "pom.PNG")

This is the pom that I am currently using.


Answers:
author: Anonymous Coward
body: Simon says:

' Your maven configuration is set to compile for Java 1.8 while your compiler is 1.5 (class file version 49.0)

Make sure you have the correct compiler version installed on your system (1.8 since you want to compile with it) and set your JAVA_HOME to point to the JDK1.8. When your settings are correct, running the command:

javac

in a terminal should result in the output for Java 1.8 and your maven build should work fine.

I hope this helps.'

Simon out.
Is it possible to have all Bamboo YAM Spec on single repo?
Asked by Mohan L:

Hi All,

Let's assume I am using Bamboo 8.0.6 and bitbucket data center hosted on prem have all application as well as bamboo spec.

The scenario is : I have two application A and B have their own repo to manage their source code. Can we have one repo "devops-bamboo-pipeline" to keep YAML spec file for App A and App B instated of keeping YAML spec on App repo itself? How to trigger only specific app bamboo spec when code push happens to respective application repo?

\`\`\`

devops-bamboo-pipeline

\|------- Bamboo_AppA.yml ----\> Trigger when code push to App A repo

\| - ----- Bamboo_AppB.yml -----\> Trigger when code push to App B repo

\`\`\`

Any thought or pointer would be greatly appreciated!

Thanks

Mohan


Answers:
author: Eduardo Alvarenga
body: Hey [@Mohan L](/t5/user/viewprofilepage/user-id/925019),

Happy to help you again!

You can reference multiple files in a YAML spec by using include statements:

* <https://docs.atlassian.com/bamboo-specs-docs/8.0.6/specs.html?yaml#includes>

Here is a nice question that you can refer to for usage examples:

* <https://community.atlassian.com/t5/Bamboo-questions/how-to-use-bamboo-specs-include-YAML/qaq-p/1112625>

To trigger a specific plan when committing changes to its code repository, you need to configure it in a way that you'll have either a [repository polling](https://docs.atlassian.com/bamboo-specs-docs/8.0.6/specs.html?yaml#polling-the-repository-for-changes) rule or a [remote trigger](https://docs.atlassian.com/bamboo-specs-docs/8.0.6/specs.html?yaml#repository-triggers-a-build-on-commit) to from your *code repository* (not the specs repository). This way once your code repository changes, Bamboo will detect it and initiate a build.

Cheers,

Eduardo Alvarenga  
Atlassian Support APAC
Restricted Admin managing agent dedications
Asked by Kevin Bouman:

I am new to administering Bamboo so please bear with me.

I have a team member that states he used to have access to manage agent dedications. He gets a 403 error when trying to attempt the same action he used to be able to do. We recently upgraded bamboo from 7.0.6 to 8.0.6. The users is in the "Restricted Admin" permission and the "Enable restricted administrator role" is enabled.

Error the user is experiencing

![image (1).png](/t5/image/serverpage/image-id/193339iA9B73CE38D08A8DB/image-size/large?v=v2&px=999 "image (1).png")

What am I missing?


Answers:
author: Eduardo Alvarenga
body: Hello [@Kevin Bouman](/t5/user/viewprofilepage/user-id/1093589)

Starting with Bamboo 7.1, only Administrators would have access to agent dedication, the agent dedication permission to "Restricted Admins" was reintroduced in Bamboo 8.2 and 8.1.3 and newer releases.

* <https://jira.atlassian.com/browse/BAM-21602>

You would have to upgrade to either Bamboo 8.1.x or 8.2.x to benefit from that setting.

Sincerely,

Eduardo Alvarenga  
Atlassian Support APAC

comments: author: Kevin Bouman
body: Thanks [@Eduardo Alvarenga](/t5/user/viewprofilepage/user-id/4365410) this is exactly what I needed.
API response contains "* Connection #0 bamboo.<companyname>.com left intact."
Asked by james.mckean:

I am testing some Bamboo APIs with the goal of writing a report requested by management. I am using cURL until I figure out what works and then will probably move to Ansible.

In all responses I get a string "\* Connection #0 bamboo.\<companyname\>.com left intact." Usually, this is the last line before the json formatted payload and causes no problems. But if the response is long, the string may get inserted into the middle of the json payload resulting in broken json.

Here is an example snippet (I added the bold)

. . . "plan":{"shortName":"Mod of HelloWorld","shortKey":"MH","type":"chain","enabled":true,"link":{"href":"<https://bamboo.dev>\<companyname\>com/rest/api/latest/plan/TABVTJP**\* Connection #0 to host bamboo.dev.\<companyname\>.com left intact**

-MH","rel":"self"},"key":"TABXXJP-YY","name":"Test availability of BITBUCKET_BRANCH variable to java program - Mod of HelloWorld","planKey":{"key":"TABXXJP-YY"}}, . . .

Does anyone have any suggestions?


Answers:
author: Eduardo Alvarenga
body: Hello [@james.mckean](/t5/user/viewprofilepage/user-id/4184054)

Adding a header "**Connection: close**" to your cURL command line should solve the problem:

*

      curl -v -H "Connection: close" https://bamboo.dev.<companyname>.com

From this [page:](https://www.sneppets.com/software/connection-0-to-host-localhost-left-intact/)
> **Why is the connection left intact:**
>
> The connection is left intact, because the server allowed it to stay open and CURL no need to close it after you receive the response for the request sent. That's why the requests return '*Connection: keep-alive* ' headers when you expect '*Connection:close*'
>
> If you wanted to close the connection, then you could send CURL request with '*Connection: close* ' as shown below and you could see '*\* Closing connection 0*' in the response.

Regards,

Eduardo Alvarenga  
Atlassian Support APAC

comments: author: james.mckean
body: Hmm. Not exactly. Now it drops the "closing connection " notification into the json response, again breaking the json.

BSR-PLAN"}},{"shortName":"build the specs demo plan","shortKey":"SDP","type":"chain","enabled***\* Closing connection 1***   
***\* TLSv1.2 (OUT), TLS alert, close notify (256):***   
":false,"link":{"href":"<https://bamboo.dev.companyName.com/rest/api/>


author: Eduardo Alvarenga
body: Hello [@james.mckean](/t5/user/viewprofilepage/user-id/4184054)

That message comes from the SSL library that cURL is linked to (usually OpenSSL/LibreSSL) and will show up when using curl with a **"-v"** flag. Those messages are sent to the standard error output and can be discarded by your script.

Try running it without the "-v" flag.


author: james.mckean
body: That did it. Thanks!


Tags: api

json
How to upgrade Bamboo to use TLS 1.2
Asked by Myke:

Hey everyone.

I'm trying to figure out how to upgrade Bamboo to use TLS 1.2. I'm currently using Bamboo version 6.6.1. I tried doing some digging online but can't seem to find any guides on how to upgrade the TLS version for bamboo. Figured I'd ask on here as maybe some of you have done this before.


Answers:
author: Myke
body: Used this page to answer my questions  
<https://jira.atlassian.com/browse/BAM-20910>

comments: author: Jens
body: Hello Myke,

So you added -Dmail.smtp.ssl.protocols=TLSv1.2 to the file setenv.sh, restarted Bamboo, and it started to use TLS 1.2?

Thanks, J.


Tags: tls

update

upgrade
bootstrap - health check failed
Asked by Stefan Haus:

Dear support,

we switched from Bamboo 6.10.10 to 8.2.1.

After restart I of 8.2.1 we get the message  
"bootstrap - Bamboo bootstrap failed: Your Bamboo instance could not start because health check failed. "

Therefore we need some help. Which further information you need?

Best regards

Stefan Haus


Answers:
author: Eduardo Alvarenga
body: Hello [@Stefan Haus](/t5/user/viewprofilepage/user-id/4785791)

Welcome to **Atlassian Community!**

As you are upgrading from an old Bamboo release, your issue appears to be related to the licence. Can you confirm if your Bamboo licence is valid and active?

Bamboo releases from 7.0 have an extra licence validation code that prevents upgrades when using a licence that expired before the new version was released.

In case you have questions related to your licence, please don't post any private information here, instead, get in touch with <https://support.atlassian.com/support>

Regards,

Eduardo Alvarenga  
Atlassian Support APAC

comments: author: Stefan Haus
body: Dear Eduardo Alvarenga,

yes I can confirm, your Bamboo licence is valid and active.  
Would you please tell me to whom I should send this informatioen on Atlassian side to get the extra license code to run Bamboo 8.2.1?  
Because the info I send to you was send using <https://support.atlassian.com>.

Regards  
Stefan Haus


author: Eduardo Alvarenga
body: Hello [@Stefan Haus](/t5/user/viewprofilepage/user-id/4785791),

You need to raise a ticket on <https://support.atlassian.com/support> so we can continue with the support. In the case description, please provide more details on your issue and also mention this Community question to ease the understanding.  

Do not post any private information here as this is a public forum.

Cheers,

Eduardo Alvarenga  
Atlassian Support APAC
Bamboo REST API - Project and plan creation
Asked by Ronald Bolante:

Is there a way to programmatically create a project and a plan? Using the Bamboo REST API has been ruled out as there seems to be no API call to do such.

What I am trying to do is find a way to automate PIV (or PVT) that can be run from a build plan whenever Bamboo gets touched in any way (server reboots, application upgrades, etc.)

To start with, I am looking at implementing these 4 basic test items:

Create a project  
Create a plan  
Create a group  
Add a user

Thank you.


Answers:
author: Anonymous Coward
body: Simon says:

\` Yes you can, but you'll have to write your own Bamboo plugin. See docs on how to do that here: <https://developer.atlassian.com/server/bamboo/bamboo-plugin-guide/>

You'll need to spend some time exploring the source but you can do it. Good luck! \`

Simon out.

comments: author: Ronald Bolante
body: Hi [@Anonymous Coward](/t5/user/viewprofilepage/user-id/1155142) ,

Thank you for your suggestion. I wasn't able to go the plugin path as I thought the learning curve would be a bit steep.

I was able to do it via Java Specs and it's amazing.

Thanks again Simon.


Tags: rest-api