Skip to content

Test data generation script #3

@andrewyager

Description

@andrewyager

We need to be able to better generate test data than using the static import currently contained in this image. This is relevant for testing a bunch of follow-on services being built with this image.

What I'd like to see is a script that takes the following parameters:

  • username
  • password
  • start date for data
  • end date for data (can be null)
  • total amount of data to be used in this period in Gigabytes(?)

and then creates:

  • A radius user with these parameters (User-name and Cleartext-Password) in radcheck table, and in the userinfo table
  • A RADIUS session in the SQL database matching these details
  • A linear allocation of the data by hour into the user_data table during this period

This would need to pay attention to whether the summarise-data cron job would "clobber" the data for today when it runs, and if so, it might need to actually insert rows into the user_stats table as well and then maybe run the summarise script. When the row is inserted into the radacct table, it is going to trigger the user_stats table unless DISABLE_TRIGGERS is set to false (as per the current load_test_data.sql script). I guess we should deal with this like that.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions