OpenALPR Webhook Processor for IP Cameras

ok there is logging in place for registration failure now, pull latest, we will be able to see why the call is failing. make sure your username/password is what you use to log into the on prem openalpr server.
 
Yup. Looks like a registration issue. Username and pass is correct.

JSON:
{"log":"[20:40:59 ERR] failed to register Agent\n","stream":"stdout","time":"2021-01-06T20:40:59.309747234Z"}
{"log":"System.Net.Http.HttpRequestException\n","stream":"stdout","time":"2021-01-06T20:40:59.309814977Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.AgentRegistration.RegisterAgentAsync(Uri serverUrl, String username, String password, Boolean ignoreSslErrors) in /src/OpenAlprWebhookProcessor/HeartbeatService/Registration/AgentRegistration.cs:line 42\n","stream":"stdout","time":"2021-01-06T20:40:59.309827923Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.HeartbeatService.RegisterAgentAsync() in /src/OpenAlprWebhookProcessor/HeartbeatService/HeartbeatService.cs:line 153\n","stream":"stdout","time":"2021-01-06T20:40:59.309838285Z"}
{"log":"Unhandled exception. System.Net.Http.HttpRequestException\n","stream":"stderr","time":"2021-01-06T20:40:59.320089774Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.AgentRegistration.RegisterAgentAsync(Uri serverUrl, String username, String password, Boolean ignoreSslErrors) in /src/OpenAlprWebhookProcessor/HeartbeatService/Registration/AgentRegistration.cs:line 42\n","stream":"stderr","time":"2021-01-06T20:40:59.320127786Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.HeartbeatService.RegisterAgentAsync() in /src/OpenAlprWebhookProcessor/HeartbeatService/HeartbeatService.cs:line 153\n","stream":"stderr","time":"2021-01-06T20:40:59.320140864Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.HeartbeatService.StartAsync(CancellationToken cancellationToken) in /src/OpenAlprWebhookProcessor/HeartbeatService/HeartbeatService.cs:line 45\n","stream":"stderr","time":"2021-01-06T20:40:59.320148622Z"}
{"log":"   at Microsoft.Extensions.Hosting.Internal.Host.StartAsync(CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T20:40:59.320153405Z"}
{"log":"   at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.RunAsync(IHost host, CancellationToken token)\n","stream":"stderr","time":"2021-01-06T20:40:59.320157728Z"}
{"log":"   at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.RunAsync(IHost host, CancellationToken token)\n","stream":"stderr","time":"2021-01-06T20:40:59.320162297Z"}
{"log":"   at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.Run(IHost host)\n","stream":"stderr","time":"2021-01-06T20:40:59.320168281Z"}
{"log":"   at OpenAlprWebhookProcessor.Program.Main(String[] args) in /src/OpenAlprWebhookProcessor/Program.cs:line 21\n","stream":"stderr","time":"2021-01-06T20:40:59.320175203Z"}
 
Ok. Here is the crash log:

JSON:
{"log":"[22:03:48 WRN] 'AddEntityFramework*' was called on the service provider, but 'UseInternalServiceProvider' wasn't called in the DbContext options configuration. Remove the 'AddEntityFramework*' call as in most cases it's not needed and might cause conflicts with other products and services registered in the same service provider.\n","stream":"stdout","time":"2021-01-06T22:03:48.522542149Z"}
{"log":"[22:03:49 INF] Entity Framework Core 3.1.10 initialized 'ProcessorContext' using provider 'Microsoft.EntityFrameworkCore.Sqlite' with options: None\n","stream":"stdout","time":"2021-01-06T22:03:49.137697805Z"}
{"log":"[22:03:50 ERR] Failed executing DbCommand (18ms) [Parameters=[@__companyId_0='?' (Size = 36)], CommandType='Text', CommandTimeout='30']\n","stream":"stdout","time":"2021-01-06T22:03:50.175419414Z"}
{"log":"SELECT \"c\".\"Id\", \"c\".\"CompanyId\", \"c\".\"Username\"\n","stream":"stdout","time":"2021-01-06T22:03:50.17545565Z"}
{"log":"FROM \"Companies\" AS \"c\"\n","stream":"stdout","time":"2021-01-06T22:03:50.175466459Z"}
{"log":"WHERE \"c\".\"CompanyId\" = @__companyId_0\n","stream":"stdout","time":"2021-01-06T22:03:50.175473323Z"}
{"log":"LIMIT 1\n","stream":"stdout","time":"2021-01-06T22:03:50.175480613Z"}
{"log":"[22:03:50 ERR] An exception occurred while iterating over the results of a query for context type 'OpenAlprWebhookProcessor.Data.ProcessorContext'.\n","stream":"stdout","time":"2021-01-06T22:03:50.213416809Z"}
{"log":"Microsoft.Data.Sqlite.SqliteException (0x80004005): SQLite Error 1: 'no such table: Companies'.\n","stream":"stdout","time":"2021-01-06T22:03:50.213450659Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteException.ThrowExceptionForRC(Int32 rc, sqlite3 db)\n","stream":"stdout","time":"2021-01-06T22:03:50.213456465Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.PrepareAndEnumerateStatements(Stopwatch timer)+MoveNext()\n","stream":"stdout","time":"2021-01-06T22:03:50.213460624Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.GetStatements(Stopwatch timer)+MoveNext()\n","stream":"stdout","time":"2021-01-06T22:03:50.213464635Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteDataReader.NextResult()\n","stream":"stdout","time":"2021-01-06T22:03:50.213468574Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior)\n","stream":"stdout","time":"2021-01-06T22:03:50.213472575Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213476492Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteDbDataReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213480536Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213484559Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213489043Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213493814Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.Internal.QueryingEnumerable`1.AsyncEnumerator.InitializeReaderAsync(DbContext _, Boolean result, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213497852Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.Internal.QueryingEnumerable`1.AsyncEnumerator.MoveNextAsync()\n","stream":"stdout","time":"2021-01-06T22:03:50.213501903Z"}
{"log":"Microsoft.Data.Sqlite.SqliteException (0x80004005): SQLite Error 1: 'no such table: Companies'.\n","stream":"stdout","time":"2021-01-06T22:03:50.213505882Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteException.ThrowExceptionForRC(Int32 rc, sqlite3 db)\n","stream":"stdout","time":"2021-01-06T22:03:50.213510444Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.PrepareAndEnumerateStatements(Stopwatch timer)+MoveNext()\n","stream":"stdout","time":"2021-01-06T22:03:50.213531703Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.GetStatements(Stopwatch timer)+MoveNext()\n","stream":"stdout","time":"2021-01-06T22:03:50.213537807Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteDataReader.NextResult()\n","stream":"stdout","time":"2021-01-06T22:03:50.213541829Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior)\n","stream":"stdout","time":"2021-01-06T22:03:50.213545852Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213549875Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteDbDataReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213553834Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.21355785Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213561977Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213566072Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.Internal.QueryingEnumerable`1.AsyncEnumerator.InitializeReaderAsync(DbContext _, Boolean result, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.213570234Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.Internal.QueryingEnumerable`1.AsyncEnumerator.MoveNextAsync()\n","stream":"stdout","time":"2021-01-06T22:03:50.213574376Z"}
{"log":"[22:03:50 ERR] failed to register Agent\n","stream":"stdout","time":"2021-01-06T22:03:50.227443996Z"}
{"log":"Microsoft.Data.Sqlite.SqliteException (0x80004005): SQLite Error 1: 'no such table: Companies'.\n","stream":"stdout","time":"2021-01-06T22:03:50.22747266Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteException.ThrowExceptionForRC(Int32 rc, sqlite3 db)\n","stream":"stdout","time":"2021-01-06T22:03:50.227481234Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.PrepareAndEnumerateStatements(Stopwatch timer)+MoveNext()\n","stream":"stdout","time":"2021-01-06T22:03:50.227487919Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.GetStatements(Stopwatch timer)+MoveNext()\n","stream":"stdout","time":"2021-01-06T22:03:50.227494566Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteDataReader.NextResult()\n","stream":"stdout","time":"2021-01-06T22:03:50.227500814Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior)\n","stream":"stdout","time":"2021-01-06T22:03:50.227508059Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.227512128Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteDbDataReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.227516188Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.227520315Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.227524417Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.227543916Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.Internal.QueryingEnumerable`1.AsyncEnumerator.InitializeReaderAsync(DbContext _, Boolean result, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.227548995Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.Internal.QueryingEnumerable`1.AsyncEnumerator.MoveNextAsync()\n","stream":"stdout","time":"2021-01-06T22:03:50.227561763Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.ShapedQueryCompilingExpressionVisitor.SingleOrDefaultAsync[TSource](IAsyncEnumerable`1 asyncEnumerable, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.227569921Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.ShapedQueryCompilingExpressionVisitor.SingleOrDefaultAsync[TSource](IAsyncEnumerable`1 asyncEnumerable, CancellationToken cancellationToken)\n","stream":"stdout","time":"2021-01-06T22:03:50.227574247Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.HeartbeatService.RegisterAgentAsync() in /src/OpenAlprWebhookProcessor/HeartbeatService/HeartbeatService.cs:line 163\n","stream":"stdout","time":"2021-01-06T22:03:50.2275796Z"}
{"log":"Unhandled exception. Microsoft.Data.Sqlite.SqliteException (0x80004005): SQLite Error 1: 'no such table: Companies'.\n","stream":"stderr","time":"2021-01-06T22:03:50.236620609Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteException.ThrowExceptionForRC(Int32 rc, sqlite3 db)\n","stream":"stderr","time":"2021-01-06T22:03:50.236655309Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.PrepareAndEnumerateStatements(Stopwatch timer)+MoveNext()\n","stream":"stderr","time":"2021-01-06T22:03:50.236664189Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.GetStatements(Stopwatch timer)+MoveNext()\n","stream":"stderr","time":"2021-01-06T22:03:50.236668354Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteDataReader.NextResult()\n","stream":"stderr","time":"2021-01-06T22:03:50.236672334Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior)\n","stream":"stderr","time":"2021-01-06T22:03:50.236676373Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T22:03:50.23668029Z"}
{"log":"   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteDbDataReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T22:03:50.236684664Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T22:03:50.236688759Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T22:03:50.236692957Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T22:03:50.236697028Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.Internal.QueryingEnumerable`1.AsyncEnumerator.InitializeReaderAsync(DbContext _, Boolean result, CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T22:03:50.236702455Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.Internal.QueryingEnumerable`1.AsyncEnumerator.MoveNextAsync()\n","stream":"stderr","time":"2021-01-06T22:03:50.236709712Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.ShapedQueryCompilingExpressionVisitor.SingleOrDefaultAsync[TSource](IAsyncEnumerable`1 asyncEnumerable, CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T22:03:50.236714806Z"}
{"log":"   at Microsoft.EntityFrameworkCore.Query.ShapedQueryCompilingExpressionVisitor.SingleOrDefaultAsync[TSource](IAsyncEnumerable`1 asyncEnumerable, CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T22:03:50.236733645Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.HeartbeatService.RegisterAgentAsync() in /src/OpenAlprWebhookProcessor/HeartbeatService/HeartbeatService.cs:line 163\n","stream":"stderr","time":"2021-01-06T22:03:50.236739783Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.HeartbeatService.StartAsync(CancellationToken cancellationToken) in /src/OpenAlprWebhookProcessor/HeartbeatService/HeartbeatService.cs:line 45\n","stream":"stderr","time":"2021-01-06T22:03:50.236744137Z"}
{"log":"   at Microsoft.Extensions.Hosting.Internal.Host.StartAsync(CancellationToken cancellationToken)\n","stream":"stderr","time":"2021-01-06T22:03:50.236748439Z"}
{"log":"   at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.RunAsync(IHost host, CancellationToken token)\n","stream":"stderr","time":"2021-01-06T22:03:50.236752384Z"}
{"log":"   at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.RunAsync(IHost host, CancellationToken token)\n","stream":"stderr","time":"2021-01-06T22:03:50.236757803Z"}
{"log":"   at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.Run(IHost host)\n","stream":"stderr","time":"2021-01-06T22:03:50.236764009Z"}
{"log":"   at OpenAlprWebhookProcessor.Program.Main(String[] args) in /src/OpenAlprWebhookProcessor/Program.cs:line 21\n","stream":"stderr","time":"2021-01-06T22:03:50.236769964Z"}

Here is the appsettings.json:

JSON:
{
  "AllowedHosts": "*",
  "OpenAlprAgent": {
    "Cameras": [
      {
        "Latitude": 11.1111,
        "Longitude": -11.1111,
        "Manufacturer": "Dahua",
        "Name": "<redacted>",
        "OpenAlprCameraId": <redacted>,
        "Password": "<redacted>",
        "UpdateOverlayTextUrl": "http://10.200.200.14/cgi-bin/configManager.cgi?action=setConfig&VideoWidget[0].CustomTitle[1].Text=",
        "Username": "admin"
      }
    ],
    "Hostname": "<redacted>",
    "OpenAlprWebServer": {
      "Endpoint": "https://10.200.200.54",
      "IgnoreSslErrors": true,
      "Username": "<redacted>",
      "Password": "<redacted>"
    },
    "Uid": "<redacted>",
    "Version": "2.8.101"
  },
  "ConnectionStrings": {
    "ProcessorContext": "Data Source=config/processor.db"
  },
  "WebRequestLoggingEnabled": false
}
 
I'll have to troubleshoot a bit later this evening when I have more time. I'm getting overlays and I'm seeing a connected agent but I'm not seeing any plate data in the local OpenALPR server
 
The local OpenALPR is showing 1 camera and 1 site on the main dashboard. When I go to "View Details" on the site, it shows an Agent Name and a Hostname (they have identical numbers) with a thumbs up and 1 camera. If I click "Config" it says "Unable to connect to agent" and "agent_not_connected". I'm getting overlays so I know I'm getting the webhooks. It's just not showing any plates being received in the local OpenALPR server. Here are my logs for what its worth. I feel like we are super close to closing the deal on this:

JSON:
{"log":"[00:19:43 WRN] 'AddEntityFramework*' was called on the service provider, but 'UseInternalServiceProvider' wasn't called in the DbContext options configuration. Remove the 'AddEntityFramework*' call as in most cases it's not needed and might cause conflicts with other products and services registered in the same service provider.\n","stream":"stdout","time":"2021-01-07T00:19:43.194916538Z"}
{"log":"[00:19:44 INF] Entity Framework Core 3.1.10 initialized 'ProcessorContext' using provider 'Microsoft.EntityFrameworkCore.Sqlite' with options: None\n","stream":"stdout","time":"2021-01-07T00:19:44.847164497Z"}
{"log":"[00:19:44 INF] Entity Framework Core 3.1.10 initialized 'ProcessorContext' using provider 'Microsoft.EntityFrameworkCore.Sqlite' with options: None\n","stream":"stdout","time":"2021-01-07T00:19:44.863075257Z"}
{"log":"[00:19:45 INF] Executed DbCommand (53ms) [Parameters=[], CommandType='Text', CommandTimeout='30']\n","stream":"stdout","time":"2021-01-07T00:19:45.549152314Z"}
{"log":"SELECT COUNT(*) FROM \"sqlite_master\" WHERE \"name\" = '__EFMigrationsHistory' AND \"type\" = 'table';\n","stream":"stdout","time":"2021-01-07T00:19:45.549226531Z"}
{"log":"[00:19:45 INF] Executed DbCommand (3ms) [Parameters=[], CommandType='Text', CommandTimeout='30']\n","stream":"stdout","time":"2021-01-07T00:19:45.7281065Z"}
{"log":"SELECT \"MigrationId\", \"ProductVersion\"\n","stream":"stdout","time":"2021-01-07T00:19:45.728250314Z"}
{"log":"FROM \"__EFMigrationsHistory\"\n","stream":"stdout","time":"2021-01-07T00:19:45.728266499Z"}
{"log":"ORDER BY \"MigrationId\";\n","stream":"stdout","time":"2021-01-07T00:19:45.72827383Z"}
{"log":"[00:19:49 INF] Now listening on: http://[::]:80\n","stream":"stdout","time":"2021-01-07T00:19:49.191138483Z"}
{"log":"[00:19:49 INF] Application started. Press Ctrl+C to shut down.\n","stream":"stdout","time":"2021-01-07T00:19:49.191733723Z"}
{"log":"[00:19:49 INF] Hosting environment: Production\n","stream":"stdout","time":"2021-01-07T00:19:49.191851566Z"}
{"log":"[00:19:49 INF] Content root path: /app\n","stream":"stdout","time":"2021-01-07T00:19:49.192033424Z"}
{"log":"[00:19:49 INF] Executed DbCommand (12ms) [Parameters=[@__companyId_0='?' (Size = 36)], CommandType='Text', CommandTimeout='30']\n","stream":"stdout","time":"2021-01-07T00:19:49.199837846Z"}
{"log":"SELECT \"c\".\"Id\", \"c\".\"CompanyId\", \"c\".\"Username\"\n","stream":"stdout","time":"2021-01-07T00:19:49.199877661Z"}
{"log":"FROM \"Companies\" AS \"c\"\n","stream":"stdout","time":"2021-01-07T00:19:49.199888853Z"}
{"log":"WHERE \"c\".\"CompanyId\" = @__companyId_0\n","stream":"stdout","time":"2021-01-07T00:19:49.199896729Z"}
{"log":"LIMIT 1\n","stream":"stdout","time":"2021-01-07T00:19:49.199905205Z"}
{"log":"[00:19:49 INF] Agent registered with server successfully\n","stream":"stdout","time":"2021-01-07T00:19:49.293842784Z"}
{"log":"[00:23:12 INF] Request starting HTTP/1.1 POST http://<redacted>3859/webhook application/json 10615\n","stream":"stdout","time":"2021-01-07T00:23:12.392537004Z"}
{"log":"[00:23:12 INF] Executing endpoint 'OpenAlprWebhookProcessor.WebhookProcessor.WebhookController.Post (OpenAlprWebhookProcessor)'\n","stream":"stdout","time":"2021-01-07T00:23:12.6599716Z"}
{"log":"[00:23:12 INF] Route matched with {action = \"Post\", controller = \"Webhook\"}. Executing controller action with signature System.Threading.Tasks.Task`1[Microsoft.AspNetCore.Mvc.ActionResult] Post() on controller OpenAlprWebhookProcessor.WebhookProcessor.WebhookController (OpenAlprWebhookProcessor).\n","stream":"stdout","time":"2021-01-07T00:23:12.747761278Z"}
{"log":"[00:23:12 INF] request received from: ::ffff:54.221.95.194\n","stream":"stdout","time":"2021-01-07T00:23:12.960773736Z"}
{"log":"[00:23:13 INF] adding job for plate: LUBY12\n","stream":"stdout","time":"2021-01-07T00:23:13.017100345Z"}
{"log":"[00:23:13 INF] processing job for plate: LUBY12\n","stream":"stdout","time":"2021-01-07T00:23:13.017772634Z"}
{"log":"[00:23:13 INF] Entity Framework Core 3.1.10 initialized 'ProcessorContext' using provider 'Microsoft.EntityFrameworkCore.Sqlite' with options: None\n","stream":"stdout","time":"2021-01-07T00:23:13.157217654Z"}
{"log":"[00:23:13 INF] Executed DbCommand (3ms) [Parameters=[@p0='?', @p1='?', @p2='?', @p3='?', @p4='?', @p5='?', @p6='?' (Size = 3968), @p7='?' (Size = 6), @p8='?'], CommandType='Text', CommandTimeout='30']\n","stream":"stdout","time":"2021-01-07T00:23:13.606864078Z"}
{"log":"INSERT INTO \"PlateGroups\" (\"Id\", \"AlertDescription\", \"IsAlert\", \"OpenAlprCameraId\", \"OpenAlprProcessingTimeMs\", \"PlateConfidence\", \"PlateJpeg\", \"PlateNumber\", \"ReceivedOn\")\n","stream":"stdout","time":"2021-01-07T00:23:13.606912726Z"}
{"log":"VALUES (@p0, @p1, @p2, @p3, @p4, @p5, @p6, @p7, @p8);\n","stream":"stdout","time":"2021-01-07T00:23:13.606925341Z"}
{"log":"[00:23:13 INF] Executing HttpStatusCodeResult, setting HTTP status code 200\n","stream":"stdout","time":"2021-01-07T00:23:13.709508959Z"}
{"log":"[00:23:13 INF] Executed action OpenAlprWebhookProcessor.WebhookProcessor.WebhookController.Post (OpenAlprWebhookProcessor) in 963.6327ms\n","stream":"stdout","time":"2021-01-07T00:23:13.727908106Z"}
{"log":"[00:23:13 INF] Executed endpoint 'OpenAlprWebhookProcessor.WebhookProcessor.WebhookController.Post (OpenAlprWebhookProcessor)'\n","stream":"stdout","time":"2021-01-07T00:23:13.732339531Z"}
{"log":"[00:23:13 INF] HTTP POST /webhook responded 200 in 1339.3447 ms\n","stream":"stdout","time":"2021-01-07T00:23:13.74294483Z"}
{"log":"[00:23:13 INF] Request finished in 1378.8405ms 200 \n","stream":"stdout","time":"2021-01-07T00:23:13.759276868Z"}
{"log":"[00:23:19 INF] clearing expired overlay for: 254963574\n","stream":"stdout","time":"2021-01-07T00:23:19.157631745Z"}
 
hard to troubleshoot these when i don't have the cloud calling my service. i think it might be the company id not matching when the webhook gets relayed to the local one.

pull latest try it again
 
I can always send my cloud webhooks to you temporarily for testing.

I'll pull the latest and give it a try...
 
Still no plates showing in my local Server. It sees the agent but when I click "Configure" there is nothing there which may be normal since there really isn't an "agent" connected to it. I'll go back through my appsettings.json and make sure I didn't misconfigure something there.

You want me to forward my webhooks to you to for testing? Would that help?
 

Attachments

  • Screenshot from 2021-01-06 19-31-15.png
    Screenshot from 2021-01-06 19-31-15.png
    2.6 MB · Views: 6
  • Screenshot from 2021-01-06 19-31-11.png
    Screenshot from 2021-01-06 19-31-11.png
    3 MB · Views: 6
Last edited:
Nothing is going to show up when you configure, it's not using websockets. go to Webhook.site - Test, process and transform emails and HTTP requests and generate a custom url, leave that window open and put that custom url into your openalpr Endpoint field then wait for it to push something there

the logs show it sending the webhook successfully {"log":"[00:23:13 INF] HTTP POST /webhook responded 200 in 1339.3447 ms\n","stream":"stdout","time":"2021-01-07T00:23:13.74294483Z"} so there's probably just something wrong with the payload
 
Last edited:
So I'm not getting anything sent to that temporary webhook website when I put in the temporary webhook address at the Endpoint in appsettings.json. Maybe that is why I'm not seeing plates on the local server...
 
and your webhook url looks like https://webhook.site/asdfcgf-adce-484c-9bf6-1c317f8a91b5 ? When you are posting to the webhook site are you seeing the HTTP 200 messages in the logs?
 
JSON:
"OpenAlprWebServer": {
      "Endpoint": "https://webhook.site/95f9f78a-fe89-4ac1-9f90-f481ecaf1186",                                                               
      "IgnoreSslErrors": true,
      "Username": "user",
      "Password": "pass"
 
I can confirm I'm getting overlays so I know I'm getting webhooks. It doesn't appear to be relaying it anywhere though after that.
 
Here is the log:

JSON:
{"log":"[02:28:44 WRN] 'AddEntityFramework*' was called on the service provider, but 'UseInternalServiceProvider' wasn't called in the DbContext options configuration. Remove the 'AddEntityFramework*' call as in most cases it's not needed and might cause conflicts with other products and services registered in the same service provider.\n","stream":"stdout","time":"2021-01-07T02:28:44.154195089Z"}
{"log":"[02:28:44 ERR] failed to register Agent\n","stream":"stdout","time":"2021-01-07T02:28:44.851420118Z"}
{"log":"System.Net.Http.HttpRequestException: \u003c!DOCTYPE html\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851467585Z"}
{"log":"\u003chtml lang=\"en\"\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851482557Z"}
{"log":"    \u003chead\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851490684Z"}
{"log":"        \u003cmeta charset=\"utf-8\"\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851498397Z"}
{"log":"        \u003cmeta name=\"viewport\" content=\"width=device-width, initial-scale=1\"\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851505907Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.8515152Z"}
{"log":"        \u003ctitle\u003eNot Found\u003c/title\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851522052Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.851529395Z"}
{"log":"        \u003c!-- Fonts --\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851535371Z"}
{"log":"        \u003clink rel=\"dns-prefetch\" href=\"/fonts.gstatic.com\"\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.85154156Z"}
{"log":"        \u003clink href=\"https://fonts.googleapis.com/css?family=Nunito\" rel=\"stylesheet\"\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851549198Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.851556417Z"}
{"log":"        \u003c!-- Styles --\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851562272Z"}
{"log":"        \u003cstyle\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851571311Z"}
{"log":"            html, body {\n","stream":"stdout","time":"2021-01-07T02:28:44.851577758Z"}
{"log":"                background-color: #fff;\n","stream":"stdout","time":"2021-01-07T02:28:44.851584229Z"}
{"log":"                color: #636b6f;\n","stream":"stdout","time":"2021-01-07T02:28:44.851590515Z"}
{"log":"                font-family: 'Nunito', sans-serif;\n","stream":"stdout","time":"2021-01-07T02:28:44.851599634Z"}
{"log":"                font-weight: 100;\n","stream":"stdout","time":"2021-01-07T02:28:44.851605606Z"}
{"log":"                height: 100vh;\n","stream":"stdout","time":"2021-01-07T02:28:44.851611078Z"}
{"log":"                margin: 0;\n","stream":"stdout","time":"2021-01-07T02:28:44.851616832Z"}
{"log":"            }\n","stream":"stdout","time":"2021-01-07T02:28:44.851622639Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.85162987Z"}
{"log":"            .full-height {\n","stream":"stdout","time":"2021-01-07T02:28:44.851635434Z"}
{"log":"                height: 100vh;\n","stream":"stdout","time":"2021-01-07T02:28:44.851640859Z"}
{"log":"            }\n","stream":"stdout","time":"2021-01-07T02:28:44.851646488Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.851652083Z"}
{"log":"            .flex-center {\n","stream":"stdout","time":"2021-01-07T02:28:44.85165952Z"}
{"log":"                align-items: center;\n","stream":"stdout","time":"2021-01-07T02:28:44.851665235Z"}
{"log":"                display: flex;\n","stream":"stdout","time":"2021-01-07T02:28:44.851670804Z"}
{"log":"                justify-content: center;\n","stream":"stdout","time":"2021-01-07T02:28:44.851676383Z"}
{"log":"            }\n","stream":"stdout","time":"2021-01-07T02:28:44.851682031Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.851689829Z"}
{"log":"            .position-ref {\n","stream":"stdout","time":"2021-01-07T02:28:44.851695262Z"}
{"log":"                position: relative;\n","stream":"stdout","time":"2021-01-07T02:28:44.851716284Z"}
{"log":"            }\n","stream":"stdout","time":"2021-01-07T02:28:44.851724776Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.851755262Z"}
{"log":"            .code {\n","stream":"stdout","time":"2021-01-07T02:28:44.85176401Z"}
{"log":"                border-right: 2px solid;\n","stream":"stdout","time":"2021-01-07T02:28:44.851770826Z"}
{"log":"                font-size: 26px;\n","stream":"stdout","time":"2021-01-07T02:28:44.851779329Z"}
{"log":"                padding: 0 15px 0 15px;\n","stream":"stdout","time":"2021-01-07T02:28:44.851785724Z"}
{"log":"                text-align: center;\n","stream":"stdout","time":"2021-01-07T02:28:44.851791894Z"}
{"log":"            }\n","stream":"stdout","time":"2021-01-07T02:28:44.851797675Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.851805239Z"}
{"log":"            .message {\n","stream":"stdout","time":"2021-01-07T02:28:44.851810737Z"}
{"log":"                font-size: 18px;\n","stream":"stdout","time":"2021-01-07T02:28:44.851817028Z"}
{"log":"                text-align: center;\n","stream":"stdout","time":"2021-01-07T02:28:44.851822783Z"}
{"log":"            }\n","stream":"stdout","time":"2021-01-07T02:28:44.851828935Z"}
{"log":"        \u003c/style\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851836248Z"}
{"log":"    \u003c/head\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851842619Z"}
{"log":"    \u003cbody\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851848512Z"}
{"log":"        \u003cdiv class=\"flex-center position-ref full-height\"\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851854698Z"}
{"log":"            \u003cdiv class=\"code\"\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851861428Z"}
{"log":"                404            \u003c/div\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851867277Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.851873119Z"}
{"log":"            \u003cdiv class=\"message\" style=\"padding: 10px;\"\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851878593Z"}
{"log":"                Not Found            \u003c/div\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.85188522Z"}
{"log":"        \u003c/div\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851891026Z"}
{"log":"    \u003c/body\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851897048Z"}
{"log":"\u003c/html\u003e\n","stream":"stdout","time":"2021-01-07T02:28:44.851902964Z"}
{"log":"\n","stream":"stdout","time":"2021-01-07T02:28:44.851909192Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.AgentRegistration.RegisterAgentAsync(Uri serverUrl, String username, String password, Boolean ignoreSslErrors) in /src/OpenAlprWebhookProcessor/HeartbeatService/Registration/AgentRegistration.cs:line 43\n","stream":"stdout","time":"2021-01-07T02:28:44.851915262Z"}
{"log":"   at OpenAlprWebhookProcessor.HeartbeatService.HeartbeatService.RegisterAgentAsync() in /src/OpenAlprWebhookProcessor/HeartbeatService/HeartbeatService.cs:line 155\n","stream":"stdout","time":"2021-01-07T02:28:44.851924635Z"}
{"log":"[02:28:44 INF] Entity Framework Core 3.1.10 initialized 'ProcessorContext' using provider 'Microsoft.EntityFrameworkCore.Sqlite' with options: None\n","stream":"stdout","time":"2021-01-07T02:28:44.8603842Z"}
{"log":"[02:28:45 INF] Executed DbCommand (22ms) [Parameters=[], CommandType='Text', CommandTimeout='30']\n","stream":"stdout","time":"2021-01-07T02:28:45.092627329Z"}
{"log":"SELECT COUNT(*) FROM \"sqlite_master\" WHERE \"name\" = '__EFMigrationsHistory' AND \"type\" = 'table';\n","stream":"stdout","time":"2021-01-07T02:28:45.092663969Z"}
{"log":"[02:28:45 INF] Executed DbCommand (1ms) [Parameters=[], CommandType='Text', CommandTimeout='30']\n","stream":"stdout","time":"2021-01-07T02:28:45.134506171Z"}
{"log":"SELECT \"MigrationId\", \"ProductVersion\"\n","stream":"stdout","time":"2021-01-07T02:28:45.134571864Z"}
{"log":"FROM \"__EFMigrationsHistory\"\n","stream":"stdout","time":"2021-01-07T02:28:45.13458823Z"}
{"log":"ORDER BY \"MigrationId\";\n","stream":"stdout","time":"2021-01-07T02:28:45.134595917Z"}
{"log":"[02:28:45 INF] Now listening on: http://[::]:80\n","stream":"stdout","time":"2021-01-07T02:28:45.281662312Z"}
{"log":"[02:28:45 INF] Application started. Press Ctrl+C to shut down.\n","stream":"stdout","time":"2021-01-07T02:28:45.282610273Z"}
{"log":"[02:28:45 INF] Hosting environment: Production\n","stream":"stdout","time":"2021-01-07T02:28:45.282846314Z"}
{"log":"[02:28:45 INF] Content root path: /app\n","stream":"stdout","time":"2021-01-07T02:28:45.283198284Z"}
{"log":"[02:29:50 INF] Request starting HTTP/1.1 POST http://<REDACTED>3859/webhook application/json 10855\n","stream":"stdout","time":"2021-01-07T02:29:50.968258435Z"}
{"log":"[02:29:51 INF] Executing endpoint 'OpenAlprWebhookProcessor.WebhookProcessor.WebhookController.Post (OpenAlprWebhookProcessor)'\n","stream":"stdout","time":"2021-01-07T02:29:51.120180004Z"}
{"log":"[02:29:51 INF] Route matched with {action = \"Post\", controller = \"Webhook\"}. Executing controller action with signature System.Threading.Tasks.Task`1[Microsoft.AspNetCore.Mvc.ActionResult] Post() on controller OpenAlprWebhookProcessor.WebhookProcessor.WebhookController (OpenAlprWebhookProcessor).\n","stream":"stdout","time":"2021-01-07T02:29:51.262028663Z"}
{"log":"[02:29:53 INF] request received from: ::ffff:35.170.81.143\n","stream":"stdout","time":"2021-01-07T02:29:53.033663398Z"}
{"log":"[02:29:53 INF] adding job for plate: LUBY12\n","stream":"stdout","time":"2021-01-07T02:29:53.040811725Z"}
{"log":"[02:29:53 INF] processing job for plate: LUBY12\n","stream":"stdout","time":"2021-01-07T02:29:53.043126732Z"}
{"log":"[02:29:53 INF] Entity Framework Core 3.1.10 initialized 'ProcessorContext' using provider 'Microsoft.EntityFrameworkCore.Sqlite' with options: None\n","stream":"stdout","time":"2021-01-07T02:29:53.056186075Z"}
{"log":"[02:29:53 INF] Executed DbCommand (11ms) [Parameters=[@p0='?', @p1='?', @p2='?', @p3='?', @p4='?', @p5='?', @p6='?' (Size = 3944), @p7='?' (Size = 6), @p8='?'], CommandType='Text', CommandTimeout='30']\n","stream":"stdout","time":"2021-01-07T02:29:53.439823167Z"}
{"log":"INSERT INTO \"PlateGroups\" (\"Id\", \"AlertDescription\", \"IsAlert\", \"OpenAlprCameraId\", \"OpenAlprProcessingTimeMs\", \"PlateConfidence\", \"PlateJpeg\", \"PlateNumber\", \"ReceivedOn\")\n","stream":"stdout","time":"2021-01-07T02:29:53.43987305Z"}
{"log":"VALUES (@p0, @p1, @p2, @p3, @p4, @p5, @p6, @p7, @p8);\n","stream":"stdout","time":"2021-01-07T02:29:53.439890127Z"}
{"log":"[02:29:53 INF] Entity Framework Core 3.1.10 initialized 'ProcessorContext' using provider 'Microsoft.EntityFrameworkCore.Sqlite' with options: None\n","stream":"stdout","time":"2021-01-07T02:29:53.57166309Z"}
{"log":"[02:29:53 INF] Executed DbCommand (1ms) [Parameters=[@___agentConfiguration_OpenAlprWebServer_Username_0='?' (Size = 22)], CommandType='Text', CommandTimeout='30']\n","stream":"stdout","time":"2021-01-07T02:29:53.986242915Z"}
{"log":"SELECT \"c\".\"Id\", \"c\".\"CompanyId\", \"c\".\"Username\"\n","stream":"stdout","time":"2021-01-07T02:29:53.986287562Z"}
{"log":"FROM \"Companies\" AS \"c\"\n","stream":"stdout","time":"2021-01-07T02:29:53.986304643Z"}
{"log":"WHERE \"c\".\"Username\" = @___agentConfiguration_OpenAlprWebServer_Username_0\n","stream":"stdout","time":"2021-01-07T02:29:53.986313853Z"}
{"log":"LIMIT 1\n","stream":"stdout","time":"2021-01-07T02:29:53.986320263Z"}
{"log":"[02:29:54 INF] Executing HttpStatusCodeResult, setting HTTP status code 200\n","stream":"stdout","time":"2021-01-07T02:29:54.541791463Z"}
{"log":"[02:29:54 INF] Executed action OpenAlprWebhookProcessor.WebhookProcessor.WebhookController.Post (OpenAlprWebhookProcessor) in 3280.8168ms\n","stream":"stdout","time":"2021-01-07T02:29:54.554349608Z"}
{"log":"[02:29:54 INF] Executed endpoint 'OpenAlprWebhookProcessor.WebhookProcessor.WebhookController.Post (OpenAlprWebhookProcessor)'\n","stream":"stdout","time":"2021-01-07T02:29:54.558171031Z"}
{"log":"[02:29:54 INF] HTTP POST /webhook responded 200 in 3586.9490 ms\n","stream":"stdout","time":"2021-01-07T02:29:54.564168969Z"}
{"log":"[02:29:54 INF] Request finished in 3619.9942ms 200 \n","stream":"stdout","time":"2021-01-07T02:29:54.571667345Z"}
{"log":"[02:29:58 INF] clearing expired overlay for: 254963574\n","stream":"stdout","time":"2021-01-07T02:29:58.990527255Z"}
 
Less traffic in front of the house now but as soon as I get a "hit" i'll let you know.