This document applies to FastGPT v4.17.0.
What this category's data looks like
Data for this category comes from steel coil labels and quality certificates, press and feeder operation data, mold management systems, MES systems, and coordinate measuring machine or fixture inspection reports. Daily ledger documents include stamping work instructions, material utilization rate sheets, mold inspection sheets, first and last piece records, dimensional inspection reports, and mold change records. Data updates occur for each steel coil, each production batch, and each mold change operation. Fields include coil number, material, sheet thickness (mm), steel coil weight (t), stamping times, single stamping pressure (kN), mold number, mold change time, part dimensional deviation (mm), and more. Some documents include unstructured handwritten inspection records.
Constraints on database and operations maintenance
The multi-source heterogeneous data sources, high-frequency update rhythm, multiple document types, and structured fields with units for this category create multiple constraints for database and operations maintenance. Differences in data formats across multi-source equipment, MES, and quality inspection systems require the database to support both structured and unstructured storage. High-frequency updates for steel coils, production batches, and mold changes require support for high-concurrency writes and low-latency queries. Mixed storage of multiple ledger document types requires reasonable division of database storage roles. Fields with units require strict validation rules to prevent data chaos that disrupts subsequent summary and report generation.
How to configure
| Configuration Item | Recommended Value | Rationale |
|---|---|---|
MONGODB_URI | mongodb://fastgpt:pass@127.0.0.1:27017/fastgpt?authSource=admin | Stores unstructured work instructions, inspection reports, and multi-source device logs |
PG_URL | postgresql://fastgpt:pass@127.0.0.1:5432/fastgpt | Stores structured ledger fields, such as coil number, stamping pressure, part deviation values, and other structured data with units |
DB_MAX_LINK | 20–30 | Adapts to high-frequency write requests from each steel coil and mold change, preventing database connection exhaustion |
REDIS_URL | redis://:pass@127.0.0.1:6379/0 | Caches frequently accessed data such as mold inspection records and mold change times, reducing database query latency |
Three common configuration mistakes
- Phenomenon: A
MongoDB connection failedlog error appears during startup. Cause: Authentication parameters forMONGODB_URIare not configured correctly, or the database port is not open. The database instance storing ledger data cannot be connected. - Phenomenon: Ledger data update delay exceeds a reasonable range. Cause: The
DB_MAX_LINKvalue is too low. Concurrent write requests queue up, and high-frequency update tasks for each steel coil and mold change cannot be processed in a timely manner. - Phenomenon: Inconsistent units appear in structured ledger fields. Cause: Field validation rules are not configured for the standard units of category data. This leads to mixed storage units for the same type of data from different sources.
How to confirm correct configuration
- Run database connection test commands to confirm successful connection to the configured
MONGODB_URIandPG_URLinstances. - Log in to the database management panel in the FastGPT backend to check whether the connection status of each data source is normal.
- Manually import a simulated stamping workshop ledger data set to confirm that corresponding fields can be stored and retrieved correctly.
- View cache monitoring data to confirm that the cache for frequently accessed mold and mold change record data is active.
The values provided are common starting points and should be measured against the reader's own samples.