Skip to content

Commit 51fe22d

Browse files
committed
Implement review suggestions
1 parent bf52333 commit 51fe22d

File tree

3 files changed

+27
-11
lines changed

3 files changed

+27
-11
lines changed

Migration.Tool.CLI/README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -661,6 +661,25 @@ Add the options under the `Settings` section in the configuration file.
661661
}
662662
```
663663

664+
## Logging
665+
666+
The migration tool uses [.NET logging](https://learn.microsoft.com/en-us/dotnet/core/extensions/logging) with console and file output. Configure log levels and file path in the `Logging` section of `appsettings.json`:
667+
668+
```json
669+
"Logging": {
670+
"LogLevel": {
671+
"Default": "Information",
672+
"Microsoft": "Warning"
673+
},
674+
"pathFormat": "logs/log.txt"
675+
}
676+
```
677+
678+
- **Console** - Real-time progress with timestamps
679+
- **Files** - Detailed logs at the specified path (default: `logs/log-<date>.txt`)
680+
681+
To use logging in custom migrations, inject `ILogger<T>` into your class constructor.
682+
664683
## Source instance API discovery
665684

666685
> :warning: **Warning** – source instance API discovery is only available when migrating from Kentico Xperience 13.

Migration.Tool.Extensions/README.md

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ The following sections provide detailed instructions for implementing each type
145145

146146
### Custom Class Mappings
147147

148-
You can customize class mappings to adjust the content model between the source instance and the target Xperience by Kentico instance. For example, you can merge multiple page types into a single content type, remodel page types as [reusable field scehams](https://docs.kentico.com/x/remodel_page_types_as_reusable_field_schemas_guides), or migrate them to the [content hub](https://docs.kentico.com/x/barWCQ) as reusable content.
148+
You can customize class mappings to adjust the content model between the source instance and the target Xperience by Kentico instance. For example, you can merge multiple page types into a single content type, remodel page types as [reusable field schemas](https://docs.kentico.com/x/remodel_page_types_as_reusable_field_schemas_guides), or migrate them to the [content hub](https://docs.kentico.com/x/barWCQ) as reusable content.
149149

150150
1. Create a new class.
151151
2. Add an `IServiceCollection` extension method. Use a separate method for every class mapping that you wish to configure.
@@ -287,7 +287,7 @@ Implement your decision logic based on available node properties (`NodeClassID`,
287287

288288
#### Available Actions
289289

290-
##### `options.Drop()`
290+
#### `options.Drop()`
291291
Skips migration of the linked page entirely. Use for temporary content, archived pages, or content that should be handled manually.
292292

293293
#### `options.Materialize()`
@@ -302,13 +302,10 @@ Creates a content item reference field in an ancestor page that points to the or
302302

303303
#### Common Strategies
304304

305-
**Content Type-Based**: Use `NodeClassID` to look up the content type and apply different strategies based on page type.
306-
307-
**Path-Based**: Filter by `NodeAliasPath` to handle different sections of your site (e.g., archive pages, temporary content).
308-
309-
**Site-Specific**: Use `source.SourceSite.SiteName` to apply different rules for different sites in multi-site scenarios.
310-
311-
**Contextual**: Combine node properties with ancestor analysis to make intelligent decisions about reference placement.
305+
- **Content Type-Based**: Use `NodeClassID` to look up the content type and apply different strategies based on page type.
306+
- **Path-Based**: Filter by `NodeAliasPath` to handle different sections of your site (e.g., archive pages, temporary content).
307+
- **Site-Specific**: Use `source.SourceSite.SiteName` to apply different rules for different sites in multi-site scenarios.
308+
- **Contextual**: Combine node properties with ancestor analysis to make intelligent decisions about reference placement.
312309

313310
#### Important Considerations
314311

@@ -336,7 +333,7 @@ After implementing your linked page director, you need to [register the director
336333
- **Deferred processing**: Some linked pages may be processed in a second pass if their dependencies aren't ready
337334

338335
**Debugging Tips:**
339-
- Use logging to track which strategy is applied to each linked page
336+
- Use [logging](../Migration.Tool.CLI/README.md#logging) to track which strategy is applied to each linked page
340337
- Verify that ancestor pages exist and have the expected structure
341338

342339
### Migrate Pages to Widgets

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ For a lift-and-shift migration, use the migration tool's default configuration:
9999
--sites --custom-modules --users --settings-keys --page-types --pages --type-restrictions --contact-management --forms --media-libraries --data-protection --custom-tables --members --categories
100100
```
101101

102-
5. **Review results** - Check console output and log files for issues or manual steps:
102+
5. **Review results** - Check console [output and log files](./Migration.Tool.CLI/README.md#logging) for issues or manual steps:
103103
- **Console** shows real-time progress and results
104104
- **Log files** capture detailed execution logs (`logs\log-<date>.txt`)
105105

0 commit comments

Comments
 (0)