CN116466895A - Vehicle storage management system and method and vehicle - Google Patents

Vehicle storage management system and method and vehicle Download PDF

Info

Publication number
CN116466895A
CN116466895A CN202310524751.2A CN202310524751A CN116466895A CN 116466895 A CN116466895 A CN 116466895A CN 202310524751 A CN202310524751 A CN 202310524751A CN 116466895 A CN116466895 A CN 116466895A
Authority
CN
China
Prior art keywords
storage
capacity
vehicle
service
module
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310524751.2A
Other languages
Chinese (zh)
Inventor
马强
王波
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanghai Jidu Automobile Co Ltd
Original Assignee
Shanghai Jidu Automobile Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shanghai Jidu Automobile Co Ltd filed Critical Shanghai Jidu Automobile Co Ltd
Priority to CN202310524751.2A priority Critical patent/CN116466895A/en
Publication of CN116466895A publication Critical patent/CN116466895A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0604Improving or facilitating administration, e.g. storage management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0629Configuration or reconfiguration of storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/0644Management of space entities, e.g. partitions, extents, pools
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/067Distributed or networked storage systems, e.g. storage area networks [SAN], network attached storage [NAS]
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The application provides a vehicle storage management system and method and a vehicle. The storage management system of the vehicle includes: the application program interface layer is used for performing access operation on service data generated by a plurality of service modules of the vehicle; the capacity configuration module is used for configuring a plurality of storage spaces corresponding to the plurality of service modules one by one according to the storage spaces of the storage equipment of the vehicle, the plurality of storage spaces are respectively used for storing service data generated by the plurality of service modules, acquiring capacity information corresponding to the plurality of storage spaces from the capacity management module, and adjusting the plurality of storage spaces according to the capacity information corresponding to the plurality of storage spaces; the capacity management module is used for scanning the plurality of storage spaces and monitoring capacity information corresponding to the storage spaces according to the scanning result; and the database management module is used for managing the business data generated by the business modules based on the database. The embodiment of the application is beneficial to reasonably and dynamically configuring a plurality of storage spaces.

Description

Vehicle storage management system and method and vehicle
Technical Field
The present application relates to the field of vehicle technologies, and in particular, to a storage management system and method for a vehicle, and a vehicle.
Background
With the development of vehicle intellectualization, a large number of service modules, such as a digital video recorder, a sentry mode and the like, are arranged in the vehicle, and generate a large amount of service data. Therefore, it is necessary to consider how to store these service data so as to better function as each service module.
Disclosure of Invention
The embodiment of the application aims at providing a vehicle storage management system and method and a vehicle. Various aspects related to embodiments of the present application are described below.
In a first aspect, there is provided a storage management system of a vehicle, comprising: the system comprises an application program interface layer, a capacity configuration module, a capacity management module and a database management module, wherein the application program interface layer is used for being connected with a plurality of service modules of the vehicle and used for performing access operation on service data generated by the service modules; the capacity configuration module is used for acquiring the storage space of the storage device of the vehicle, configuring a plurality of storage spaces corresponding to the plurality of service modules one by one according to the storage space of the storage device, acquiring capacity information corresponding to the storage spaces from the capacity management module, adjusting the storage spaces according to the capacity information corresponding to the storage spaces, and storing service data generated by the service modules; the capacity management module is connected with the capacity configuration module and is used for scanning the storage spaces and monitoring capacity information corresponding to the storage spaces according to scanning results, wherein the capacity information comprises used capacity information and residual capacity information of the storage spaces; the database management module is used for managing service data generated by the service modules based on a database.
Optionally, the capacity management module is used for monitoring whether the vehicle is connected with the external storage device or not through a first scanning thread; when the vehicle is connected with the external storage device and the external storage device meets a preset condition, the capacity management module is used for returning to an external storage path, wherein the external storage path is a path for storing service data generated by the plurality of service modules to the external storage device; when the vehicle is not connected with the external storage device, the capacity management module is used for returning to an internal storage path, and the internal storage path is a path for storing service data generated by the service modules to the internal storage device.
Optionally, the capacity management module is used for creating a plurality of capacity scanning threads corresponding to the plurality of service modules one by one; scanning a plurality of storage spaces corresponding to the service modules by using the capacity scanning threads, and sending capacity information corresponding to the storage spaces to the capacity configuration module; the capacity configuration module is further used for storing the capacity information of the storage spaces into a memory of the vehicle to form a memory snapshot; storing the memory snapshot to a local storage device of the vehicle to form a local snapshot; and after the storage management system is restarted, determining the capacity information corresponding to each of the storage spaces according to the local snapshot.
Optionally, the capacity configuration module is further configured to configure a shared storage space for remaining service modules of the vehicle except for the plurality of service modules; and under the condition that capacity information corresponding to the plurality of storage spaces meets a second adjustment condition, configuring partial spaces in the shared storage space for the plurality of service modules, wherein the partial spaces are used for storing service data generated by the plurality of service modules.
Optionally, the storage management system includes a generic layer, connected to the application program interface layer, the database management module, and the capacity configuration module, for implementing data interaction between the database management module and/or the capacity configuration module and the application program interface layer.
Optionally, the service data includes an urgent video and a non-urgent video, the database includes a first database table and a second database table, the first database table is used for storing a file name and a file access path corresponding to the urgent video, the second database table is used for storing a file name and a file access path corresponding to the non-urgent video, and the database management module is used for judging the types of the current service data generated by the plurality of service modules; if the type of the current service data belongs to an emergency video, storing a file name and a file access path corresponding to the current service data into the first database table; and if the type of the current service data belongs to the non-emergency video, storing the file name and the file access path corresponding to the current service data into the second database table.
Optionally, the database management module is further configured to store the service data in the multiple storage spaces and/or capacity information corresponding to each of the multiple storage spaces into a cloud storage.
Optionally, the plurality of service modules include a sentinel module and/or a vehicle recorder, and the capacity management module is further configured to monitor a storage capacity corresponding to the sentinel module when the vehicle is in a parking state; and when the vehicle is in a driving state, monitoring the storage capacity corresponding to the driving recorder.
Optionally, the application program interface layer is configured to perform at least one of the following operations: storing service data; searching service data; deleting service data; and coverage of service data.
In a second aspect, there is provided a storage management method applied to the storage management system as described in the first aspect, the method including: acquiring a plurality of storage spaces corresponding to a plurality of service modules of the vehicle one by one, wherein the storage spaces are configured based on the storage spaces of storage equipment of the vehicle, and the storage spaces are respectively used for storing service data generated by the service modules; scanning the storage spaces, and monitoring capacity information corresponding to each storage space according to a scanning result, wherein the capacity information comprises used capacity information and residual capacity information of the storage space; and adjusting the storage spaces according to the capacity information corresponding to the storage spaces.
In a third aspect, there is provided a vehicle comprising: a plurality of business modules; the storage management system according to the first aspect, configured to manage service data generated by the plurality of service modules.
In a fourth aspect, a computer program product is provided, comprising a computer program/instruction which, when executed by the computer program/instruction processor, implements the storage management method of any of the second aspects.
In some implementations, the computer program product described above includes computer program code that can include computer program code that, when run on a computer, causes the computer to perform the storage management method as shown in the second aspect.
In other implementations, the computer program product includes a computer readable medium storing program code which, when run on a computer, causes the computer to perform the storage management method as shown in the second aspect.
According to the embodiment of the application, a plurality of storage spaces corresponding to the service modules one by one are configured according to the storage spaces of the storage equipment of the vehicle, service data generated by the service modules are respectively stored in the corresponding storage spaces, and capacity information corresponding to the storage spaces is monitored. The embodiment of the application is beneficial to reasonably and dynamically configuring a plurality of storage spaces for each service module, and the functions of each service module are better played.
Drawings
Fig. 1 is a schematic diagram of a storage management system of a vehicle according to an embodiment of the present application.
FIG. 2 is a schematic diagram of one possible implementation of the storage management system of FIG. 1.
Fig. 3 is a flow diagram of one possible implementation of the capacity allocation module 230 of fig. 2.
Fig. 4 is a schematic diagram of one possible implementation of the capacity management module 240 of fig. 2.
Fig. 5 is a schematic diagram of one possible implementation of the database management module 250 of fig. 2.
Fig. 6 is a flow chart of a storage management method according to an embodiment of the present application.
Detailed Description
The following description of the technical solutions in the embodiments of the present application will be made clearly and completely with reference to the drawings in the embodiments of the present application, and it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments.
Intelligent driving and safety monitoring of vehicles have been attracting attention, and along with the development of vehicle intellectualization, many vehicle control systems integrate digital video recorders, sentry modes and other functions.
Digital video recorders (digital video recorder, DVR), also known as hard disk recorders, use hard disk recordings as opposed to traditional analog video recorders. A DVR is a device mounted on a car to photograph a plurality of angles. The DVR uses advanced video and audio coding and decoding technology to carry out digital-to-analog conversion and compression storage on videos inside and outside the automobile. Some vehicles' DVRs may also perform GPS positioning, vehicle-mounted entertainment playback, wireless network transmission, etc. The DVR can record related information such as images and sounds during the running of the vehicle, record video images and sounds during the whole running process of the vehicle, provide evidence for traffic accidents, reduce disputes and the like.
The sentinel mode refers to the fact that after a specified area is parked and locked, the system automatically monitors suspicious activity around the vehicle. When suspicious behavior is detected, the vehicle will react according to the severity of the threat. If a serious threat is detected, the vehicle camera will begin recording video and activate the alarm system. The mobile phone application of the vehicle will send a message to alert the user that an accident may occur.
Typically, the file data generated by the digital video recorder or the sentinel mode is stored in an on-board external memory, such as a usb disk, a Secure Digital (SD) card, etc. Taking a USB flash disk as an example, the USB flash disk is connected with a vehicle-mounted system by adopting a universal serial bus (universal serial bus, USB). USB is an external bus standard for standardizing the connection and communication of a computer with external devices.
The digital video recorder and the sentry mode are usually recorded circularly, for example, a 128G USB flash disk is used, if the vehicle is in the sentry mode, the video file stored first in the sentry mode can be automatically covered and deleted to continue recording after the vehicle is fully stored, and the process is repeated. The USB flash disk can be taken down, and data on the USB flash disk can be backed up to other electronic equipment.
In some vehicles, if the usb flash disk is not inserted, the sentinel mode may receive a notification on the mobile APP when entering the alarm state, but no video recording is performed, and the key video data may be lost.
With the development of vehicle intellectualization, video data generated by service modules such as a digital video recorder and a sentinel mode occupy a larger space, and the storage space of a plurality of service modules such as the sentinel mode is not reasonably configured to influence the functions of the vehicle service modules, so that the intellectualization of the vehicle is influenced.
Therefore, how to develop a reasonable vehicle-mounted file storage management scheme is a problem to be solved.
Based on this, the embodiment of the application proposes a storage management system of a vehicle. Fig. 1 is a schematic flow chart of a storage management system of a vehicle according to an embodiment of the present application. The storage management system of the vehicle of fig. 1 may be a storage management system under a single operating system, which may be, for example, an android (android) system. The storage management system of the vehicle of fig. 1 may also be configured as a storage management system under a dual operating system, which may be, for example, an android system and a Linux system. The following describes in detail a storage management system of a vehicle according to an embodiment of the present application with reference to fig. 1. As shown in fig. 1, the storage management system 100 of the vehicle may include an application program interface layer 110, a capacity configuration module 120, a capacity management module 130, and a database management module 140.
The application program interface layer 110 may be connected to a plurality of service modules of the vehicle, and is configured to perform access operation on service data generated by the plurality of service modules of the vehicle. The application program interface layer 110 is provided with an application program interface through which an application program can interact with service data of a plurality of service modules.
In some implementations, the application program interface may be used to perform at least one of the following operations: storing service data; searching service data; deleting service data; and coverage of service data. I.e. the application program interface may be used to perform CRUD operations. CRUD refers to add (Create), read, update, and Delete (Delete) operations at the time of the computing process, and is primarily used to describe the basic operational functions of a database or persistence layer in a software system. The file information aiming at the service module can be uniformly written into the database to uniformly manage the related information of the file, so that the searching of the file can be uniformly operated on the database, and the searching speed is increased.
The capacity configuration module 120 is connected to the application program interface layer 110, and is configured to obtain a storage space of a storage device of the vehicle, and configure a plurality of storage spaces corresponding to the plurality of service modules one by one according to the storage space of the storage device. The storage spaces are respectively used for storing service data generated by the service modules, the service modules are all in a system self-starting mode, and the service data are stored in a cyclic coverage mode based on preset rules.
The storage devices of the vehicle may include an internal storage device and an external storage device. Internal storage devices such as memory, cache, hard disk, etc. of the storage management system; external storage devices such as SD cards, USB discs connected through USB interfaces, and the like. The internal storage device and the external storage device of the vehicle are collectively referred to as a local storage device. The storage capacity or storage space, the storage space of the storage device or storage capacity of the storage device, which is not differentiated by the embodiments of the present application. The storage space of the storage device may include total space, used space, remaining space, and the like.
The plurality of service modules may refer to service modules that generate multimedia data such as video, pictures, etc. The plurality of business modules may include a sentinel mode module, a vehicle recorder, etc., wherein the sentinel mode module may be referred to as a sentinel module for short. The video data generated by the service module is typically streaming data. The streaming data may include at least one group of pictures (group of pictures, GOP), one GOP including one I frame, a plurality of B frames, and a plurality of P frames.
The plurality of service modules of the vehicle are usually operated in a background service mode after the system is started, namely a system self-starting mode.
The plurality of service modules can be configured as storage spaces with the same capacity or as storage spaces with different capacities. For example, according to the storage space of the storage device, a plurality of storage spaces corresponding to a plurality of service modules of the vehicle one by one can be configured according to a certain proportion relation. Generally, the larger the storage space of the storage device, the larger the configuration storage space corresponding to the plurality of service modules.
The capacity allocation module 120 may perform customized capacity allocation for a plurality of service modules for different storage spaces. For example, when the total storage space of the storage device is 10G and the remaining storage space is 6G, the storage space of the sentinel module may be configured to be 2G and the storage space of the automobile data recorder module may be configured to be 3G.
In some implementations, the capacity of the plurality of service modules may be configured for different sizes of storage space, and the capacity of the plurality of service modules may have different scale setting ranges for different storage space ranges. For example, when the total storage space is 10G or less, the storage space configuration ratio of the sentinel module and the automobile data recorder may be 1:2; when the total storage space is 10G-20G, the storage space configuration ratio of the sentinel module and the automobile data recorder can be 1:3.
The capacity allocation module 120 may allocate a plurality of storage spaces corresponding to a plurality of service modules of the vehicle one by one according to the storage spaces of the storage devices and the type information of the service modules. For example, in some implementations, where the vehicle is often in a sentinel mode for a period of time, the memory space corresponding to the sentinel module may be configured to be larger in order to store more video files, increase the cycle coverage period of the files, help to improve the resolution of the video data, and so on. In some embodiments, the vehicle is in a driving state for a long time, and the storage space corresponding to the automobile data recorder can be configured to be larger.
In some embodiments, after the system is started, the capacity configuration module 120 may pre-configure a plurality of storage spaces corresponding to a plurality of service modules of the vehicle one-to-one according to the total storage space, the remaining storage space and the used storage space of the storage device. And respectively storing the service data generated by the service modules into the corresponding storage spaces according to the preconfigured storage spaces. For example, the service data such as the video and the picture generated by the sentry module are stored in the storage space corresponding to the sentry module, and the service data such as the video and the picture generated by the automobile data recorder are stored in the storage space corresponding to the automobile data recorder.
The service data generated by the plurality of service modules is typically video data that is stored continuously in time order. The storage of the service data is cyclic coverage storage based on preset rules. The loop overlay storage is alternatively referred to as loop overlay, loop delete. The service data file (video) with the longest storage date can be deleted first by circularly overlaying storage, and the service data file with the longest file number can be deleted first. The preset rule may be to delete the service data with the longest storage date first, or delete the service data with the longest file number first. The cyclic coverage storage based on the preset rule may be cyclic coverage according to a certain period of time, or cyclic coverage may be performed according to a certain capacity.
For example, in the manner of performing the cyclic coverage according to the capacity, when the remaining capacity of the service module is smaller than the corresponding remaining capacity threshold, the newly generated service data may be stored in the manner of the cyclic coverage. In some implementations, the cyclic overlay may also delete only the service data (video) of the lowest security level that is the longest in storage date, and not the service data of the higher security level, taking into account the different security levels of the service data.
And if the residual capacity of the storage space corresponding to the service module is smaller than the corresponding residual capacity threshold value, performing cyclic coverage based on a preset rule on the newly generated service data.
During normal operation of the system, the plurality of memory spaces of the plurality of business modules, which correspond one-to-one, are typically no longer changed. In some embodiments, after the system is restarted, the multiple storage spaces corresponding to the multiple service modules one to one may be reconfigured according to the total storage space, the remaining storage space, the used storage space information, and the preset adjustment conditions of the storage device.
The capacity management module 130 is connected to the capacity configuration module 120, and the capacity management module 130 is configured to scan a plurality of storage spaces; and monitoring capacity information corresponding to each of the plurality of storage spaces according to the scanning result, wherein the capacity information comprises used capacity information and residual capacity information of the storage spaces.
The capacity information of the storage space corresponding to each of the plurality of service modules is obtained through scanning, so that the capacity service conditions of the plurality of service modules, such as the information of service time, total capacity, used capacity, residual capacity, the duty ratio of the used capacity to the total capacity and the like, can be obtained.
The capacity configuration module 120 is further configured to obtain capacity information corresponding to each of the plurality of storage spaces from the capacity management module 130, and adjust the plurality of storage spaces according to the capacity information corresponding to each of the plurality of storage spaces.
The database management module 140 is connected to the application program interface layer 110, and is configured to manage service data generated by a plurality of service modules based on a database.
According to the embodiment of the application, the capacity information corresponding to the storage spaces is monitored, and the storage spaces can be reasonably and dynamically configured. The method is beneficial to reasonably configuring the storage spaces corresponding to the service modules, and the functions of the service modules are better played.
The capacity of the internal memory of the vehicle is typically fixed, limited, and the vehicle is typically also connectable to external storage devices, such as a USB flash disk. The external storage device is large in storage capacity and extensible, such as a USB flash disk, is in quick plug connection, and is convenient for copying and outputting service data. The system can perform unified storage management on the external storage device and the internal storage device.
Before configuring storage spaces corresponding to a plurality of business modules, it is generally necessary to calculate the storage space of the storage device of the vehicle. In some implementations, the capacity configuration module 120 is to: monitoring whether the vehicle is connected with an external storage device; and if the vehicle is in a connection state with the external storage device, acquiring a storage space from the external storage device, and taking the external storage device as a target storage area of the service modules. And if the vehicle is in a disconnected state with the external storage device, acquiring the storage space from the internal storage device of the vehicle, and taking the internal storage device as a target storage area. The external storage device is also used for backing up high-priority data in the service data stored by the internal storage device, so that unified processing of the external storage device and the internal storage device of the vehicle is facilitated.
In some implementations, the capacity management module 130 may employ the same scanning thread for scanning multiple storage spaces, or may employ different scanning threads. In some embodiments, one scanning thread may be independently turned on for each business module. For example, different threads are adopted to scan the storage spaces corresponding to the sentry modules and the automobile data recorder, so that mutual interference among different service modules can be reduced to the greatest extent, and more system resources can be occupied. In some embodiments, the number of scanning threads can be dynamically adjusted, so as to achieve better cost performance according to the actual conditions of the system load and the service modules. Such schemes typically require some scheduling policy and algorithm support.
In some implementations, the capacity management module 130 is configured to monitor, via the first scanning thread, whether the vehicle is connected to an external storage device; if the vehicle is connected with the external storage device, judging whether the external storage device meets the preset condition; when the vehicle is connected with the external storage device and the external storage device meets a preset condition, the capacity management module 130 is configured to return to an external storage path, where the external storage path is a path for storing service data generated by a plurality of service modules to the external storage device; if the vehicle is not connected to an external storage device, the capacity management module 130 is configured to return an internal storage path, which is a path for storing service data generated by a plurality of service modules to the internal storage device. The preset condition may be that the external storage device (USB device) is an external storage device authenticated by the vehicle, or that the external storage device is a USB device that meets the authentication requirement of the vehicle, or that the capacity of the external storage device meets the minimum capacity requirement. The preset conditions are not particularly limited in the embodiment of the present application.
In some implementations, the capacity management module 130 is configured to create a plurality of capacity scan threads that are in one-to-one correspondence with the plurality of traffic modules; and scanning a plurality of storage spaces corresponding to the service modules by using a plurality of capacity scanning threads respectively, and sending capacity information corresponding to the storage spaces to the capacity configuration module 120. For example, a folder and a scanning thread for storing video data can be generated according to whether a USB is inserted and provided service module list (sentinel/DVR) information, and then up-summarizing is performed according to service data scanned by different service threads, so as to collect total storage space, used storage space, residual storage space and the like of each service module.
After the storage management system is restarted, a certain amount of resources and time are generally consumed for calculating the storage space of the storage device, and then a plurality of storage spaces corresponding to a plurality of service modules of the vehicle one by one are configured. The larger the storage space of the storage device, the more used space the service data occupies, generally the longer the computation time.
In some implementations, the capacity configuration module 120 is further configured to store capacity information of the plurality of storage spaces into a memory of the vehicle to form a memory snapshot; and storing the memory snapshot to a local storage device of the vehicle, such as a hard disk, to form the local snapshot. After the storage management system is restarted, the capacity information corresponding to each of the storage spaces is determined according to the memory snapshot (or the local snapshot). This helps to reduce the storage space computation time of the storage device, providing response timeliness and efficiency of the storage management system.
The memory snapshot, as the name implies, takes a picture of the memory, records the data in the memory at a certain moment, and saves the data on the hard disk in the form of a file. The memory snapshot may be updated periodically to the local storage device, e.g., the memory snapshot may be updated to the local hard disk before the storage management system shuts down.
The capacity configuration module 120 is further configured to adjust the plurality of storage spaces according to the capacity information and the first adjustment condition corresponding to each of the plurality of storage spaces.
The first adjustment condition may be that the change amount of the capacity information of the storage space of the service module exceeds a preset threshold value within a preset time, and capacity adjustment is required after the first adjustment condition is satisfied. For example, the first adjustment condition may be that a change amount of the used capacity information of the storage space of the service module exceeds a preset threshold, or that a change amount of a ratio of the used capacity information to the total capacity information exceeds a preset threshold. For example, in the historical preset time, if the change amount of the used capacity information of the storage space of the automobile data recorder module exceeds the preset threshold, that is, the first adjustment condition is satisfied, the storage space of the automobile data recorder module can be adjusted. If the ratio variation of the used capacity to the total capacity of the storage space of the automobile data recorder module is 80% within a preset time (one week), and exceeds a preset threshold value of 70%, that is, the first adjustment condition is satisfied, the storage space of the automobile data recorder module can be reset, and the corresponding storage space configuration of the automobile data recorder module can be increased.
The database management module 140 manages service data generated by a plurality of service modules based on a database. Databases refer to software systems used in computer systems to organize, store, and manage data. Databases typically occupy a certain amount of memory space and require management and optimization to ensure the performance and reliability of the database. Scanning and monitoring of the storage space helps to ensure adequate and reasonable utilization of the storage space. First, the scanning and monitoring of storage space may help identify and free up unnecessary storage space, thereby providing more space for the database. Secondly, the management and optimization of the database needs to consider the use condition of the storage space, including the allocation, backup, recovery and the like of the storage space.
The storage management system 100 may manage service data generated by the plurality of service modules based on a database. The database management module 140 may perform the following operations: receiving a query request, wherein the query request is used for querying target service data from service data generated by a plurality of service modules; and responding to the query request, and searching the target service data through the database. The target business data may be, for example, video file data, image file data, or event information at a time in the sentinel module.
In some implementations, the storage management system 100 may include a common layer. The generic layer is connected to the application program interface layer 110, the database management module 140 and the capacity configuration module 120, and is used for implementing data interaction between the database management module 140 and/or the capacity configuration module 120 and the application program interface layer 110. The generic layer may include one or more of the following functions: generating a service module catalog, acquiring a service module path, storing pre-verification, acquiring a service module data table, deleting coverage judgment, generating an ID (identity) strategy and the like.
In some implementations, the storage management system 100 performs unified management encapsulation, identification, and parsing of the business data. The main process may include the steps of:
and (3) packaging: the storage management system may provide a uniform (universal) package format for the service data, such as MP4, AVI, etc., for use by different applications. The application may package the business data into this generic format. And (3) identification: the encapsulation format of the service data may be identified, for example, by checking header information of the service data. Different processing modes can be provided for data in different formats. Analysis: the storage management system can perform corresponding analysis according to the format of the service data. For example, for MP4 format video data, information such as audio, video, subtitles, etc. may be parsed to facilitate playing or editing. Through these steps, the storage management system 110 can uniformly manage service data in different formats and provide a uniform interface for application programs, thereby improving the usability and expandability of the data.
Traffic data may be classified into a number of different priorities, high priority data or data known as high security level, high threat level data. In some implementations, video data generated in the sentinel mode may be classified into several levels, such as alert, alarm, severe threat (alert), for example, according to threat level. For example, the safety level of people depending on the car body and scraping the car can be a warning level, and illegal intrusion into the car can be a serious threat level.
In some implementations, the vehicle is not connected to the external storage device at first, the spaces of the service modules are set in the internal storage device, and the service data generated by the service modules are stored in the corresponding storage spaces of the internal storage device. And then, the connection of the vehicle and the external storage device is monitored, the external storage device is used as a target storage area of a plurality of service modules, and a plurality of storage spaces corresponding to the service modules of the vehicle one by one are reconfigured. Typically, the internal storage device has stored thereon a portion of the traffic data. In some embodiments, the important file data of the business module on the internal storage device may be copied to the external storage device, such as storing the high priority (high threat level) video data of the sentinel module to the U disk, and deleting the remaining business data. In some embodiments, the service data of the service module on the internal storage device may be deleted directly.
For example, when an external storage device (U disk) is not connected, video with illegal invasion is stored in the internal storage device; after the external storage device is connected, the illegal intrusion video stored in the internal storage device can be dumped to the external storage device. Thus, the method is beneficial to reducing the storage space occupied by the internal storage device and can also backup the service data with high security level.
In some implementations, the capacity configuration module 120 is further configured to configure, on a storage device of the vehicle, a shared storage space for remaining service modules of the vehicle other than the plurality of service modules; and storing the service data of the rest service modules into the shared storage space. And according to the capacity information and the second adjustment condition corresponding to each of the plurality of storage spaces, configuring part of the space in the shared storage space into the plurality of storage spaces, wherein the part of the space is used for storing service data generated by the plurality of service modules. The data types generated by the plurality of service modules are not identical to the data types generated by the rest of service modules. The remaining service modules may include, for example, an automatic navigation module, an audio-visual entertainment module, and the like. For example, the automatic navigation module may store video data, voice data, vehicle location information, and the like. The video data and the voice data are usually media stream data. Vehicle location information is typically structured data residing in a record or file in fixed fields, and may include longitude, latitude, altitude, vehicle speed, direction, etc.
The size of the shared memory space or the memory space called shared area or shared area can be adjusted. For example, the adjustment may be made according to the storage space of the storage device; the adjustment may also be performed according to the storage space of the storage device, the total storage space corresponding to the plurality of service modules, the remaining storage space information, and the like.
The second adjustment condition may be that a ratio of the plurality of storage spaces to the shared storage space is lower than a ratio threshold, which may be 8:2, for example. The second adjustment condition may be that a ratio of a change amount of the plurality of storage spaces to a change amount of the shared storage space within a predetermined time exceeds a ratio threshold, and the ratio threshold may be 8:2, for example. For example, when the target storage space is switched from the external storage device to the internal storage device, the total storage space becomes smaller, the ratio of the plurality of storage spaces to the shared storage space becomes 5:2, and the ratio is lower than the ratio threshold value 8:2, that is, the second adjustment condition is satisfied. According to the capacity information and the second adjustment condition corresponding to each of the plurality of storage spaces, a part of the space in the shared storage space may be arranged in the plurality of storage spaces. The shared memory space may be used to dynamically increase the multiple memory spaces of multiple business modules. For example, when the traffic data volume of the plurality of storage spaces increases rapidly within the predetermined time, but the shared storage space does not change, the ratio of the amount of change of the plurality of storage spaces to the amount of change of the shared storage space is 10:1, and exceeds the ratio threshold value of 8:2, that is, the second adjustment condition is satisfied, a part of the space in the shared storage space may be configured in the plurality of storage spaces.
In some embodiments, the videos generated by the business module may be divided into emergency videos and non-emergency videos. Non-emergency video may also be understood as cyclic video. For example, the video data with high threat level in the event data recorder and the sentry mode may be urgent video, and the video data with low threat level may be non-urgent video.
In some implementations, the database that manages the business data generated by the plurality of business modules described above may include a first database table and a second database table. The first database table may be used to store file names and file access paths corresponding to emergency videos, and the second database table may be used to store file names and file access paths corresponding to non-emergency videos. The first database table and the second database table can enable a user to focus on the content of the emergency video, and the use of the user is convenient.
In some implementations, a first database table and a second database table may also be established separately for each business module. If the sentinel pattern may correspond to a first database table and a second database table, the vehicle event data recorder may also correspond to a first database table and a second database table. I.e. the first database table and the second database table constitute the database of the service module. The first database table may be used to store file names and file access paths corresponding to emergency videos, and the second database table may be used to store file names and file access paths corresponding to non-emergency videos. The method can enable the user to focus on the content of the emergency video, and is convenient for the user to use and the like.
The service data can be video data, and the file names of the video data can be ordered according to storage time or named according to time sequence, so that the video data is convenient to review. A video file may be generated based on threat levels and/or preset times. For example, a non-urgent video may generate one video file for 10 minutes; in the case of a serious threat, a video file may be generated in 3 minutes.
In some implementations, the database management module 140 may be configured to determine a type of current service data generated by the plurality of service modules; if the type of the current service data belongs to the emergency video, storing a file name and a file access path corresponding to the current service data into a first database table; and if the type of the current service data belongs to the non-emergency video, storing the file name and the file access path corresponding to the current service data into a second database table.
In some implementations, the type of current business data generated by the plurality of business modules may also be determined by the application program interface layer 110. And the database management module 140 stores the file name and the file access path corresponding to the current service data into the corresponding database table according to the type of the current service data. For example, if the type of the current service data belongs to the emergency video, storing a file name and a file access path corresponding to the current service data into a first database table; and if the type of the current service data belongs to the non-emergency video, storing the file name and the file access path corresponding to the current service data into a second database table.
The plurality of business modules may include a sentinel module and/or a tachograph. In some implementations, the capacity management module 130 is further configured to monitor a storage capacity corresponding to the sentinel module when the vehicle is in a stopped state; and when the vehicle is in a driving state, monitoring the storage capacity corresponding to the driving recorder.
In some implementations, the database management module 140 is further configured to store capacity information corresponding to each of the plurality of storage spaces in the cloud storage. The capacity information corresponding to each of the plurality of storage spaces may include capacity configuration information corresponding to the storage space, total space, used space, remaining space information, and the like. In this way, even if the memory snapshot is not updated to the local storage device in time before the storage management system is closed, the loss of capacity information corresponding to the plurality of storage spaces can be avoided.
In some implementations, the database management module 140 is further configured to store the business data in the plurality of storage spaces into the cloud storage. For example, video data with high threat level in the sentry mode needs to be uploaded to a cloud storage, so that a user can check the video data in time at the APP end of the mobile phone.
According to the embodiment of the application, a plurality of storage spaces corresponding to the plurality of service modules one by one are configured according to the storage spaces of the storage equipment of the vehicle, service data generated by the plurality of service modules are respectively stored in the plurality of storage spaces, capacity information corresponding to the plurality of storage spaces is monitored, and the plurality of storage spaces can be configured reasonably and dynamically. The embodiment of the application is beneficial to reasonably configuring the storage spaces corresponding to the service modules, and the functions of the service modules are better played.
FIG. 2 is a schematic diagram of one possible implementation of the storage management system of FIG. 1. The storage management system of fig. 2 provides a scheme for simultaneously managing the usb disk and the internal storage device at the vehicle end, and can perform configuration management on the storage space, capacity information monitoring of each service module, management on a database, and the like. Unified API operation can be provided for upper programs to realize functions of storing, searching, deleting, covering and the like of files. The storage management system of the vehicle according to the embodiment of the present application is further described below with reference to fig. 2. As shown in fig. 2, the storage management system 200 of the vehicle may mainly include an application program interface layer 110, a general layer 200, a capacity configuration module 230, a capacity management module 240, and a database management module 250.
The application program interface layer 210 is provided with an application program interface through which an application program can interact with databases of a plurality of service modules.
An Application Program Interface (API) may be used to perform the following operations: generating a catalog, saving videos, saving metadata, searching videos, deleting videos, etc., i.e., an application program interface may be used to perform CRUD operations. The file information aiming at the service module can be uniformly written into the database, and the related information of the file is uniformly managed.
The generic layer 220 is located between the application program interface layer 210 and the database management module 250 for memory access operation interaction between the application program interface layer 210 and the database management module 250. The generic layer 220 may include one or more of the following functions: generating a service module catalog, acquiring a service module path, storing pre-verification, acquiring a service module data table, deleting coverage judgment, generating an ID (identity) strategy and the like.
The capacity configuration module 230 is connected to the application program interface layer 210 through the generic layer 220, and is configured to obtain a storage space of a storage device of the vehicle, and configure a plurality of storage spaces corresponding to the plurality of service modules one by one according to the storage space of the storage device. The storage spaces are respectively used for storing service data generated by the service modules, the service modules are all in a system self-starting mode, and the service data are stored in a cyclic coverage mode based on preset rules.
The plurality of service modules may refer to service modules that generate multimedia data such as video, pictures, etc. The plurality of business modules may include a sentinel mode module, a vehicle recorder, etc., wherein the sentinel mode module may be referred to as a sentinel module for short. The plurality of service modules of the vehicle are usually operated in a background service mode after the system is started, namely a system self-starting mode.
In some implementations, the capacity configuration module 230 may configure a plurality of storage spaces of the vehicle in one-to-one correspondence to a plurality of traffic modules according to the total storage space of the storage devices. In some embodiments, after the system is started, a plurality of storage spaces corresponding to a plurality of service modules of the vehicle one by one may be preconfigured according to the total storage space, the remaining storage space and the used storage space of the storage device. And respectively storing the service data generated by the service modules into the corresponding storage spaces according to the preconfigured storage spaces. For example, the service data such as the video and the picture generated by the sentry module are stored in the storage space corresponding to the sentry module, and the service data such as the video and the picture generated by the automobile data recorder are stored in the storage space corresponding to the automobile data recorder.
The capacity configuration module 230 may configure a plurality of storage spaces of the vehicle corresponding to a plurality of service modules one by one according to the storage spaces of the storage devices and the type information of the service modules. For example, in some implementations, where the vehicle is often in a sentinel mode for a period of time, the memory space corresponding to the sentinel module may be configured to be larger in order to store more video files, increase the cycle coverage period of the files, may increase the resolution of the video data, and so on.
The service data generated by the plurality of service modules is typically video data that is stored continuously in time order. The service data generated by the plurality of service modules is generally stored in a cyclic coverage manner. The cycle overlay storage may be cycled according to a certain period of time, or may be cycled according to a certain capacity.
In some embodiments, after the system is restarted, the multiple storage spaces corresponding to the multiple service modules one to one may be reconfigured according to the total storage space, the remaining storage space, the used storage space information, and the preset adjustment conditions of the storage device.
The capacity configuration module 230 also has a memory snapshot storage function, and stores capacity information of a plurality of storage spaces into a memory of the vehicle to form a memory snapshot; the memory snapshot is stored to a local storage device of the vehicle, such as a hard disk. After the storage management system is restarted, the capacity information corresponding to each of the storage spaces is determined according to the memory snapshot. Thus, the configuration information can be localized so that the storage management system can be reloaded after restarting, which is helpful for reducing the storage space calculation time of the storage device and providing response timeliness and efficiency of the storage management system.
The capacity allocation module 230 is further configured to allocate, on a storage device of the vehicle, a shared storage space for remaining service modules of the vehicle other than the plurality of service modules; and storing the service data of the rest service modules into the shared storage space. And according to the capacity information and the second adjustment condition corresponding to each of the plurality of storage spaces, configuring part of the space in the shared storage space in the plurality of storage spaces. The data types generated by the plurality of service modules are not identical to the data types generated by the rest of service modules. The remaining service modules may include, for example, an automatic navigation module, etc. For example, the automatic navigation module may store video data, voice data, vehicle location information, and the like.
The capacity management module 240 is connected to the capacity configuration module 230, and is configured to scan a plurality of storage spaces; and monitoring capacity information corresponding to each of the plurality of storage spaces according to the scanning result, wherein the capacity information comprises used capacity information and residual capacity information of the storage spaces.
The capacity management module 240 is configured to generate folders and scan threads for storing service data (video data) according to whether the USB is inserted and the provided service module list (sentinel/DVR) configuration information. And then carrying out upward summarization according to the service data scanned by different service threads, and collecting the total storage space, the used storage space, the residual storage space and the storage space information of the shared area of each service module. As shown in fig. 2, the total storage space, the used space, the remaining space information of the storage device of the vehicle may be included, and the used space, the remaining space information, the minimum space, the used space of the shared storage space, the remaining space information, and the like of the automobile data recorder module may be included.
The capacity management module 240 may use the same scanning thread for scanning the plurality of storage spaces, or may use different scanning threads. For example, different scanning threads are adopted to scan the storage spaces corresponding to the sentry modules and the automobile data recorder, so that mutual interference among different service modules can be reduced to the greatest extent.
The capacity configuration module 230 is further configured to adjust the plurality of storage spaces according to the capacity information corresponding to each of the plurality of storage spaces and the first adjustment condition if the capacity information corresponding to each of the plurality of storage spaces satisfies the first adjustment condition. The first adjustment condition may be that the change amount of the capacity information of the storage space of the service module exceeds a preset threshold value within a preset time, and capacity adjustment is required after the first adjustment condition is satisfied. For example, the first adjustment condition may be that a change amount of the used capacity information of the storage space of the service module exceeds a preset threshold, or that a change amount of a ratio of the used capacity information to the total capacity information exceeds a preset threshold.
The database management module 250 is connected to the application program interface layer 210 through the generic layer 220, and manages service data generated by a plurality of service modules based on a database. The database management module 250 may include: API design, data table management, video/event information mapping, video/Internet of vehicles cloud information mapping, video/thumbnail information mapping, video/Robo cloud information mapping and the like.
In some embodiments, the videos generated by the business module may be divided into emergency videos and non-emergency videos. Non-emergency video may also be understood as cyclic video. The file names of the video data may be ordered by storage time. In a cyclic video, the video file stored longest in date is conveniently overlaid in time sequence. For example, the video data with high threat level in the event data recorder and the sentry mode may be urgent video, and the video data with low threat level may be non-urgent video.
In some implementations, the database that manages the business data generated by the plurality of business modules described above may include a first database table and a second database table. The first database table may be used to store file names and file access paths corresponding to emergency videos, and the second database table may be used to store file names and file access paths corresponding to non-emergency videos. The first database table and the second database table can enable a user to focus on the content of the emergency video, and the use of the user is convenient.
In some implementations, a first database table and a second database table may be established separately for each business module. If the sentinel pattern may correspond to a first database table and a second database table, the vehicle event data recorder may also correspond to a first database table and a second database table. I.e. the first database table and the second database table constitute the database of the service module. The first database table may be used to store file names and file access paths corresponding to emergency videos, and the second database table may be used to store file names and file access paths corresponding to non-emergency videos. The method can enable the user to focus on the content of the emergency video, and is convenient for the user to use and the like.
In some implementations, the database management module 250 may be configured to determine a type of current service data generated by the plurality of service modules; if the type of the current service data belongs to the emergency video, storing a file name and a file access path corresponding to the current service data into a first database table; and if the type of the current service data belongs to the non-emergency video, storing the file name and the file access path corresponding to the current service data into a second database table.
After the storage management system is restarted, a certain amount of resources and time are generally consumed for calculating the storage space of the storage device, and then a plurality of storage spaces corresponding to a plurality of service modules of the vehicle one by one are configured. In some implementations, the database management module 250 is further configured to store capacity information corresponding to each of the plurality of storage spaces in the cloud storage. The capacity information corresponding to each of the plurality of storage spaces may include capacity configuration information corresponding to the storage space, total space, used space, remaining space information, and the like. In this way, loss of capacity information corresponding to a plurality of storage spaces can be avoided.
The database management module 250 is used for the basic CURD function of the database, and can record path storage of video/pictures, event information (including event ID, time, place, event type, etc.) when recording video, and whether to upload to the cloud storage, etc. The Cloud storage may be an internet of vehicles Cloud, a Robo-Cloud, or the like. For example, video data with high threat level in the sentry mode needs to be uploaded to a cloud storage, so that a user can check the video data in time at the APP end of the mobile phone.
In some implementations, the process of the storage management system 200 for unified management encapsulation, identification, and parsing of service data may include the following steps:
and (3) packaging: a common encapsulation format, such as MP4, AVI, etc., may be provided for the service data to facilitate use by different applications. The application may package the business data into this generic format. And (3) identification: the encapsulation format of the service data can be identified by checking header information of the service data. Thus, the storage management system can provide different processing modes for data in different formats. Analysis: the corresponding analysis can be performed according to the format of the service data. For example, for MP4 format video data, information such as audio, video, subtitles, etc. may be parsed to facilitate playing or editing. Through the steps, the storage management system can uniformly manage business data in different formats and provide uniform interfaces for application programs, so that the availability and expandability of the data are improved.
According to the embodiment of the application, a plurality of storage spaces corresponding to the service modules one by one are configured according to the storage spaces of the storage equipment of the vehicle, service data generated by the service modules are respectively stored in the storage spaces, and the respective capacity information of the storage spaces is monitored, so that the storage spaces can be configured reasonably and dynamically. The embodiment of the application is beneficial to reasonably configuring the storage spaces corresponding to the service modules, and the functions of the service modules are better played.
Fig. 3 is a flow diagram of one possible implementation of the capacity configuration module 230 of fig. 2. As shown in fig. 3, the operation flow performed by the capacity configuration module 230 may mainly include steps S310 to S390, which will be described in detail below.
In step S310, a USB plug monitor is performed on the vehicle. If a USB device is detected, step S330 is entered; if no USB device is detected, step S320 is entered.
In step S320, no USB device is detected, and all scanning threads for USB device capacity detection are stopped. Step S360 is entered.
If the vehicle is in a disconnected state with the external storage device, the USB device is not detected, the storage space is acquired from the internal storage device of the vehicle, and the internal storage device is taken as a target storage area.
In step S330, the first USB device is detected, and the process may proceed directly to step S350. In some embodiments, step S340 may also be entered first.
In step S340, it is determined whether the USB device satisfies a preset condition. The preset conditions are not specifically limited, and the preset conditions may be, for example, that the USB device is a USB device authenticated by the vehicle, or that the USB device is a USB device meeting the vehicle authentication requirement, or that the capacity of the USB device meets the minimum capacity requirement.
In step S350, no USB device is detected, and an internal storage path is returned to the storage management system.
In step S360, the USB device is detected, and an external storage path, such as a USB device storage path, is returned to the storage management system.
And if the vehicle is in a connection state with the external storage device, returning to the external storage path, acquiring a storage space from the external storage device, and taking the external storage device as a target storage area of the service modules.
In step S370, it is checked whether a sentinel module and/or DVR folder is present in the storage device. If not, a sentinel module and/or DVR folder may be created first.
In step S380, a capacity scan thread is created according to the configuration of the traffic module.
Different management threads can be arranged in the storage space of different service modules for scanning, for example, the sentinel module and the DVR can be arranged in different management threads for scanning, and the scanned space can be synchronously stored into a memory to form a memory snapshot. For another example, the shared memory space may be scanned by different management threads.
In step S390, the threads are summarized up. So as to obtain the information of the total space, the residual space, the used space and the shared storage space of each business module.
The method and the device are beneficial to unified management of the external storage equipment and the internal storage equipment of the vehicle, and the storage spaces corresponding to the service modules are reasonably configured, so that functions of the service modules can be better played.
Fig. 4 is a schematic diagram of one possible implementation of the capacity management module 240 of fig. 2. As shown in fig. 4, the capacity management module includes a total storage management unit 400 that performs total storage management on the storage devices of the vehicle. Total storage management unit 400 may include USB management 420, storage scan thread management 430 for each business module, and shared storage management 440.
The total storage management unit 400 may generate folders and scanning threads for storing service data according to whether the USB is inserted and service module list (sentinel/DVR) information is provided, for example, the storage scanning thread management 430 generates a storage scanning thread 431, a storage scanning thread 432, etc. corresponding to each service module, and calculates total space, used space, remaining space, minimum space information, etc. corresponding to each service module.
The shared storage management 440 may generate a shared storage scan thread 441 that calculates the total space, used space, remaining space, minimum space information, etc. of the shared region. And then, carrying out upward summarization according to service storage data scanned by different service threads, and collecting the total storage space, used storage space, residual storage space and storage space information of a shared area of each service module. And further determines the total storage space, the used space, and the remaining space information of the storage device, etc.
Fig. 5 is a schematic diagram of one possible implementation of the database management module 250 of fig. 2. As shown in fig. 5, database management module 250 may include a conducting database set 510 and a remote database 520.
The database management module 250 enables access and processing of data through a data access object 511 in the database edit 510. The data access object (data access object, DAO) is an object-oriented database interface that is located intermediate the business logic and the database resources. DAOs are typically suitable for single system applications or for small scale distributed use. For example, video data generated by a plurality of service modules may be stored in the database edit 510 via the data access object 511, and the database may employ the SQLite model, and basic CURD operations may be performed on the database SQLite via the data access object 511.
The database data may be uploaded to a content visitor (content resource) of the remote database 520 through the data access object 511. The content visitor may also perform basic CURD operations on the database SQLite through the content provider (content provider).
The embodiments of the storage management system of the present application are described above in detail with reference to fig. 1 to 5, and the embodiments of the method for storage management of the present application are described below in detail. It should be appreciated that the description of the method embodiments of storage management corresponds to the description of the storage management system embodiments, and thus, portions not described in detail may be referred to the previous storage management system embodiments.
Fig. 6 is a flow chart of a storage management method according to an embodiment of the present application. The storage management method is applied to a storage management system of a vehicle. The storage management system may be any of the storage management systems described above. The storage management system may include: an application program interface layer, a capacity configuration module, a capacity management module and a database management module. The application program interface layer is used for carrying out access operation on service data generated by the service modules. The database management module is used for managing service data generated by the plurality of service modules based on the database. The following describes the storage management method according to the embodiment of the present application in detail with reference to fig. 6. As shown in fig. 6, the storage management method may mainly include steps S610 to S640, which are described in detail below.
It should be noted that, the sequence number of each step in the embodiment of the present application does not mean that the execution sequence of each process should be determined by the function and the internal logic, and should not limit the implementation process of the embodiment of the present invention.
In step S610, a plurality of storage spaces corresponding to a plurality of service modules of a vehicle one-to-one are acquired. The plurality of storage spaces are configured based on the storage space of the storage device of the vehicle, the plurality of storage spaces are respectively used for storing service data generated by the plurality of service modules, the starting of the plurality of service modules is a system self-starting mode, and the storage of the service data is cyclic coverage storage based on a preset rule.
The storage devices of the vehicle may include internal storage devices such as memory, cache, hard disk, etc. of the storage management system. The storage device of the vehicle may also include an external storage device such as an SD card, a USB disk connected through a USB interface, or the like. The internal storage device and the external storage device of the vehicle are collectively referred to as a local storage device.
The service module may refer to a service module that generates multimedia data such as video, pictures, etc. The plurality of business modules may include a sentinel mode module, a vehicle recorder, and the like. The plurality of service modules of the vehicle are usually operated in a service mode in the background after the vehicle is started, and are a system self-starting mode. The plurality of storage spaces are respectively used for storing service data generated by the plurality of service modules. For example, the service data such as the video and the picture generated by the sentry module are stored in the storage space corresponding to the sentry module, and the service data such as the video and the picture generated by the automobile data recorder are stored in the storage space corresponding to the automobile data recorder.
In step S620, the plurality of storage spaces are scanned, and capacity information corresponding to each of the plurality of storage spaces is monitored according to the scanning result. The capacity information includes used capacity information and remaining capacity information of the storage space.
In step S630, the plurality of storage spaces are adjusted according to the capacity information and the first adjustment condition corresponding to each of the plurality of storage spaces.
Alternatively, it may be monitored whether the vehicle is connected to an external storage device; acquiring a storage space of a storage device of the vehicle from an external storage device in response to the vehicle being in a connected state with the external storage device; in response to the vehicle being in a disconnected state from the external storage device, a storage space of the storage device of the vehicle is obtained from the internal storage device of the vehicle. The external storage device is also used for backing up high-priority data in the service data stored in the internal storage device.
Optionally, monitoring whether the vehicle is connected with an external storage device through a first scanning thread; if the vehicle is connected with the external storage device, whether the external storage device meets the preset condition is judged. If the external storage device meets the preset condition, returning to an external storage path, wherein the external storage path is a path for storing service data generated by a plurality of service modules to the external storage device; if the vehicle is not connected with the external storage device, returning to an internal storage path, wherein the internal storage path is a path for storing service data generated by the service modules to the internal storage device.
Optionally, creating a plurality of capacity scanning threads corresponding to the plurality of service modules one by one; and scanning a plurality of storage spaces corresponding to the service modules by using a plurality of capacity scanning threads respectively, and sending capacity information corresponding to the storage spaces to the capacity configuration module 120. Storing the capacity information of the storage spaces into a memory of the vehicle to form a memory snapshot; storing the memory snapshot to a local storage device of the vehicle to form a local snapshot; after the storage management system is restarted, the capacity information corresponding to each of the storage spaces is determined according to the local snapshot (or the memory snapshot).
Optionally, configuring a shared storage space for the remaining service modules of the vehicle except for the plurality of service modules; and under the condition that the capacity information corresponding to the plurality of storage spaces meets the second adjustment condition, configuring part of the space in the shared storage space for the plurality of service modules. Wherein a portion of the space is used to store business data generated by the plurality of business modules.
Optionally, the storage management system manages service data generated by the plurality of service modules based on the database. May further include: receiving a query request, wherein the query request is used for querying target service data from service data generated by a plurality of service modules; and responding to the query request, and searching the target service data through the database.
Optionally, the service data includes an urgent video and a non-urgent video, and the database includes a first database table and a second database table, where the first database table is used to store a file name and a file access path corresponding to the urgent video, and the second database table is used to store a file name and a file access path corresponding to the non-urgent video. The method of the embodiment of the application can further comprise the following steps: judging the type of current service data generated by a plurality of service modules; if the type of the current service data belongs to the emergency video, storing a file name and a file access path corresponding to the current service data into a first database table; and if the type of the current service data belongs to the non-emergency video, storing the file name and the file access path corresponding to the current service data into a second database table.
Optionally, storing capacity information of the plurality of storage spaces into a memory of the vehicle to form a memory snapshot, wherein the memory snapshot is stored into a local storage device of the vehicle; and after the storage management system is restarted, determining the capacity information corresponding to each of the storage spaces according to the memory snapshot.
Optionally, the service data in the plurality of storage spaces and/or capacity information corresponding to each of the plurality of storage spaces are stored in the cloud storage.
Optionally, the plurality of business modules includes a sentinel module and/or a tachograph. When the vehicle is in a parking state, monitoring the storage capacity corresponding to the sentry module; and when the vehicle is in a driving state, monitoring the storage capacity corresponding to the driving recorder.
Optionally, the storage management system has an application program interface. The application program interface is for performing at least one of the following operations: storing service data; searching service data; deleting service data; and coverage of service data.
The embodiment of the application provides a vehicle, which comprises a plurality of service modules and a storage management system as described in any one of the previous embodiments, wherein the storage management system is used for managing service data generated by the plurality of service modules.
It should be appreciated that the vehicle in embodiments of the present application may be a wheeled vehicle or work device on land. The vehicle may be a motor vehicle, which may be a motor vehicle for passengers traveling on a road, or a motor vehicle for transporting articles, and a vehicle for performing a project work. The vehicles can be buses and trucks, the buses can be private cars, buses and business cars, and the buses can also be soft-seat cars, hard-sleeping cars, soft-sleeping cars, dining cars, luggage cars, postal cars and the like. The truck can be a flat car, an open car, a box car, a tank car, a thermal insulation car and the like. The vehicle can also be a special vehicle, such as a banknote carrier. The vehicle in the embodiment of the application may be a vehicle driven by a traditional energy source, such as a vehicle driven by gasoline, diesel oil or natural gas as a power source, or a vehicle driven by a new energy source, such as an electric vehicle or a hydrogen energy vehicle. The embodiment of the present application does not specifically limit the type of vehicle.
Embodiments of the present application provide a computer program product comprising a computer program/instruction which, when executed by a processor of the computer program/instruction, implements a storage management method as described in any of the preceding.
Embodiments of the present application also provide a computer-readable storage medium having instructions stored thereon for performing a storage management method as described in any of the foregoing.
In the above embodiments, it may be implemented in whole or in part by software, hardware, firmware, or any other combination. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, produces a flow or function in accordance with embodiments of the present disclosure, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable apparatus. The computer instructions may be stored in a machine-readable storage medium or transmitted from one machine-readable storage medium to another machine-readable storage medium, for example, the computer instructions may be transmitted from one website, computer, server, or data center to another website, computer, server, or data center by a wired (e.g., coaxial cable, fiber optic, digital subscriber line (digital subscriber line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The machine-readable storage medium may be any available medium that can be accessed by a computer or a data storage device including one or more servers, data centers, etc. integrated with the available medium. The usable medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a magnetic tape), an optical medium (e.g., a digital video disc (digital video disc, DVD)), or a semiconductor medium (e.g., a Solid State Disk (SSD)), or the like.
Those of ordinary skill in the art will appreciate that the elements and algorithm steps described in connection with the embodiments disclosed herein can be implemented as electronic hardware, or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present disclosure.
It should be understood that, in various embodiments of the present application, "first," "second," etc. are used to distinguish between different objects, and not to describe a specific order, the size of the sequence numbers of each process described above does not mean that the order of execution should not be construed as to imply that the order of execution of each process should be determined by its function and inherent logic, but should not be construed as limiting the implementation of the embodiments of the present application.
In the several embodiments provided in the present disclosure, it should be understood that the disclosed systems, devices, and methods may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, e.g., the division of the units is merely a logical function division, and there may be additional divisions when actually implemented, e.g., multiple units or components may be combined or integrated into another system, or some features may be omitted or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
In several embodiments provided herein, it will be understood that when a portion is referred to as being "connected" or "connected" to another portion, it means that the portion can be "directly connected" or "electrically connected" while another element is interposed therebetween. In addition, the term "connected" also means that the portions are "physically connected" as well as "wirelessly connected". In addition, when a portion is referred to as "comprising" an element, it is meant that the portion may include the other element without excluding the other element, unless otherwise stated.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in each embodiment of the present disclosure may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit.
The foregoing is merely specific embodiments of the disclosure, but the protection scope of the disclosure is not limited thereto, and any person skilled in the art can easily think about changes or substitutions within the technical scope of the disclosure, and it is intended to cover the scope of the disclosure. Therefore, the protection scope of the present disclosure shall be subject to the protection scope of the claims.

Claims (12)

1. A storage management system of a vehicle, characterized by comprising: an application program interface layer, a capacity configuration module, a capacity management module and a database management module,
the application program interface layer is used for being connected with a plurality of service modules of the vehicle so as to carry out access operation on service data generated by the service modules;
the capacity configuration module is used for acquiring the storage space of the storage device of the vehicle, configuring a plurality of storage spaces corresponding to the plurality of service modules one by one according to the storage space of the storage device, acquiring capacity information corresponding to the storage spaces from the capacity management module, adjusting the storage spaces according to the capacity information corresponding to the storage spaces, and storing service data generated by the service modules;
The capacity management module is connected with the capacity configuration module and is used for scanning the storage spaces and monitoring capacity information corresponding to the storage spaces according to scanning results, wherein the capacity information comprises used capacity information and residual capacity information of the storage spaces;
the database management module is used for managing service data generated by the service modules based on a database.
2. The storage management system of claim 1, wherein the capacity management module is configured to monitor whether the vehicle is connected to an external storage device via a first scanning thread;
when the vehicle is connected with the external storage device and the external storage device meets a preset condition, the capacity management module is used for returning to an external storage path, wherein the external storage path is a path for storing service data generated by the plurality of service modules to the external storage device;
when the vehicle is not connected with the external storage device, the capacity management module is used for returning to an internal storage path, and the internal storage path is a path for storing service data generated by the service modules to the internal storage device.
3. The storage management system of claim 2, wherein the capacity management module is configured to create a plurality of capacity scan threads in one-to-one correspondence with the plurality of traffic modules; scanning a plurality of storage spaces corresponding to the service modules by using the capacity scanning threads, and sending capacity information corresponding to the storage spaces to the capacity configuration module;
the capacity configuration module is further used for storing the capacity information of the storage spaces into a memory of the vehicle to form a memory snapshot; and storing the memory snapshot to a local storage device of the vehicle to form a local snapshot, and determining capacity information corresponding to each of the plurality of storage spaces according to the local snapshot after the storage management system is restarted.
4. The storage management system of claim 1, wherein,
the capacity configuration module is further configured to configure a shared storage space for remaining service modules of the vehicle other than the plurality of service modules;
and under the condition that capacity information corresponding to the plurality of storage spaces meets a second adjustment condition, configuring partial spaces in the shared storage space for the plurality of service modules, wherein the partial spaces are used for storing service data generated by the plurality of service modules.
5. The storage management system of any one of claims 1-4, wherein the business data comprises urgent video and non-urgent video, the database comprises a first database table and a second database table, the first database table is used for storing file names and file access paths corresponding to the urgent video, the second database table is used for storing file names and file access paths corresponding to the non-urgent video,
the database management module is used for judging the type of the current service data generated by the plurality of service modules; if the type of the current service data belongs to an emergency video, storing a file name and a file access path corresponding to the current service data into the first database table; and if the type of the current service data belongs to the non-emergency video, storing the file name and the file access path corresponding to the current service data into the second database table.
6. The storage management system according to any of claims 1-4, wherein the storage management system comprises a generic layer, connected to the application program interface layer, the database management module and the capacity allocation module, for enabling data interaction between the database management module and/or the capacity allocation module and the application program interface layer.
7. The storage management system of any one of claims 1-4, wherein the plurality of business modules include a sentinel module and/or a vehicle recorder, the capacity management module further configured to monitor a storage capacity corresponding to the sentinel module when the vehicle is in a parked state; and when the vehicle is in a driving state, monitoring the storage capacity corresponding to the driving recorder.
8. The storage management system of any of claims 1-4, wherein the database management module is further configured to store the business data in the plurality of storage spaces and/or the capacity information corresponding to each of the plurality of storage spaces into a cloud storage.
9. The storage management system of any of claims 1-4, wherein the application program interface layer is to perform at least one of:
storing service data;
searching service data;
deleting service data; and
coverage of service data.
10. A storage management method, applied to the storage management system according to any one of claims 1 to 9, comprising:
Acquiring a plurality of storage spaces corresponding to a plurality of service modules of the vehicle one by one, wherein the storage spaces are configured based on the storage spaces of storage equipment of the vehicle, and the storage spaces are respectively used for storing service data generated by the service modules;
scanning the storage spaces, and monitoring capacity information corresponding to each storage space according to a scanning result, wherein the capacity information comprises used capacity information and residual capacity information of the storage space;
and adjusting the storage spaces according to the capacity information corresponding to the storage spaces.
11. A vehicle, characterized by comprising: a plurality of business modules; the storage management system of any of claims 1-9, configured to manage service data generated by the plurality of service modules.
12. A computer readable storage medium having stored thereon instructions for performing the method of claim 10.
CN202310524751.2A 2023-05-10 2023-05-10 Vehicle storage management system and method and vehicle Pending CN116466895A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310524751.2A CN116466895A (en) 2023-05-10 2023-05-10 Vehicle storage management system and method and vehicle

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310524751.2A CN116466895A (en) 2023-05-10 2023-05-10 Vehicle storage management system and method and vehicle

Publications (1)

Publication Number Publication Date
CN116466895A true CN116466895A (en) 2023-07-21

Family

ID=87173656

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310524751.2A Pending CN116466895A (en) 2023-05-10 2023-05-10 Vehicle storage management system and method and vehicle

Country Status (1)

Country Link
CN (1) CN116466895A (en)

Similar Documents

Publication Publication Date Title
US20230298400A1 (en) System, method, and apparatus for managing vehicle data collection
US9324201B2 (en) Vehicular image processing apparatus and method of sharing data using the same
US20170203706A1 (en) Vehicle activity information system
US20160112461A1 (en) Collection and use of captured vehicle data
US10755121B2 (en) Driving oriented digital video recorder system
CN109804367A (en) Use the distributed video storage and search of edge calculations
CN103595973A (en) Real-time vehicle audio/video monitoring system and method
US20200137142A1 (en) Vehicle data offloading systems and methods
WO2014184543A1 (en) Driving event notification
WO2016033523A1 (en) Compact multi-function dvr with multiple integrated wireless data communication devices
CN108415855A (en) It makes video recording file memory method and device, computer installation and storage medium
US11848938B2 (en) Distributed content uploading and validation
JPWO2017138620A1 (en) Memory device, edge device for handling storable data, and data management method
CN116466895A (en) Vehicle storage management system and method and vehicle
CN207624070U (en) A kind of intelligent network controller
CN115534867A (en) Vehicle anti-theft method, device, vehicle and storage medium
US11032372B1 (en) Efficient data streaming using a global index
KR20150080058A (en) Video sharing system and method of black box for vehicle
CN115514741A (en) OTA (over the air) upgrading method and device and computer readable storage medium
KR20130057265A (en) A system for providing video images of a smartphone black-box and the method thereof
CN113345129A (en) Traffic information recording method and device and electronic equipment
US20200401810A1 (en) Computer device and method for monitoring an object
CN112003867A (en) Communication method of vehicle-mounted T-BOX and cloud server and related equipment
CN113557558B (en) Vehicle abnormity monitoring and lighting method and device
CN115909202A (en) Security and protection monitoring all-in-one machine and security and protection monitoring system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination