Event Logging installation
The Event Logging extension is a ShareAspace extension used to process subscription profile actions and generate log entries.
It can:
- Write events to the Windows Event Log
- Upload event logs back to ShareAspace
This provides a mechanism for tracking system activity and integrating event-based logging into ShareAspace workflows.
Prerequisites
The Event Logging extension requires:
- A server running Microsoft Internet Information Services (IIS).
- Software prerequisites.
Note
The Event Logging component requires access to the Windows Event Log on the hosting server.
Installation steps
Step 1: Run the installer
Run the EventLogger.msi installer to install the ShareAspace Event Logging extension on the IIS server.
Step 2: Configure IIS
During installation, an IIS Application Pool named "EventLogger" is created.
By default, the Application Pool runs under the built-in LocalSystem account.
Note
If a different account is used, it must have:
- Read access to the Event Logging installation folder
- Read and write access to the Windows Event Log:
%SystemRoot%\System32\Winevt\Logs\Application.evtx
Step 3: Configure the component
See the Configuration section.
Step 4: Register the extension
See the Extension registration section.
Configuration
Open the appsettings.json file located in the Event Logging installation folder.
By default:
C:\Program Files\Eurostep\ShareAspace\EventLogger\appsettings.json
Example configuration:
{
"NovaConfig": {
"SymmetricKey": "<generated-key>",
"ServerAddress": "https://host.machine.net:5001",
"UploadIntervalTime": 10
}
}
Configuration properties
SymmetricKey– Symmetric key used when registering the extension with ShareAspaceServerAddress– ShareAspace Host endpoint or Reverse Proxy addressUploadIntervalTime– Interval (in minutes) for uploading logs to ShareAspace
SymmetricKey
The SymmetricKey should be generated as described in:
Generate symmetric signing keys
OpenTelemetry configuration
The SendGrid Mail component supports OpenTelemetry (OTEL) for logging, metrics, and tracing.
Configuration is performed using configuration variables, for example:
{
"OTEL_SERVICE_NAME": "ShareAspace.EventLogging",
"OTEL_EXPORTER_OTLP_ENDPOINT": "https://host.example.com:4317",
"OTEL_EXPORTER_OTLP_PROTOCOL": "grpc"
}
Additional OTEL configuration options are available and are shared across all ShareAspace components.
See: OpenTelemetry logging.
Extension registration
The Event Logging extension must be registered as a Nova Extension on a bootstrapped ShareAspace collection.
Note
The Event Logging component must be running during registration, as a manifest exchange will occur.
The default application path is /EventLogging.
Example registration script:
param (
[Parameter(Mandatory = $true)]
[string]$NovaHost,
[Parameter(Mandatory = $true)]
[string]$PersonalAccessToken,
[Parameter(Mandatory = $true)]
[string]$Extension,
[Parameter(Mandatory = $true)]
[string]$ExtensionApiKey
)
$uri = "{0}/collection/externalExtension/novaExtension" -f $NovaHost
$pat = [System.Convert]::ToBase64String([System.Text.Encoding]::ASCII.GetBytes(":$PersonalAccessToken"))
$headers = @{ "Authorization" = "Basic $pat" }
$body = @{ "hostUri" = $Extension; "apiKey" = $ExtensionApiKey; "tokenLifeTime" = 15 } | ConvertTo-Json
Invoke-WebRequest -Method Post -Uri $uri -Headers $headers -Body $body -ContentType "application/json" -UseBasicParsing
Example usage:
.\Add-Extension.ps1 `
-NovaHost https://host.example.com:5001 `
-PersonalAccessToken "<token>" `
-Extension "https://logging.example.com/EventLogging" `
-ExtensionApiKey "<apikey>"