This repository has been archived by the owner on Oct 30, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fbb607c
commit e5006cf
Showing
12 changed files
with
96 additions
and
93 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,19 @@ | ||
# Notes on in-code documentation for this project | ||
|
||
All public types, methods, and properties should have documentation comments in the standard C# XML comment format. These will be automatically included in the [HTML documentation](https://launchdarkly.github.io/dotnet-server-sdk) that is generated on release. | ||
All public types, methods, and properties should have documentation comments in the standard C# XML comment format. | ||
These will be automatically included in the [HTML documentation](https://launchdarkly.github.io/dotnet-server-sdk) that is generated on release. | ||
|
||
Non-public items may have documentation comments as well, since those may be helpful to other developers working on this project, but they will not be included in the HTML documentation. | ||
Non-public items may have documentation comments as well, since those may be helpful to other developers working on this | ||
project, but they will not be included in the HTML documentation. | ||
|
||
The HTML documentation also includes documentation comments from `LaunchDarkly.CommonSdk`. These are included automatically when the documentation is built on release, so that developers can see a single unified API in the documentation rather than having to look in two packages. | ||
The HTML documentation also includes documentation comments from `LaunchDarkly.CommonSdk`. These are included automatically | ||
when the documentation is built on release, so that developers can see a single unified API in the documentation rather | ||
than having to look in two packages. | ||
|
||
The `docs-src` subdirectory contains additional Markdown content that is included in the documentation build, as follows: | ||
|
||
* `namespaces/<Fully.Qualified.Name.Of.Namespace>.md`: A file that is used as the description of a specific namespace. The first line is the summary, which will appear on both the landing page and the API page for the namespace; the rest of the file is the full description, which will appear on the API page for the namespace. | ||
* `namespaces/<Fully.Qualified.Name.Of.Namespace>.md`: A file that is used as the description of a specific namespace. | ||
* The first line is the summary, which will appear on both the landing page and the API page for the namespace; the rest | ||
* of the file is the full description, which will appear on the API page for the namespace. | ||
|
||
Markdown text can include hyperlinks to namespaces, types, etc. using the syntax `<xref:Fully.Qualified.Name.Of.Thing>`. |
20 changes: 15 additions & 5 deletions
20
pkgs/sdk/server/docs-src/namespaces/LaunchDarkly.Sdk.Json.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,20 @@ | ||
Helper classes and methods for interoperability with JSON. | ||
|
||
The NuGet package containing these types is [`LaunchDarkly.CommonSdk`](https://www.nuget.org/packages/LaunchDarkly.CommonSdk). Normally you should not need to reference that package directly; it is loaded automatically as a dependency of the main SDK package. | ||
The NuGet package containing these types is [`LaunchDarkly.CommonSdk`](https://www.nuget.org/packages/LaunchDarkly.CommonSdk). Normally you should not need to reference | ||
that package directly; it is loaded automatically as a dependency of the main SDK package. | ||
|
||
Any LaunchDarkly SDK type that has the marker interface <xref:LaunchDarkly.Sdk.Json.IJsonSerializable> has a canonical JSON encoding that is consistent across all LaunchDarkly SDKs. There are three ways to convert any such type to or from JSON: | ||
Any LaunchDarkly SDK type that has the marker interface <xref:LaunchDarkly.Sdk.Json.IJsonSerializable> has a canonical | ||
JSON encoding that is consistent across all LaunchDarkly SDKs. There are three ways to convert any such type to or from JSON: | ||
|
||
* When using the `System.Text.Json` API, these types already have the necessary attributes to behave correctly. | ||
* You may use the <xref:LaunchDarkly.Sdk.Json.LdJsonSerialization> methods <xref:LaunchDarkly.Sdk.Json.LdJsonSerialization.SerializeObject``1(``0)> and <xref:LaunchDarkly.Sdk.Json.LdJsonSerialization.DeserializeObject``1(System.String)> to convert to or from a JSON-encoded string. | ||
* When using the <xref:System.Text.Json> API, these types already have the necessary attributes to behave correctly. | ||
* You may use the <xref:LaunchDarkly.Sdk.Json.LdJsonSerialization> methods | ||
* <xref:LaunchDarkly.Sdk.Json.LdJsonSerialization.SerializeObject``1(``0)> and | ||
* <xref:LaunchDarkly.Sdk.Json.LdJsonSerialization.DeserializeObject``1(System.String)> to convert to or from a | ||
* JSON-encoded string. | ||
|
||
Earlier versions of the LaunchDarkly SDKs used `Newtonsoft.Json` for JSON serialization, but current versions have no such third-party dependency. Therefore, these types will not work correctly with the reflection-based `JsonConvert` methods in `Newtonsoft.Json` without some extra logic. There is an add-on package, [`LaunchDarkly.CommonSdk.JsonNet`](https://github.com/launchdarkly/dotnet-sdk-common/tree/main/src/LaunchDarkly.CommonSdk.JsonNet), that provides an adapter to make this work; alternatively, you can call <xref:LaunchDarkly.Sdk.Json.LdJsonSerialization.SerializeObject``1(``0)> and put the resulting JSON output into a `Newtonsoft.Json.Linq.JRaw` value. | ||
Earlier versions of the LaunchDarkly SDKs used `Newtonsoft.Json` for JSON serialization, but current versions have no | ||
such third-party dependency. Therefore, these types will not work correctly with the reflection-based `JsonConvert` | ||
methods in `Newtonsoft.Json` without some extra logic. There is an add-on package, [`LaunchDarkly.CommonSdk.JsonNet`](https://github.com/launchdarkly/dotnet-sdk-common/tree/main/src/LaunchDarkly.CommonSdk.JsonNet), | ||
that provides an adapter to make this work; alternatively, you can call | ||
<xref:LaunchDarkly.Sdk.Json.LdJsonSerialization.SerializeObject``1(``0)> and put the resulting JSON output into a | ||
`Newtonsoft.Json.Linq.JRaw` value. |
6 changes: 5 additions & 1 deletion
6
pkgs/sdk/server/docs-src/namespaces/LaunchDarkly.Sdk.Server.Integrations.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
Tools for configuring how the SDK connects to LaunchDarkly, or to other software components. | ||
|
||
This package contains the configuration builders for standard SDK components such as <xref:LaunchDarkly.Sdk.Server.Integrations.StreamingDataSourceBuilder>; the <xref:LaunchDarkly.Sdk.Server.Integrations.PersistentDataStoreBuilder> builder for use with database integrations (the specific database integrations themselves are provided by add-on libraries); and the test fixtures <xref:LaunchDarkly.Sdk.Server.Integrations.FileData> and <xref:LaunchDarkly.Sdk.Server.Integrations.TestData>. | ||
This package contains the configuration builders for standard SDK components such as | ||
<xref:LaunchDarkly.Sdk.Server.Integrations.StreamingDataSourceBuilder>; the | ||
<xref:LaunchDarkly.Sdk.Server.Integrations.PersistentDataStoreBuilder> builder for use with database integrations | ||
(the specific database integrations themselves are provided by add-on libraries); and the test fixtures | ||
<xref:LaunchDarkly.Sdk.Server.Integrations.FileData> and <xref:LaunchDarkly.Sdk.Server.Integrations.TestData>. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 5 additions & 1 deletion
6
pkgs/sdk/server/docs-src/namespaces/LaunchDarkly.Sdk.Server.Subsystems.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,9 @@ | ||
Interfaces for implementation of custom LaunchDarkly components. | ||
|
||
Most applications will not need to refer to these types. You will use them if you are creating a plugin component, such as a database integration. They are also used as interfaces for the built-in SDK components, so that plugin components can be used interchangeably with those: for instance, the configuration method <xref LaunchDarkly.Sdk.Server.ConfigurationBuilder.DataStore> references <xref LaunchDarkly.Sdk.Server.Subsystems.IDataStore> as an abstraction for the data store component. | ||
Most applications will not need to refer to these types. You will use them if you are creating a plugin component, such | ||
as a database integration. They are also used as interfaces for the built-in SDK components, so that plugin components | ||
can be used interchangeably with those: for instance, the configuration method | ||
<xref:LaunchDarkly.Sdk.Server.ConfigurationBuilder.DataStore(LaunchDarkly.Sdk.Server.Subsystems.IComponentConfigurer{LaunchDarkly.Sdk.Server.Subsystems.IDataStore})> | ||
references <xref:LaunchDarkly.Sdk.Server.Subsystems.IDataStore> as an abstraction for the data store component. | ||
|
||
The namespace also includes concrete types that are used as parameters within these interfaces. |
4 changes: 3 additions & 1 deletion
4
pkgs/sdk/server/docs-src/namespaces/LaunchDarkly.Sdk.Server.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
The main namespace for the LaunchDarkly server-side .NET SDK. | ||
|
||
You will most often use **<xref:LaunchDarkly.Sdk.Server.LdClient>** (the SDK client) and **<xref:LaunchDarkly.Sdk.Server.Configuration>** (configuration options for the client), as well as the **<xref:LaunchDarkly.Sdk.Context>** type from <xref:LaunchDarkly.Sdk>. | ||
You will most often use <xref:LaunchDarkly.Sdk.Server.LdClient> (the SDK client) and | ||
<xref:LaunchDarkly.Sdk.Server.Configuration> (configuration options for the client), as well as | ||
the <xref:LaunchDarkly.Sdk.Context> type from <xref:LaunchDarkly.Sdk>. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
The base namespace for all LaunchDarkly .NET-based SDKs, containing common types. | ||
|
||
Types in this namespace are part of the overall LaunchDarkly model, shared by both server-side and client-side SDKs. The one you will use most often is **<xref:LaunchDarkly.Sdk.Context>**. | ||
Types in this namespace are part of the overall LaunchDarkly model, shared by both server-side and client-side SDKs. | ||
The one you will use most often is <xref:LaunchDarkly.Sdk.Context>. | ||
|
||
The NuGet package containing these types is [`LaunchDarkly.CommonSdk`](https://www.nuget.org/packages/LaunchDarkly.CommonSdk). Normally you should not need to reference that package directly; it is loaded automatically as a dependency of the main SDK package. | ||
The NuGet package containing these types is [`LaunchDarkly.CommonSdk`](https://www.nuget.org/packages/LaunchDarkly.CommonSdk). Normally you should not need to reference | ||
that package directly; it is loaded automatically as a dependency of the main SDK package. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
--- | ||
_layout: landing | ||
--- | ||
|
||
# LaunchDarkly Server-Side SDK for .NET | ||
|
||
For first time users, visit our [LaunchDarkly Docs](https://docs.launchdarkly.com/sdk/server-side/dotnet) page. | ||
Within these docs, the <xref:LaunchDarkly.Sdk.Server.LdClient> and the <xref:LaunchDarkly.Sdk.ContextBuilder> are good | ||
starting points to explore from. | ||
|
||
|
||
This site contains the full API reference for the [`LaunchDarkly.ServerSdk`](https://www.nuget.org/packages/LaunchDarkly.ServerSdk) | ||
package, as well as the `LaunchDarkly.CommonSdk` package that is included automatically as a dependency of the SDK. | ||
|
||
For source code, see the [GitHub repository](https://github.com/launchdarkly/dotnet-server-sdk). | ||
The [developer notes](https://github.com/launchdarkly/dotnet-server-sdk/blob/main/CONTRIBUTING.md) there include links | ||
to other repositories used in the SDK. | ||
|
||
|
||
## Namespaces | ||
|
||
**[LaunchDarkly.Sdk](docs-src/namespaces/LaunchDarkly.Sdk.md):** The base namespace for all LaunchDarkly .NET-based SDKs, containing common types. | ||
|
||
**[LaunchDarkly.Sdk.Server](docs-src/namespaces/LaunchDarkly.Sdk.Server.md):** The main namespace for the LaunchDarkly server-side .NET SDK. | ||
|
||
**[LaunchDarkly.Sdk.Json](docs-src/namespaces/LaunchDarkly.Sdk.Json.md):** Helper classes and methods for interoperability with JSON. | ||
|
||
**[LaunchDarkly.Sdk.Server.Integrations](docs-src/namespaces/LaunchDarkly.Sdk.Server.Integrations.md):** Tools for configuring how the SDK connects to LaunchDarkly, or to other software components. | ||
|
||
**[LaunchDarkly.Sdk.Server.Interfaces](docs-src/namespaces/LaunchDarkly.Sdk.Server.Interfaces.md):** Interfaces and types that are part of the public API, but not needed for basic use of the SDK. | ||
|
||
**[LaunchDarkly.Sdk.Server.Subsystem](docs-src/namespaces/LaunchDarkly.Sdk.Server.Subsystems.md):** Interfaces for implementation of custom LaunchDarkly components. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
--- | ||
_layout: landing | ||
--- | ||
|
||
# LaunchDarkly Server-Side SDK for .NET: Telemetry | ||
|
||
This package contains telemetry components for the .NET Server-Side SDK. It is a separate package from the main SDK so | ||
that telemetry related changes will not impact the base SDK. | ||
|
||
To get started, check out the documentation for [TracingHook](api/LaunchDarkly.Sdk.Server.Telemetry.TracingHook.yml). | ||
|
||
This class can be used to add custom tracing to the SDK via the `System.Diagnostics` API, for usage with with compatible | ||
systems like [OpenTelemetry](https://opentelemetry.io/docs/languages/net/). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters