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
Copy file name to clipboardExpand all lines: content/learning-paths/servers-and-cloud-computing/dotnet-migration-nopcommerce/2-environment-setup.md
+14-28Lines changed: 14 additions & 28 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,25 +6,17 @@ weight: 2
6
6
layout: learningpathall
7
7
---
8
8
9
-
Create two VMs in the same Azure region with matching OS and tooling so differences are attributable to architecture, not configuration drift.
9
+
# Environment setup
10
10
11
-
This path was validated with Ubuntu 24.04 LTS VMs in `westus2`:
11
+
Set up an Arm Cobalt environment first, then keep your toolchain and runtime configuration stable across all test runs. This creates a reliable Arm baseline for migration and tuning work.
Start with the official [Azure Cobalt setup guide](https://learn.arm.com/learning-paths/servers-and-cloud-computing/cobalt/) and complete VM provisioning there first.
17
14
18
-
## Log in and create VMs
15
+
This path was validated with Ubuntu 24.04 LTS on Azure Cobalt in `westus2` (example VM size: `Standard_D2ps_v6`, 2 vCPUs).
19
16
20
-
```bash
21
-
az login --use-device-code
22
-
az account set --subscription <your-subscription>
23
-
```
24
-
25
-
Create both VMs in the same resource group and region.
17
+
## Install tools on Cobalt VM
26
18
27
-
## Install tools on each VM
19
+
Install the toolchain on the Cobalt VM before building and testing.
Confirm architecture and tool versions before proceeding.
34
+
41
35
```bash
42
36
uname -m
43
37
dotnet --version
44
38
docker --version
45
39
```
46
40
47
-
Expected output: `x86_64` on the x86 VM, `aarch64` on the Arm VM. Both should report the same .NET SDK version (9.0.x).
41
+
Expected output: `Arm` (kernel strings may still show architecture-specific values). Ensure the .NET SDK version is 9.0.x.
48
42
49
43
## PostgreSQL prerequisite for nopCommerce install
50
44
51
-
nopCommerce migrations on PostgreSQL require the `citext` extension. Create it before running the installer:
45
+
nopCommerce defaults to SQL Server, but this learning path uses PostgreSQL for Arm validation. For PostgreSQL installs, `citext` is required before migration/installation. Without it, installer migrations fail with `type "citext" does not exist` (captured in local test artifacts).
46
+
47
+
Create PostgreSQL and enable `citext` before running the installer:
52
48
53
49
```bash
50
+
# Start PostgreSQL for local validation.
54
51
docker run -d --name nop-postgres \
55
52
-e POSTGRES_USER=nop \
56
53
-e POSTGRES_PASSWORD=<password> \
57
54
-e POSTGRES_DB=nopcommerce \
58
55
-p 5432:5432 postgres:16
59
56
57
+
# Enable the extension required by nopCommerce migrations.
Copy file name to clipboardExpand all lines: content/learning-paths/servers-and-cloud-computing/dotnet-migration-nopcommerce/3-checkout-build-baseline.md
+50-47Lines changed: 50 additions & 47 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,10 +6,14 @@ weight: 3
6
6
layout: learningpathall
7
7
---
8
8
9
-
Pin nopCommerce to a reproducible release, build on both architectures, and capture a baseline that includes core storefront paths.
9
+
# Build and baseline
10
+
11
+
Create a reproducible Arm baseline before optimization work. This page pins source, verifies a clean build, and captures a representative endpoint baseline so later changes can be measured against a known control.
10
12
11
13
## Clone and pin the source
12
14
15
+
Pinning the exact tag and commit avoids silent drift in dependencies and behavior.
Start the app locally and complete installer setup with PostgreSQL.
29
40
30
41
```bash
31
42
cd src/Presentation/Nop.Web
32
43
dotnet run -c Release --no-build --urls http://0.0.0.0:5000
33
44
```
34
45
35
-
## Baseline methodology
36
-
37
-
Do not rely on `/install` alone. Baseline at least:
38
-
39
-
- Home page
40
-
- Search
41
-
- Product page
42
-
- Cart
43
-
- Checkout
44
-
45
-
Prerequisite: complete nopCommerce setup first (database configured and installer finished). Otherwise, storefront paths redirect to the install flow and do not represent real behavior.
46
-
47
-
Use a valid product URL from your seeded catalog (for example, `/apple-macbook-pro`), not a hard-coded slug that may not exist in your dataset.
48
-
49
-
Quick smoke probe (pre-install, useful as a connectivity check only):
46
+
Complete installation with PostgreSQL (`citext` enabled), then verify:
Before installation is complete, all storefront paths redirect to setup (`302`). Those numbers confirm reachability but are not valid performance baselines.
56
+
Expected after successful install: `root=200`, `install=302`.
65
57
66
-
## Installed-store endpoint baseline (validated)
58
+
## Baseline methodology
67
59
68
-
After fixing PostgreSQL setup (`citext`) and completing installation on both machines, the same endpoint benchmark was executed with `wrk` (`-t2 -c32 -d20s`) across this set:
60
+
Do not benchmark `/install`. Baseline real storefront paths:
69
61
70
62
-`/`
71
-
-`/search?q=book`
72
-
-`/electronics`
73
-
-`/apple-macbook-pro`
74
-
-`/cart`
75
-
-`/checkout`
76
-
77
-
Storefront pages returned `200`; `/checkout` returned `302` (expected without an authenticated session).
# Use fixed concurrency and iterations for a repeatable starting point.
78
+
python3 test_nopcommerce_endpoints.py \
79
+
--base-url http://127.0.0.1:5000 \
80
+
--concurrency 8 \
81
+
--iterations 20 \
82
+
--json-out arm_before.json
83
+
```
80
84
81
-
| Endpoint | x86 | Arm | Arm vs x86 |
82
-
|---|---:|---:|---:|
83
-
|`/apple-macbook-pro`| 35.40 | 32.28 | -8.8% |
84
-
|`/electronics`| 99.52 | 76.07 | -23.6% |
85
-
|`/search?q=book`| 28.18 | 27.40 | -2.8% |
85
+
## Baseline quality rules
86
86
87
-
Different endpoints show different gaps. Avoid reducing migration performance to a single number — use per-endpoint baselines to guide architecture-specific optimizations.
87
+
Use these rules before you compare any optimization result:
88
88
89
-
## Arm MCP accelerator (optional)
89
+
- Run at least 3 baseline trials with identical parameters.
90
+
- Keep endpoint order fixed per run (not randomized) when comparing before vs after.
91
+
- Keep database state and seeded data identical across runs.
92
+
- Capture raw JSON for every run and compare medians, not single outliers.
90
93
91
-
Use MCP to script repeated baseline runs and summarize deltas, but keep the manual baseline commands as your ground truth.
94
+
This baseline process becomes the control for every later tuning or code-change decision.
Copy file name to clipboardExpand all lines: content/learning-paths/servers-and-cloud-computing/dotnet-migration-nopcommerce/4-dependency-mapping-manifests.md
+12-14Lines changed: 12 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,23 +6,29 @@ weight: 4
6
6
layout: learningpathall
7
7
---
8
8
9
-
Use a manual-first audit, then use the Arm MCP server to accelerate checks.
9
+
# Audit dependencies
10
10
11
-
## Manual workflow (required)
11
+
Run dependency discovery before migration changes so you understand direct references, transitive risk, and hidden native payloads. This avoids late surprises when deploying to Arm.
12
12
13
13
### 1. Map direct references
14
14
15
+
Start with project-level references to see what your app explicitly depends on.
16
+
15
17
```bash
16
18
rg -n "<PackageReference|<ProjectReference" src
17
19
```
18
20
19
21
### 2. List transitive dependencies
20
22
23
+
Enumerate the full dependency graph; transitive packages often carry architecture-sensitive constraints.
24
+
21
25
```bash
22
26
dotnet list src/Presentation/Nop.Web/Nop.Web.csproj package --include-transitive
23
27
```
24
28
25
-
### 3. Generate an SBOM (required)
29
+
### 3. Generate an SBOM
30
+
31
+
Generate an SBOM so you can track all components, versions, and exposure surface as a first-class migration artifact. While not strictly necessary for migration purposes, this is a best practice that will save your team time down the road. You can also give this SBOM to an LLM to extract insights about your codebase for you.
26
32
27
33
```bash
28
34
dotnet tool install --global CycloneDX
@@ -33,6 +39,8 @@ If tool installation is blocked, treat `dotnet list --include-transitive` plus `
33
39
34
40
### 4. Inspect package internals for native payloads
35
41
42
+
Inspect package contents directly to find architecture-specific native binaries.
0 commit comments