client/local, ipn, tailcfg: document which LocalAPI client APIs are stable
The client/local package doc said its API is not necessarily stable, but that caveat was easy to miss and only a few cert methods said anything explicit either way. People have been surprised by IPN bus changes between releases. Add explicit "API maturity" notes, matching the existing wording on the cert methods, marking stable: BugReport, BugReportWithOpts, CertDomains, CheckUpdate, CurrentDERPMap, DialTCP, UserDial, DisconnectControl, GetPrefs, EditPrefs, Status, StatusWithoutPeers, SetUseExitNode, SwitchProfile, UserProfile, and the WhoIs* methods. Mark unstable: ipn.Notify, WatchIPNBus, DoLocalRequest, the Debug*, Drive*, Check*, EventBus*, and Stream* methods, SetComponentDebugLogging, TailDaemonLogs, ShutdownTailscaled, GetDNSOSConfig, GetEffectivePolicy, GetServeConfig, and GetAppConnectorRouteInfo. Also note on tailcfg.DERPMap that the type is subject to minor changes over time though its general shape is stable, document that ipn.Prefs.CorpDNS is the internal name for "tailscale set --accept-dns", and add a package doc paragraph to client/local saying that methods without an explicit API maturity note should be assumed unstable. Updates #20406 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com> Change-Id: I9333c58ae312e392c61d7de77987282e84ce2aeb
This commit is contained in:
committed by
Brad Fitzpatrick
parent
b14f7b7543
commit
172124da8c
@@ -294,6 +294,9 @@ func ValidateNotifyWatchOpt(mask NotifyWatchOpt) error {
|
||||
// In any given notification, any or all of these may be nil, meaning
|
||||
// that they have not changed.
|
||||
// They are JSON-encoded on the wire, despite the lack of struct tags.
|
||||
//
|
||||
// API maturity: this type is not considered a stable API and is
|
||||
// subject to change between releases.
|
||||
type Notify struct {
|
||||
_ structs.Incomparable
|
||||
Version string // version number of IPN backend
|
||||
|
||||
+2
-1
@@ -291,7 +291,8 @@ func (v PrefsView) InternalExitNodePrior() tailcfg.StableNodeID { return v.ж.In
|
||||
func (v PrefsView) ExitNodeAllowLANAccess() bool { return v.ж.ExitNodeAllowLANAccess }
|
||||
|
||||
// CorpDNS specifies whether to install the Tailscale network's
|
||||
// DNS configuration, if it exists.
|
||||
// DNS configuration, if it exists. It is the internal name for
|
||||
// the "tailscale set --accept-dns=" flag.
|
||||
func (v PrefsView) CorpDNS() bool { return v.ж.CorpDNS }
|
||||
|
||||
// RunSSH bool is whether this node should run an SSH
|
||||
|
||||
+2
-1
@@ -130,7 +130,8 @@ type Prefs struct {
|
||||
ExitNodeAllowLANAccess bool
|
||||
|
||||
// CorpDNS specifies whether to install the Tailscale network's
|
||||
// DNS configuration, if it exists.
|
||||
// DNS configuration, if it exists. It is the internal name for
|
||||
// the "tailscale set --accept-dns=" flag.
|
||||
CorpDNS bool
|
||||
|
||||
// RunSSH bool is whether this node should run an SSH
|
||||
|
||||
Reference in New Issue
Block a user