AWS SNS with SQS permissions - amazon-sqs

Looking at this blog post it seems that I need to open my SNS queue to the world to integrate it with SNS. Is this still the case?
I'm trying to implement automatic bounce handling for SES emails and Amazon recommend using a SNS/SQS pattern but if I understand this correctly it would mean that anyone can effectively remove people from our email list? I can't believe this is the case.

So I found some documentation which indicates that you can specify a source ARN in the queue permissions:
Add a condition that allows the action for the topic. Click Add
Conditions (optional), select ArnEquals for Condition, select
aws:SourceArn for Key, and paste in the topic ARN for Value. Click Add
Condition. The new condition should appear at the bottom of the box
(you may have to scroll down to see this).

Related

Azure - App Insights - how to track the logged-in Username in Auth Id?

What is the best-supported approach for tracking logged-in Usernames/Ids in App Insights telemetry?
A User with Username "JonTester1" said some Pages he visited 4 hours ago were really slow. How can I see everything JonTester1 did in App Insights to trouble shoot/know which pages he's referring to?
Seems like User Id in App Insights is some Azure-generated anonymized thing like u7gbh that Azure ties to its own idea of the same user (thru cookie?). It doesn't know about our app's usernames at all.
I've also seen a separate field in App Insights called Auth Id (or user_AuthenticatedId in some spots), which looks to sometimes have the actual username e.g. "JonTester1" filled in - but not always... And while I don't see any mention of this field in the docs, it seems promising. How is our app's code/config supposed to be setting that Auth Id to make sure every App Insights log/telemetry has it set?
Relevant MS docs:
https://learn.microsoft.com/en-us/azure/azure-monitor/app/usage-send-user-context
This looks to just copy one library Telemetry object's User Id into another... no mention of our custom, helpful Username/Id anyway... and most in-the-wild examples I see don't actually look like this, including MS docs own examples in the 3rd link below; they instead hardcode get a new TelemetryClient()
https://learn.microsoft.com/en-us/azure/azure-monitor/app/website-monitoring No mention of consistently tracking a custom Username/Id
https://learn.microsoft.com/en-us/azure/azure-monitor/app/api-custom-events-metrics#authenticated-users Shows some different helpful pieces, but still no full example. E.g. it says with only the setAuth... JS function call (still no full example of working client-side JS that tracks User) on the page, you don't need any server-side code for it to track custom User Id across both client-side and server-side telemetry sent to Azure... yet then it also shows explicit code to new up a TelemetryClient() server-side to track User Id (in the Global.asax.cs or where?)... so you do need both?
Similar SO questions, but don't connect the dots/show a full solution:
Azure Insights telemetry not showing Auth ID on all transactions
Application Insights - Tracking user and session across schemas
How is Application insight tracking the User_Id?
Display user ID in the metrics of application Insight
I'm hoping this question and answers can get this more ironed out; hopefully do a better job of documentation than the relevant MS docs...
The first link in your question lists the answer. What it does show you is how to write a custom telemetry initializer. Such an initializer lets you add or overwrite properties that will be send along any telemetry that is being send to App Insights.
Once you add it to the configuration, either in code or the config file (see the docs mentioned earlier in the answer) it will do its work without you needing to create special instances of TelemetryClient. That is why this text of you does not make sense to me:
[…] and most in-the-wild examples I see don't actually look like this, including MS docs own examples in the 3rd link below; they instead hardcode get a new TelemetryClient()
You can either overwrite the value of UserId or overwrite AuthenticatedUserId in your initializer. You can modify the code given in the docs like this:
if (requestTelemetry != null && !string.IsNullOrEmpty(requestTelemetry.Context.User.Id) &&
(string.IsNullOrEmpty(telemetry.Context.User.Id) || string.IsNullOrEmpty(telemetry.Context.Session.Id)))
{
// Set the user id on the Application Insights telemetry item.
telemetry.Context.User.AuthenticatedUserId = HttpContext.Current.User.Identity.Name;
}
You can then see the Auth Id and User Id by going to your AI resource -> Search and click an item. Make sure to press "Show All" first, otherwise the field is not displayed.
Auth Id in the screenshot below is set to the user id from the database in our example:
We access the server from azure functions as well so we set the user id server side as well since there is no client involved in such scenarios.
There is no harm in settting it in both places, javascript and server side via an initializer. That way you cover all scenario's.
You can also manually add user id to app insights by
appInsights.setAuthenticatedUserContext(userId);
See App Insights Authenticated users

Using Zapier to process a backlog of existing emails in GMail?

I've successfully set up a Zap to process new emails matching a given search in my Gmail account (extracting info and adding it to a Google Sheet). But I'd like to make it process the 145 existing matching emails already archived in my Gmail as well. Is there a way to accomplish this?
David here, from the Zapier Platform team. Unfortunately, Zapier is built around doing ongoing work, not a single task. Polling is specifically designed to only process new things after the zap has been turned on. So, you'll have to cheat a bit.
For the purposes of your backlog you could set the gmail filter to look for what it's set to now, plus a label (say, zapier-backlog). If you do the search right now, it should be empty (and a poll on the zap with that search shouldn't return anything). After you turn the zap on, add that label to all emails you want processed, and the'll show up as "new" to the zap and all get processed accordingly.
Once that's done, you'll want to remove those changes and only have it process new emails. Hope this helps. ​Let me know if you've got any other questions!

Any idea to archive emails in Conversations in Asana?

I would like to centralize every email from (or to) customers of a project in the Conversations view of a project in Asana. The goal is to keep an archive of all exchanges with a customer in one place for every team member.
I tried to use the project#mail.asana.com as CC in every emails that i send but customers don't have accounts on Asana (and i don't want them to access it) and so they can't save their replies in Conversations. I tried also to create an email group (in Google Apps) and add the Asana email at it but it didn't work.
Any idea to use the Conversations view as an archive ? Or maybe is there an external tool which integrate with Asana that can do this ?
Thanks a lot in advance !
Hmm, that's interesting! I suppose that if you don't have too many emails this makes some sense (otherwise it might make your Asana Inbox pretty noisy - everyone would see in their inbox every conversation)
I think what I would do is to set up a Gmail filter to automatically forward the email to your team. You can do this in Gmail like this: https://support.google.com/mail/answer/6579?hl=en. If you set up a good filter (i.e. sent to a group address) it seems like it would be pretty painless.
One thing to note is that the conversation in Asana will appear to come from whoever is associated with the email that's sending the conversation to Asana, so if you have a single POC with the outside world, it may make sense to only forward from their account. Alternatively, you could set up a special Asana user just for this purpose, and your teammates can follow a convention that "mailbot" (or whatever user it is) is just used to forward mail, and you should look at the content to get who the author was.

How does User Custom Field Value work in Jira Notification scheme

I am new to Jira and I have issue when some of the users are not getting email notification when someone tags them in a comment of the story.
My suggestion is to create outlook group and then I can add that as group in Notification scheme.
Along with that I would like to know how User Custom field value and Group custom field value works.
Any information along these lines is appreciated.
Thanks
About notifications:
add your users to jira, and set emails
create your groups (or roles) depending on what make more sense.
Then add users to groups
go to Admin>issues>notifications schemes> : create your scheme
Set notifications to your scheme, adding people to each event
There is a notification called "issue commented" or something similar.
Click add. Select Group(or role), and set wich group should be notificated
About the mentions, it is automatic, but you have to ensure your users are in the jira users directory and not only in a MActive Directory or whatever (if i remember ok):
http://blogs.atlassian.com/2013/06/using-watchers-and-mentions-effectively/
Say you and a coworker both discover the same issue; obviously, only one of you should file it. In the description you can quickly use an #mention to loop your colleague in on the issue. When you submit the issue to JIRA, they will get one notification that the issue was filed. That way, they don’t file the issue thinking that you didn’t. The benefit of using an #mention over adding them as a watcher is that they only get notified once.
About this question :"Along with that I would like to know how User Custom field value and Group custom field value works."
They works really similar to usual users and groups. What's your problem with them exactly.
Regards,

How to change the issue Type of an issue in JIRA via email?

I am working on an MVC application that is currently sending an email to JIRA and it is creating an issue. I am currently configuring all of the required fields and currently the issue being created has the issue Type set to bug as a default and also I think the priority set to minor.
I need to be able to change these two fields from the default as this application is used for clients that need to choose the correct issue and priority.
Currently I am using the TO, FROM, CC as the assignees, client and reporter. The summary and description are used by the subject and body respectively. This is why I don't know if it is actually possible to change these.
Can this actually be done, for example in the body "issueType" = "BUG", or "issueType":"Task"?
The application has the IssueType and Priority as dropdown list so could I append this to the body or maybe the subject of the email and send it. All code is working just need to know how/if I can set these two properties.
Update
I saw an example of this being used but I am unsure of how to implement this into an email form or if this can be done. And I am also using smtp gmail to send the information in my MVC application.
handler.params: project=XXOODD, issuetype=2
https://answers.atlassian.com/questions/39041/jira-creating-issues-and-comments-from-email
By default this cannot be done, but by using a couple of add-ons you can successfully get it to work:
https://marketplace.atlassian.com/plugins/com.metainf.jira.plugin.emailissue
https://marketplace.atlassian.com/plugins/com.javahollic.jira.jemh-ui

Resources