mirror of
https://github.com/aaronpo97/the-biergarten-app.git
synced 2026-07-16 17:47:22 +00:00
Cleanup user and brewery generation exception logic
This commit is contained in:
@@ -110,9 +110,9 @@ class BiergartenPipelineOrchestrator {
|
||||
void LogResults() const;
|
||||
|
||||
/// @brief Stores generated brewery data.
|
||||
std::vector<GeneratedBrewery> generated_breweries_;
|
||||
std::vector<BreweryRecord> generated_breweries_;
|
||||
|
||||
/// @brief Stores generated user data.
|
||||
std::vector<GeneratedUser> generated_users_;
|
||||
std::vector<UserRecord> generated_users_;
|
||||
};
|
||||
#endif // BIERGARTEN_PIPELINE_INCLUDES_BIERGARTEN_DATA_GENERATOR_H_
|
||||
|
||||
@@ -74,7 +74,7 @@ struct EnrichedCity {
|
||||
/**
|
||||
* @brief Helper struct to store generated brewery data.
|
||||
*/
|
||||
struct GeneratedBrewery {
|
||||
struct BreweryRecord {
|
||||
Location location;
|
||||
BreweryResult brewery;
|
||||
};
|
||||
@@ -86,7 +86,7 @@ struct GeneratedBrewery {
|
||||
* the orchestrator (never LLM-authored) so a downstream auth-account seeding
|
||||
* consumer can register real accounts from the pipeline's SQLite export.
|
||||
*/
|
||||
struct GeneratedUser {
|
||||
struct UserRecord {
|
||||
Location location;
|
||||
UserResult user;
|
||||
std::string email{};
|
||||
|
||||
@@ -53,17 +53,6 @@ struct Location {
|
||||
double longitude{};
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Non-owning brewery location input.
|
||||
*/
|
||||
struct BreweryLocation {
|
||||
/// @brief City name.
|
||||
std::string_view city_name;
|
||||
|
||||
/// @brief Country name.
|
||||
std::string_view country_name;
|
||||
};
|
||||
|
||||
// ============================================================================
|
||||
// Name / Persona Models
|
||||
// ============================================================================
|
||||
|
||||
@@ -33,14 +33,14 @@ class IExportService {
|
||||
*
|
||||
* @param brewery Generated brewery payload to store.
|
||||
*/
|
||||
virtual uint64_t ProcessRecord(const GeneratedBrewery& brewery) = 0;
|
||||
virtual uint64_t ProcessRecord(const BreweryRecord& brewery) = 0;
|
||||
|
||||
/**
|
||||
* @brief Persists one generated user record.
|
||||
*
|
||||
* @param user Generated user payload to store.
|
||||
*/
|
||||
virtual uint64_t ProcessRecord(const GeneratedUser& user) = 0;
|
||||
virtual uint64_t ProcessRecord(const UserRecord& user) = 0;
|
||||
|
||||
/// @brief Finalizes the export destination.
|
||||
virtual void Finalize() = 0;
|
||||
|
||||
@@ -30,8 +30,8 @@ class SqliteExportService final : public IExportService {
|
||||
SqliteExportService& operator=(SqliteExportService&&) = delete;
|
||||
|
||||
void Initialize() override;
|
||||
uint64_t ProcessRecord(const GeneratedBrewery& brewery) override;
|
||||
uint64_t ProcessRecord(const GeneratedUser& user) override;
|
||||
uint64_t ProcessRecord(const BreweryRecord& brewery) override;
|
||||
uint64_t ProcessRecord(const UserRecord& user) override;
|
||||
void Finalize() override;
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user