Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Source section to dashboard job details #2383

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

epenet
Copy link

@epenet epenet commented Mar 22, 2024

Currently there is no easy way to see what was extracted from the database.

We have three separate projects sharing a common abstraction dll:

  • one which creates jobs
  • one which runs jobs
  • one with the dashboard

We had an issue in which the job abstraction dll was out of date on the dashboard project and this caused great confusion as the description as the top did not match the content of the database due to deserialization/serialization using an older schema.

@odinserj
Copy link
Member

Hm, can you share some more details about the issue you had before proceeding to the next steps?

odinserj added a commit that referenced this pull request Mar 28, 2024
@epenet
Copy link
Author

epenet commented Mar 28, 2024

It's kind of hard to describe, so hopefully this makes sense.

We have two dlls:

  • BackgroundTask.Abstractions.dll
    • it contains a settings class JobSettings, a job interface IJob with a method IJob.Do(JobSettings settings)
    • v1 had a JobSettings.WorkflowID property to pass in a single integer
    • v2 removed this property to replace it with JobSettings.WorkflowIDList property to pass in a list of integers
  • BackgroundTask.Runner.dll has a Job class that implements the IJob interface

We have the following scenario:

  • Server 1 (latest versions) was used to create a job with JobSettings.WorkflowIDList = [1,2,3].
  • Server 2 (latest versions) was used the run the job, but sadly it failed for an unknown reason... which needs investigating.
  • Server 3 (obsolete versions) was used to instigate the failure via the dashboard. When we open the job details, the argument is displayed as {"WorkflowID": null}

We were very very confused and we spent a long time investigating Server 1 to understand why the argument was being passed wrong. Why did it seem to be using an older version of the abstraction dll when it had been correctly updated?
After a while we decided to check the database, and we found that in the database, the argument was correctly set to ["{\"WorkflowIDList\": [1, 2, 3]}"]

That's when we (finally) understood that the issue was not on Server 1 creating the job with wrong settings, but instead with Server 3 displaying settings that were not in the database.

This patch adds a display for the raw database settings, which may or may not match the arguments displayed in the top section.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants