Is there an auto trigger of SYNC request with some frequency? - google-smart-home

It seems that there are the following options to trigger SYNC request:
account linking
manual call by user via sync device phrase
via requestSync
Is there an auto trigger of SYNC request with some frequency?

No, SYNC intents will not be periodically sent to your service without some sort of prompt such as the three you mention: linking an account, the command "sync my devices", or sending requestSync from your service.

Related

How commands in fiware work correctly? Can we use IoT Agent instead of Orion Context Broker as user?

We are following the theory that as users we must issue a command to the Context Broker to change the state of a device: Image 1
In our case, this command already works if we do it from the IoT Agent, but however, if we execute it from the Context Broker through a PATCH, it does not reach the IoT Agent.
Do you know why this could be happening?
Our Context Broker request is the following: Image 2
And finally, the request we make from the IoT Agent, which is the one that works, is this: Image 3
Another doubt that arises is, if the IoT Agent updates all the information in the Context Broker, why not execute the request from there instead of from the Contex Broker?
Your request to Context Broker seems to be ok. Sometimes, the lack of ?type in the request causes problems (see for instance this post) but it doesn't seem to be your case.
I'd suggest to check registrations at Orion. Registration is the mechanism in which the request forwarding from Orion to IOTAgent is based (more info in Orion documentation. IOTAgent should create and manage them, but something could be failing. You can get existing registrations in Orion with the GET /v2/registrations operation.
With regards:
Another doubt that arises is, if the IoT Agent updates all the information in the Context Broker, why not execute the request from there instead of from the Contex Broker?
The FIWARE data management model is context-centric. Thus, the Context Broker is the central piece of the architecture, to intermediate between context producer and context consumer. Commands are a kind of "context production", so it makes sense that Context Broker deals with commands. Note that the client issuing the command maybe doesn't even are able to access to the IOTAgent directly (they use to be "close" to the physical devices they manage and not typically open to direct client requests).

I want to be notified by email of error messages when executing Snowflake tasks

I would like to ask how to notify the error message when executing a task by e-mail.
As a premise, I know that notification is possible using AWS (S3 and Lambda, SNS).
But is there a way to notify emails with Snowflake's default features?
Thank you for your confirmation.
Snowflake does not have this mechanism by default.
But to achieve this, you can use any of the following suggestions:
Write a JAVA stored procedure (Python is in private preview) to
send messages and attach as a subtask.
You can use SNOWALERT
Or, as you wrote, use AWS mechanisms such as Amazon CloudWatch
Snowflake can send emails now with call system$send_email(). You can call this within your tasks.
For example:
call system$send_email(
'my_email_int',
'felipe#example.com, dan#example.com, rajiv#example.com',
'This is the subject',
'This is the body'
);
Read more:
https://hoffa.medium.com/hey-snowflake-send-me-an-email-243741a0fe3

How to subscribe to Salesforce connected app webhooks?

I want to implement a connected OAuth app in Salesforce which should trigger push events in case some entities changed, for example an opportunity was closed.
Zapier implemented something similar
https://zapier.com/apps/salesforce/integrations/webhook
Could not find something I need which is a simple way to subscribe to entity changes using the OAuth client's token and passing a webhook endpoint. I read about apex callouts, streaming API and outbound messages.
Yeah, we solved this exact problem at Fusebit and I can help you understand the process as well.
Typically speaking here's what you need to do:
Create triggers on the Salesforce Objects you want to get updates for
Upload Apex class that will send an outgoing message to a pre-determined URL
Enable Remote Site Setting for the Domain you want to send the message to
Add in Secret Verification (or other auth method) to prevent spamming of your external URL
If you're leveraging javascript, then you can use the jsforce sdk & salesforce tooling API to push the code into the salesforce instance AFTER the Auth flow has occurred AND on Salesforce Instances that have API access enabled (typically - this is enterprise and above OR professional with API enabled).
This will be helpful for you to look through: https://jamesward.com/2014/06/30/create-webhooks-on-salesforce-com/
FYI - Zapier's webhooks implementation is actually polling every 15 minutes, instead of real-time incoming events.
In which programming language?
For consuming outbound messages you just need to be able to accept an XML message and send back "Ack" message to acknowledge receiving, otherwise SF will keep trying to resend it for 24h.
For consuming platform events / streaming API / Change Data Capture (CDC) you'll need to raise the event in SF (Platform Event you could raise from code, flow, process builder, CDC would happen automatically, you just tell it which objects it should track).
And then in client app you'd need to login to SF (SOAP or REST API), subscribe to channel (any library that supports cometd should be fine). Have you seen "EMP Connector", mentioned for example in https://trailhead.salesforce.com/en/content/learn/modules/change-data-capture/subscribe-to-events?trail_id=architect-solutions-with-the-right-api ?
Picking right messaging way is an art, there's free course that can help: https://trailhead.salesforce.com/en/content/learn/trails/architect-solutions-with-the-right-api
And pretty awesome PDF if you want to study for certification: https://resources.docs.salesforce.com/sfdc/pdf/integration_patterns_and_practices.pdf

Icinga 2 API - set service group in maintenance?

How does one fire off a web request to icinga2 to set a service group into maintenance? Documentation is tough to find.
We frequently encounter false positive alerts during deployment (due to app-spinup) and would like to be able to programattically disable checking on service groups until deployment is finished.
There is no unified api yet (that's something we plan for 2.4 later this year). You should use the external commands for that - given that You must first fetch all servicegroup members and send a command ffor each I'd suggest using Livestatus. Details at http://docs.icinga.org/icinga2/latest/doc/module/icinga2/chapter/alternative-frontends#setting-up-livestatus

how to send event(RPC) to service/application in nagios

I am using nagios to monitor certain services. I want to trigger event when particular services goes in error state. Lets say disk space is full so send event(like RPC ) to particular service which will resolve this issue.How to configure nagios to send such event ?
In nagios, these are called event handlers. You define a command and tell the service to run that under the proper circumstances.

Resources