You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
chore: fix broken links and bring changes from #1393 (#1448)
* chore: bring in changes from #1393 to next
* chore: backport to v0.48
* chore: remove test services
* chore: backport to v0.48
* chore: backport to v0.47
Copy file name to clipboardExpand all lines: docs/sources/next/examples/oauth-authentication.md
+209-1Lines changed: 209 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,6 +61,207 @@ export function authenticateUsingAzure(tenantId, clientId, clientSecret, scope,
61
61
62
62
{{< /code >}}
63
63
64
+
### Azure B2C
65
+
66
+
The following example shows how you can authenticate with Azure B2C using the [Client Credentials Flow](https://docs.microsoft.com/en-us/azure/active-directory-b2c/active-directory-b2c-reference-oauth-code#client-credentials-flow).
67
+
68
+
This example is based on a JMeter example found at the [azure-ad-b2c/load-tests](https://github.com/azure-ad-b2c/load-tests) repository.
69
+
70
+
To use this script, you need to:
71
+
72
+
1.[Set up your own Azure B2C tenant](https://learn.microsoft.com/en-us/azure/active-directory-b2c/tutorial-create-tenant)
73
+
- Copy the tenant name, it will be used in your test script.
74
+
1.[Register a web application](https://learn.microsoft.com/en-us/azure/active-directory-b2c/tutorial-register-applications?tabs=app-reg-ga)
75
+
- Register a single page application with the redirect URL of: https://jwt.ms. That's needed for the flow to receive a token.
76
+
- After the creation, you can get the Application (client) ID, and the Directory (tenant) ID. Copy both of them, they'll be used in your test script.
77
+
1.[Create a user flow so that you can sign up and create a user](https://docs.microsoft.com/en-us/azure/active-directory-b2c/tutorial-create-user-flows)
78
+
- Create a new user, and copy the username and password. They'll be used in the test script.
79
+
80
+
You can find the settings in the B2C settings in the Azure portal if you need to refer to them later on. Make sure to fill out all the variables for the `B2CGraphSettings` object, as well as replace `USERNAME` and `PASSWORD` in `export default function`.
Copy file name to clipboardExpand all lines: docs/sources/next/get-started/resources.md
-2Lines changed: 0 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -32,8 +32,6 @@ If you need a place to learn k6 and test your scripts, you can use these playgro
32
32
33
33
-[pizza.grafana.fun](https://pizza.grafana.fun/). A simple demo webapp. [grafana/quickpizza](https://github.com/grafana/quickpizza)
34
34
-[k6-http.grafana.fun](https://k6-http.grafana.fun). A simple HTTP Request & Response Service. [grafana/httpbin](https://github.com/grafana/httpbin)
35
-
-[k6-php.grafana.fun](https://k6-php.grafana.fun). A simple PHP website. [grafana/test.k6.io](https://github.com/grafana/test.k6.io)
36
-
-[test-api.k6.io](https://test-api.k6.io). A demo HTTP REST API with some WebSocket support. [grafana/test-api.k6.io](https://github.com/grafana/test-api.k6.io)
37
35
-[grpcbin.test.k6.io](https://grpcbin.test.k6.io/). A simple gRPC Request & Response Service. [grafana/k6-grpcbin](https://github.com/grafana/k6-grpcbin)
38
36
39
37
Note that these are shared testing environments - please avoid high-load tests. Alternatively, you can deploy and host them on your infrastructure and run the examples in the repository.
|[gRPC Fault](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/grpc)| Fault affecting gRPC requests from a target |
14
+
|[HTTP Fault](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/http)| Fault affecting HTTP requests from a target |
15
+
|[Pod Termination Fault](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/pod-termination)| Fault terminating a number of target Pods |
| count | integer or percentage | the number of pods to be terminated. It can be specified as a integer number or as a percentage, for example `30%`, that defines the fraction of target pods to be terminated |
16
+
17
+
{{% admonition type="note" %}}
18
+
19
+
If the count is a percentage and there are no enough elements in the target pod list, the number is rounded up.
20
+
For example '25%' of a list of 2 target pods will terminate one pod.
21
+
If the list of target pods is not empty, at least one pod is always terminated.
22
+
23
+
{{% /admonition %}}
24
+
25
+
## Example
26
+
27
+
This example defines a PorTermination fault that will terminate `30%` of target pods
|[PodDisruptor.injectGrpcFaults()](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/poddisruptor/injectgrpcfaults)| Inject [gRPC faults](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/grpc) in the target Pods |
18
-
|[PodDisruptor.injectHTTPFaults()](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/poddisruptor/injecthttpfaults)| Inject [HTTP faults](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/http) in the target Pods |
19
-
| PodDisruptor.targets() | Returns the list of target Pods of the PodDisruptor |
|[PodDisruptor.injectGrpcFaults()](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/poddisruptor/injectgrpcfaults)| Inject [gRPC faults](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/grpc) in the target Pods |
18
+
|[PodDisruptor.injectHTTPFaults()](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/poddisruptor/injecthttpfaults)| Inject [HTTP faults](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/http) in the target Pods |
19
+
| PodDisruptor.targets() | Returns the list of target Pods of the PodDisruptor |
20
+
|[PodDisruptor.terminatePods()](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/poddisruptor/terminate-pods)| executes a [Pod Termination fault](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/pod-termination) in the target Pods |
20
21
21
22
## Example
22
23
@@ -59,4 +60,4 @@ $ kubectl run nginx --image=nginx
59
60
60
61
You can also use the [xk6-kubernetes](https://github.com/grafana/xk6-kubernetes) extension for creating these resources from your test script.
| fault | object | description of the [gRPC faults](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/grpc) to be injected |
14
-
| duration | string | duration of the disruption |
15
-
| options (optional) | object |[options](#options) that control the injection of the fault |
14
+
| duration | string | duration of the disruption |
15
+
| options (optional) | object |[options](#options) that control the injection of the fault |
| fault | object | description of the [http faults](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/xk6-disruptor/faults/http) to be injected |
14
-
| duration | string | duration of the disruption |
15
-
| options (optional) | object |[options](#options) that control the injection of the fault |
14
+
| duration | string | duration of the disruption |
15
+
| options (optional) | object |[options](#options) that control the injection of the fault |
This is normal and means that one request was "in transit" at the time the faults were injected, causing the request to fail from a network connection reset.
0 commit comments