Deprecation of methods and metadata elements
As the Microsoft code base continues to evolve, some methods and metadata elements will no longer be required. Microsoft will mark these obsolete methods and metadata elements for deprecation.
- Methods are marked with the SysObsolete attribute. Typically, this attribute recommends an alternative to the method.
- For metadata elements, the IsObsolete property is set to Yes.
The deprecation is compatible with both binaries and design time. The referencing code will continue to work as expected, and no immediate action is required. During compilation, any references to deprecated artifacts are reported as compile warnings.
Cleanup of deprecated elements
After a period of at least 12 months, Microsoft might delete obsolete methods and metadata elements.
However, if telemetry shows that any obsolete methods or metadata elements are still used, Microsoft will not delete them, to reduce the risk that consumers will be broken.
Minimize your risk of being affected
Here are some tips that you, as a consumer of the Microsoft code base, can use to avoid being affected when methods and metadata elements are deprecated:
- Compile your code base at least every 12 months on top of the latest code base. If you receive any warnings because deprecated artifacts are used, address those warnings as soon as possible.
- Avoid new dependencies on deprecated artifacts. Microsoft might have just deleted the artifact, because there is a time window between when releases and telemetry are available.
List of deprecated methods and metadata elements
For reference, download the Microsoft Excel file, ObsoleteElementsPerVersion.xlsx, which shows the artifacts that have been marked for deprecation in each major release.
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기