Production Ledger Summary and Report Generation for Battery PACK and Energy Storage System Integration: Database and Operations Maintenance

The production ledger data for this category is sourced from cell capacity grading data, MES systems, welding equipment, torque tools, BMS software

What the data for this category looks like

The production ledger data for this category is sourced from cell capacity grading data, MES systems, welding equipment, torque tools, BMS software version records, and EOL test bench test data. Data updates occur once per battery pack or energy storage cabinet, and each BMS software version change will also trigger an update. Daily associated documents include grouping rules, BOM lists, welding torque records, BMS flashing logs, insulation and voltage withstand reports, EOL test reports, and system configuration lists. Data fields include cell voltage, capacity, torque value, insulation resistance, BMS version number, and more, with corresponding units of mV, Ah, N·m, MΩ, and version number.

Constraints for Database and Operations Maintenance

Multiple heterogeneous data sources require the database to support both structured ledger storage and unstructured document storage, and adapt to data formats from different devices and systems. High-frequency updates per battery pack or cabinet require stable database connections to prevent ledger loss from connection interruptions. Diverse field units require unified format parsing at the database layer to avoid chaotic data storage. In addition, abnormal production ledgers may lead to serious consequences such as thermal management failure and system shutdown. Database operations maintenance must include high-availability mechanisms and rapid recovery capabilities, as well as regular full backups of production data.

Configuration Settings

Configuration ItemRecommended ValueRationale
MONGODB_URImongodb://fastgpt:********@192.168.1.100:27017/fastgpt?authSource=adminStores unstructured production documents such as insulation and voltage withstand reports and BMS flashing logs, adapting to multi-type file storage needs
PG_URLpostgresql://fastgpt:********@192.168.1.101:5432/fastgptStores structured ledger data such as cell grouping parameters, welding torque records, and EOL test results, supporting complex conditional queries
DB_MAX_LINK20–30 个Adapts to high-frequency update connection requirements for single batches, avoiding request queuing due to insufficient connections, while not exceeding the default connection limit of most databases
REDIS_URLredis://192.168.1.102:6379/0Caches frequently accessed grouping rules and BOM list data, reducing repeated database query pressure and improving response speed

Three Common Configuration Mistakes

  • Database connection failure, with logs showing connection refused or authentication failed. This occurs when the username, password, host, or port in MONGODB_URI or PG_URL is incorrectly configured, or when firewall rules for external database access are not opened.
  • Uploaded production documents cannot be retrieved via the interface. This happens when only the file body is stored in object storage, and file metadata is not saved to MongoDB. This prevents association of ledger data via FastGPT's knowledge base retrieval function.
  • Database connection limit exceeded, with logs showing a too many connections error. This occurs when the DB_MAX_LINK setting value is higher than the maximum number of connections allowed by the database, causing concurrent requests to exceed the database's carrying capacity.

How to Verify Successful Configuration

  • Access the FastGPT v4.17.0 system settings page, check the configuration parameters of MONGODB_URI, PG_URL, and REDIS_URL, initiate a connection test, and verify that the return status is normal.
  • Upload a structured CSV file containing cell welding torque records and a PDF file of an insulation and voltage withstand report, and verify that the data is correctly stored in the PostgreSQL database and MongoDB storage bucket respectively.
  • Simulate a ledger update operation for 10 energy storage cabinets in a single batch, and check that the database connection count is within the range set by DB_MAX_LINK, with no timeout or connection interruption errors.
  • View the Redis cache monitoring panel, confirm that frequently accessed grouping rule data has been successfully cached, and that access delay meets expected standards.

The values given are common starting points and should be measured against the reader's own samples.