Is there a way to change logic apps default timezone? - azure

Currently I'm using logic apps to get/send emails. However, I noticed that, the received/sending time in logic apps is by default in UTC time zone.
Since I'm sending and receiving a lot of emails in logic apps, It's tedious to convert it for each actions.
Is there a way to change the default UTC time zone to a different time zone so that it can reflect to all my logic apps functionality?

If you have a recurrence trigger, you can add it there by defineing the timezone property under advanced scheduling. You can also add it to the work flow definition like this:
"timeZone": "Pacific Standard Time"

Related

Can Logic Apps Monitor a large number of calendars effectively?

PROBLEM
We want to track changes in user calendars, but are concerned with how often we'd need to check 2000+ user calendars (Outlook).
Would the process of monitoring over 2000 user calendars present a problem for our network?
WORKFLOW
Trigger (Check for calendar change) -> ACTION (Http: update a DB)
The Trigger below checks a calendar every 2 seconds. Is there a trigger that behaves like a "subscription" object where it simply handles a change notification?
For the question about how often to check the calendar events, it depends on your requirement. In my opinion, if you set check event every 2 seconds(it's a little bit more frequent), you'd better check if your logic app set as run in parallel. You can click the ... button of the trigger and click "Settings". Then check if it is same to below screenshot.
For your question about is there a trigger that behaves like a "subscription". I'm afraid it doesn't exist a trigger which can implement this requirement in logic app. We can also check if any backend api can implement it, we can see the graph api document.
The example in above screenshot is for mailFolders, but it's same with events. We can see it is necessary to specify a user(like me) or a group before the /events. So I don't think we can monitor the subscription events. You can raise a post on Azure feedback page to suggest developer add this feature.

Why is the timezone of Connect/webhook dates not UTC?

When processing webhook posts, I see the dates are all in my (Eastern US) timezone. This is reported correctly if I apply the option to include Time Zone Information.
I can work with this, but I have a few questions:
why not send in UTC, which is used consistently -- I believe -- throughout the API? (At least, the REST API)
Is Time Zone Information working correctly? I ask because this report says it doesn't support fractional info, such as India's UTC+5.5 correctly.)
What Time Zone is used in the webhook posts? I have changed both my personal preference and my account setting to Katmandu, but I still Eastern. (Thus, I cannot test #2 myself.)
Thank you
1.) Most datetimes coming back from API are UTC, however SOAP and Connect messages follow a hidden account setting. You will need to ask support to change it. It's called "Time Zone used for Connect and SOAP".
2.) Fractional datetimes should work fine
3.) Webhook and SOAP currently use the same time zone as mentioned above. Your UI preferences (account settings and personal preferences) that you see are aimed at UI users. Since you are an API integrator, they follow a different setting.

How does Acumatica calculate LastDateTimeModified

I have recently noticed that retrieving the LastDateTimeModified (through the WebService API) from Acumatica gives me the date and time in a very different time zone - I am guessing GMT time.
However when I view this through a Generic Inquiry it seems that it is showing the correct time - based on my Time Zone set up in the user profile.
Is there a way to get the LastDateTimeModified in the correct time zone when retrieving from the Web Service API. I have attempted changing the Time Zone for the SDK user with no success
Thanks,
G
For most screens, except a few CRM screens, the LastDateTimeModified and CreatedDateTime are stored in the same time zone as the database server machine. When reading it using web services, you are retrieving the raw value form the database, with no timezone conversion. It is up to you to convert it to the desired timezone.
The Help->Audit History panel does a manual conversion to the current user time zone. I have not been able to get the generic inquiry to show the time as you mention in your question; it is only showing the date.

Azure Notification Hub: How to handle registration for a million devices?

Requirement-
The requirement is to send notifications to devices on specific times. That is, if a user has setup a schedule at 07:00 AM for breakfast, he'll get a notification for the same like 'Its time for breakfast, blah blah blah!'.
However, if the user has already had his breakfast before 07:00 AM, he'll make his diary entry on what he had etc. and then the notification must not be sent to him.
This is a recurring schedule and the user will only change this if he needs to, otherwise, the schedule will mostly be the same.
What we have achieved?-
So, for now what we do is to register devices with tags like '{TimeZone:EST},{Breakfast:07:00:00}' on the app's launch.
In case, the user has already had his breakfast, we update his registration on notification hub to also contain a tag like '{HadBreakfast}' - So, the set of tags user's device is registered to becomes - '{TimeZone:EST},{Breakfast:07:00:00},{HadBreakfast}'
What are we stuck at?-
This approach will work very well because, when sending notifications, we use tag expression like - '{TimeZone:EST} && {Breakfast:07:00:00} && !{HadBreakfast}'
So, this will send a notification to all users that wants a notification for breakfast at 07:00:00 AM for EST timezone but not to the ones who already had their breakfast.
However, if the user is registered with a tag like {HadBreakfast}, then the next day, he might not get the notification based on the logic just described.
So, we came up with the workaround to de-register only the {HadBreakfast} tag at the end of day for all the devices which has that tag by running a scheduler.
But, somewhere in our mind, we think that is not the best solution for this problem.
Other Alternative-
We also thought of another alternative that we can run a scheduler for every hour within which, it will do the same thing of removing such tags for the past hour for all the user devices which has that tag - and this process seems to be effective than running it once in a day.
But we wanted to know thoughts from the community on what I can try out? If the method that we use is correct or not? What else could be done to do this more simply OR smoothly? What if we have a million plus devices? Will this work?
I would suggest exploring the option for modifying registration in bulk and using the Azure Scheduler for the reaccuring task

How to run a script every Monday morning on my express.js website (or any other specific time)?

I'd like to be able to run 'node sendSomeEmails.js' once every Monday morning.
So far, the easiest way I've found to do it, is actually stick a reminder in my calendar and spin up a terminal and do it myself : (
I'm building an automated email series using Mandrill. Users will subscribe on my website (built on node.js with express), get the first email right away, and then every Monday morning after that I'd like to send the next email in the series. I'll maintain how far along each subscribers is in my database, but I don't know the best way to trigger the Monday morning sends.
I'm running my site on IBM Bluemix, by the way. Maybe there's an easy way to do this with AWS... Although, nothing's ever been easy for me on AWS.
I haven't tried this but it looks possible based on there API.
Mandrill supports message scheduling. It also supports webhooks, you should schedule an email, and setup a webhook. Then when the message is sent it will trigger the webhook to schedule the next email.
https://mandrill.zendesk.com/hc/en-us/articles/205582667-Can-I-schedule-a-message-to-send-at-a-specific-time-
https://mandrillapp.com/api/docs/webhooks.JSON.html

Resources