Skip to content

Commit 7730b65

Browse files
authored
doc(ADR): deprecated functions do not have examples (#5932)
1 parent 696bdb2 commit 7730b65

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
**Title**: Deprecated functions do not have examples.
2+
3+
**Status**: accepted
4+
5+
**Context**: we write examples for all important functions, typically the ones
6+
that result in one or more RPCs. From time to time we need to deprecate a
7+
function, maybe because the function has a serious defect that cannot be
8+
resolved without changing its API, or because the function represents an
9+
experiment that "failed", or because we found a better way to do things.
10+
11+
**Decision**: when we deprecate a function we will remove the examples to that
12+
function. If the function is being replaced, we will reference the replacement
13+
in the "Examples" paragraph. If the function is being removed, we will simply
14+
remove the examples before the function itself. Unit tests and integration
15+
tests are preserved. While a function might be deprecated, it is expected to
16+
work.
17+
18+
**Consequences**: customers will be directed to the improved replacement,
19+
customers will not be misguided by examples that point to a deprecated approach.
20+
Developers of `google-cloud-cpp` will have fewer examples to maintain. Customers
21+
that cannot migrate to the new approach will not find examples of the approach
22+
they are currently using, this is mitigated by (a) they already are using the
23+
old approach, and (b) they can find the examples in the documentation
24+
accompanying old releases.

0 commit comments

Comments
 (0)