Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,32 @@ To stop the sample:

The sample are running the sample in foreground, logging and tracing from both client and server components are on stdout of the command window, to stop the sample, press Ctl C, which will terminate both the client and server components.

Debugging server component
--------------------------
Node remote debugging is enabled on port 9229 for server in docker compose, developer can attach to server from IDE e.g. vscode.

To set up the run config to debug in vscode, add below contents to `.vscode/launch.json`
```
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"address": "0.0.0.0",
"localRoot": "${workspaceFolder}/server",
"name": "Attach to Remote",
"port": 9229,
"remoteRoot": "/server",
"request": "attach",
"skipFiles": ["<node_internals>/**"],
"type": "node"
}
]
}
```

## Error Responses and handling:

[See ErrorResponses.md](./ErrorResponses.md)
2 changes: 1 addition & 1 deletion server/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ function loadDataFile(dataset_name: string, resource_file_name: string): any {
try {
return JSON.parse(resource);
} catch (error) {
process.stdout.write("Error parsing JSON:", error);
process.stdout.write("Error parsing JSON: " + error);
return null
}
}
Expand Down