All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ed Tanous <ed.tanous@intel.com>
To: openbmc@lists.ozlabs.org
Subject: Re: SNMP query
Date: Tue, 29 Jan 2019 10:38:49 -0800	[thread overview]
Message-ID: <b6d75766-87ca-6ed5-6995-255cfeab3518@intel.com> (raw)
In-Reply-To: <CANT4NrJLCLwH6dW9iTD8yMUjdbw-7-ai6YEfw97s0D-sr33Vww@mail.gmail.com>

On 1/29/19 9:31 AM, susan jasinski wrote:
> 
> I am looking for feedback on whether we _should_ implement something
> similar?
It sounds like a pretty reasonable thing, and something that other types
of systems (non BMC) do today.

> 
> - If we do not get a response, then we would provide a validation
> message like "Invalid host name or IP address, or the device did not
> respond to the SNMP query"
> 

What would the backend of this look like?  I don't think we have any
example of anything that "tests" a given settings change without
actually applying it.  Would you make the settings change, then roll it
back if it didn't work?  If that's your flow, you could likely just do
it with the apply button, and drop the "test" button altogether.

The flow could look something like:
1. User clicks apply
2. Webui requests the change from the backend, then subscribes to the
log events.
3. Backend tests the new settings by "querying" the SNMP device
4. Backend logs a signal if the SNMP device didn't respond to a ping.
5. Javascript sees signal, and gives the user the appropriate message
(possibly through Rebeccas new "toast" messages, possibly through the
form validation if the page is still up.

The above flow likely saves you as lot of complexity in implementation,
as most of the infrastructure is already there, there's only a minor
interface change needed (to add the new signal type) and you don't have
to handle the rollback case.

Coming back to the test button idea, if that's the path you're looking
to follow, how would you overcome the HTTP timeout limits?  I believe
our http timeouts are set at 15 seconds, very similar to what the SNMP
timeouts are.  Would you do a "double" request and request the change,
then a second requests to see if it applied?  Would you use the
subscribe API?  How would settings be rolled back?

PS, This list tends to prefer text emails over HTML emails.  I'm not
sure how to configure that in gmail, but it must be doable.

Thanks,

-Ed

  reply	other threads:[~2019-01-29 18:36 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-29 17:31 SNMP query susan jasinski
2019-01-29 18:38 ` Ed Tanous [this message]
2019-01-29 18:52 ` Ratan Gupta
2019-01-30 16:42   ` susan jasinski
2019-02-01 23:20 ` krtaylor

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b6d75766-87ca-6ed5-6995-255cfeab3518@intel.com \
    --to=ed.tanous@intel.com \
    --cc=openbmc@lists.ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.