CN114116045A - International service method and platform for acquiring data based on SDK asynchronous thread - Google Patents

International service method and platform for acquiring data based on SDK asynchronous thread Download PDF

Info

Publication number
CN114116045A
CN114116045A CN202111306946.7A CN202111306946A CN114116045A CN 114116045 A CN114116045 A CN 114116045A CN 202111306946 A CN202111306946 A CN 202111306946A CN 114116045 A CN114116045 A CN 114116045A
Authority
CN
China
Prior art keywords
internationalized
sdk
data
service
international
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
CN202111306946.7A
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.)
Guangzhou Haici Network Technology Co ltd
Original Assignee
Guangzhou Haici Network Technology 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 Guangzhou Haici Network Technology Co ltd filed Critical Guangzhou Haici Network Technology Co ltd
Priority to CN202111306946.7A priority Critical patent/CN114116045A/en
Publication of CN114116045A publication Critical patent/CN114116045A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/166Editing, e.g. inserting or deleting
    • G06F40/177Editing, e.g. inserting or deleting of tables; using ruled lines
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces
    • G06F9/454Multi-language systems; Localisation; Internationalisation

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Information Transfer Between Computers (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention relates to the technical field of web medical systems, and discloses an international business method and platform for acquiring data based on an SDK asynchronous thread. The platform includes: the service system is provided with a service application system corresponding to the internationalized demand interface and is used for performing internationalized content matching replacement on the internationalized client side SDK; the internationalized server side provides internationalized data import for a business side to import internationalized data; the system comprises an international client side SDK, wherein the international client side SDK asynchronously loads international content, dynamically matches and replaces a client side, exposes the client side to a service system in an SDK mode, and passes through an international cache pool maintained in the international client side SDK. The invention greatly reduces the time, labor and maintenance cost for accessing the web medical system internationally, and avoids the interface development of internationalized field addition, deletion, modification and check by using excel lightweight import.

Description

International service method and platform for acquiring data based on SDK asynchronous thread
Technical Field
The invention relates to the technical field of web medical systems, in particular to an international business method and platform for acquiring data based on an SDK asynchronous thread.
Background
With the deep opening to the foreign countries in China, more and more foreign people work and live in China, and become emerging medical groups in China, the international requirements of medical systems are stronger, especially in the first-line city, but because the international design is not considered when some hospital medical systems are constructed, the international cost is extremely high, and the difficulty is serious.
The current common scheme is that the field is directly coupled to the service, international content maintenance and display of the field with corresponding language is added to the field needing internationalization and is coupled to the service system, and hospital operators and medical system developers maintain and manage together, and the strong coupling has the following defects:
1. due to the coupling with the service, the international development cycle is long, and the requirement on the cooperation capability of operators and developers is high;
2. the method is strongly coupled with the service, is extremely unfavorable for subsequent expansion, and the service logic needs to be adjusted greatly every time one language is added;
therefore, it is desirable to design an international business method and platform for acquiring data based on the SDK asynchronous thread to solve the above problems.
Disclosure of Invention
The invention aims to provide an SDK asynchronous thread-based internationalized service method and a platform for acquiring data, wherein a service system is simple to access, original service logic is not required to be moved, the service system is extremely friendly to developers, the performance of the service system is not influenced, the coupling with an internationalized server is extremely low, the normal operation of the service system is not influenced even if the server is offline, and the expansibility is good.
The invention is realized in this way, the international service platform based on SDK asynchronous thread data acquisition, including: the service system is provided with a service application system corresponding to the internationalized demand interface and is used for performing internationalized content matching replacement on the internationalized client side SDK; the internationalized server side provides internationalized data import for a business side to import internationalized data; the system comprises an international client side SDK, wherein the international client side SDK asynchronously loads international content, dynamically matches and replaces a client side, and is exposed to a service system in an SDK mode.
Further, the internationalization server side also provides an internationalization full volume/increment query service, and the service is used for data synchronization of the internationalization SDK.
The international business method for acquiring data based on the SDK asynchronous thread specifically comprises the following steps:
s1: in the stage of importing the internationalized data, the service system integrates an internationalized client SDK, and at the moment, the interface of the service system responds to the field of the VO object needing internationalization, refers to an internationalized section annotation mode and identifies related information;
s2: the service system is started, the SDK starts an asynchronous thread, the whole internationalization information is preferentially read from the local cache file, and the whole data is synchronized from the internationalization server if the reading fails;
s3: in the internationalized data synchronization stage, after the service system takes full internationalized data, the service system processes the full internationalized data to obtain a corresponding data structure and stores the corresponding data structure into an internationalized cache pool;
s4: at regular intervals, the SDK reads the incremental data from the server, stores the incremental data into the international cache pool in the same way after receiving the incremental data, and constructs metadata for a response object in a service system by using an international tangent plane annotation mode;
s5: and in the interface dynamic data internationalization stage, the front end of the user initiates a request, the request head is attached with language information of the current user, the back end receives the request, content matching replacement is carried out on fields needing internationalization according to metadata and languages of the response object, and the interface of the service system responds to the VO object internationally matching replacement and then responds to the front end of the calling party.
Further, in the stage of importing the internationalized data in S1, the service system interface adopts an excel data import mode, which controls the development cost of internationalized versus entry.
Further, in S1, the annotation of the international section is international annotation @ I18n, which makes the original business transparent through the international annotation @ I18n without considering the specific country/language environment.
Further, in S2, the asynchronous thread is used to asynchronously load internationalized information, so as to isolate the strong coupling between the service system and the internationalized server, thereby ensuring the synchronization between the full data and the server.
Further, in S4, the internationalized cache pool is stored at regular intervals for 50-300S, and a cache mechanism is added to put down the internationalized service end without affecting the start and normal operation of the service system.
Further, in the interface dynamic data internationalization stage in S5, the matching mode in which the internationalization client SDK performs the correlation data matching replacement is hash matching, and time complexity is low.
Compared with the prior art, the international business method and platform for acquiring data based on the SDK asynchronous thread have the following beneficial effects:
1. the access of the service system is simple, the original service logic is not required to be moved, the method is extremely friendly to developers, the performance of the service system is not influenced, the coupling with the internationalized service end is extremely low, the normal operation of the service system is not influenced even if the service end is off-line, the expansibility is good, and the language is increased quickly and conveniently;
2. the time, labor and maintenance cost for accessing the web medical system to internationalization are greatly reduced, and the interface development of internationalization field adding, deleting, modifying and checking is avoided by using excel lightweight import; the expansion is simple, one-time butt joint is realized, the languages are infinitely expanded, and the codes do not need to be changed.
Drawings
FIG. 1 is a timing diagram of an international system of an international service platform for acquiring data based on an SDK asynchronous thread according to the present invention;
FIG. 2 is an international SDK initialization flowchart of the international service method for acquiring data based on SDK asynchronous thread according to the present invention;
FIG. 3 is an internationalized flow chart of interface dynamic data of the internationalized service method for acquiring data based on the SDK asynchronous thread according to the present invention;
fig. 4 is a detailed flowchart of an international tangent plane of the method for acquiring data based on the SDK asynchronous thread for international service according to the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The following describes the implementation of the present invention in detail with reference to specific embodiments.
Referring to fig. 1, the international service platform for acquiring data based on the SDK asynchronous thread includes: the service system is provided with a service application system corresponding to the internationalized demand interface and is used for performing internationalized content matching replacement on the internationalized client side SDK; the internationalized server provides internationalized data import for the business side to import internationalized data; the method comprises the steps that an international client side SDK is exposed to a service system in an SDK mode, full data are synchronized when an application is started through an international cache pool maintained in the international client side SDK, incremental data are synchronized from international service at regular time in an operation period, the synchronized data are cached in the cache pool for dynamic matching and replacement of an interface field, a server (front end) imports information into the service system, the service system is directly uploaded through the international client side SDK and is analyzed and stored in the international service, the service system is simple in access, original service logic does not need to be moved, the method is friendly to developers, and performance of the service system is not affected.
Specifically, the server in this embodiment is the front end mentioned in the technical solution, and both functions and actions are the same.
In this embodiment, the internationalized server also provides an internationalized full/incremental query service, which is used for data synchronization of the internationalized SDK, and has extremely low coupling with the internationalized server, so that even if the server is offline, normal operation of a service system is not affected, the expansibility is good, and language addition is fast and convenient.
Referring to fig. 2-4, the international service method for acquiring data based on the SDK asynchronous thread specifically includes the following steps:
s1: in the stage of importing the internationalized data, the service system integrates an internationalized client SDK, and at the moment, the interface of the service system responds to the field of the VO object needing internationalization, refers to an internationalized section annotation mode and identifies related information;
s2: the service system is started, the SDK starts an asynchronous thread, the whole internationalization information is preferentially read from the local cache file, and the whole data is synchronized from the internationalization server if the reading fails;
s3: in the internationalized data synchronization stage, after the service system takes full internationalized data, the service system processes the full internationalized data to obtain a corresponding data structure and stores the corresponding data structure into an internationalized cache pool;
s4: at regular intervals, the SDK reads the incremental data from the server, stores the incremental data into the international cache pool in the same way after receiving the incremental data, and constructs metadata for a response object in a service system by using an international tangent plane annotation mode;
s5: and in the interface dynamic data internationalization stage, the front end of the user initiates a request, the request head is attached with language information of the current user, the back end receives the request, content matching replacement is carried out on fields needing internationalization according to metadata and languages of the response object, and the interface of the service system responds to the VO object internationally matching replacement and then responds to the front end of the calling party.
Fig. 2 is an initialization flowchart of an SDK at an international client, where the initialization flowchart includes: the service system starts and registers an internationalized section, so that a stone bucket is identified to have a full cache file, if the stone bucket has the full cache file, reading is carried out, synchronization of full data is completed, if the stone bucket has the full cache file, the full data is remotely requested, if the stone bucket has the full cache file, the full data is successfully requested, the full data is synchronized, and a brightening synchronization timing task is started after the full data request is completed;
fig. 3 is an internationalized flow chart of interface dynamic data, which includes the following flows: firstly, a user uses a browser to carry out a request interface, then, the back-end service staff logical processing is carried out, a Response object is obtained after the processing, whether the Response object contains @ I18N-lang or not is confirmed, if yes, international tangent plane processing is carried out, and international interface Response is returned, and if yes, the interface Response is directly returned;
fig. 4 is a detailed flowchart of the international tangent plane, which comprises the following steps: whether the data response object has @ I18n or not is judged, a key consisting of an entity name, an although name, an id and a language is carried out, the key is taken to be matched in a cache data structure, and finally whether the data response object is matched with the cache or not is judged, if Y is, translation content corresponding to the language is obtained, the compliance content of the response object is replaced, and otherwise, the response cache content is not replaced;
in this embodiment, in the stage of importing the internationalized data in S1, the service system interface adopts an excel data import mode, so that the development cost of internationalized versus entry is controlled.
In this embodiment, in S1, the international annotation is international annotation @ I18n, and by means of international annotation @ I18n, the annotation is transparent to the original service, does not need to consider a specific country/language environment, and is very friendly to developers.
In this embodiment, in S2, the internationalization information is asynchronously loaded by using the asynchronous thread, so as to isolate the strong coupling between the service system and the internationalization server, and ensure the synchronism between the full data and the server.
In this embodiment, in S4, the internationalized cache pool is stored at regular intervals for 50-300S, and a cache mechanism is added to put down the internationalized service end without affecting the startup and normal operation of the service system.
In this embodiment, in the interface dynamic data internationalization stage in S5, the matching mode for performing the correlation data matching replacement by the internationalization client SDK is hash matching, the time complexity is low, the influence on the service performance and the response time is controlled to be minimum, a set of annotations is abstracted, the internationalized resources are abstracted to an entity domain, and the service entity and the association relationship between the entities can be expressed flexibly.
The platform of the technical scheme has the advantages that the service system is simple to access, original service logic is not required to be moved, the platform is friendly to developers, the performance of the service system is not influenced, the coupling with an internationalized service end is extremely low, the normal operation of the service system is not influenced even if the service end is offline, the expansibility is good, the language is increased quickly and conveniently, in addition, the excel lightweight import is used, the interface development of internationalized field increasing, deleting, modifying and checking is avoided, the expansion is simple, the one-time butt joint is realized, the language is infinitely expanded, and codes are not required to be changed.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents and improvements made within the spirit and principle of the present invention are intended to be included within the scope of the present invention.

Claims (8)

1. An international service platform for acquiring data based on SDK asynchronous threads is characterized by comprising:
the service system is provided with a service application system corresponding to the internationalized demand interface and is used for performing internationalized content matching replacement on the internationalized client side SDK;
the internationalized server side provides internationalized data import for a business side to import internationalized data;
the system comprises an international client side SDK, wherein the international client side SDK asynchronously loads international content, dynamically matches and replaces a client side, and is exposed to a service system in an SDK mode.
2. The internationalized service platform that obtains data based on an SDK asynchronous thread as recited in claim 1, wherein the internationalized service also provides an internationalized full/incremental query service that provides data synchronization for the internationalized SDK.
3. The international business method for acquiring data based on the SDK asynchronous thread as claimed in any one of claims 1 or 2, comprising the steps of:
s1: in the stage of importing the internationalized data, the service system integrates an internationalized client SDK, and at the moment, the interface of the service system responds to the field of the VO object needing internationalization, refers to an internationalized section annotation mode and identifies related information;
s2: the service system is started, the SDK starts an asynchronous thread, the whole internationalization information is preferentially read from the local cache file, and the whole data is synchronized from the internationalization server if the reading fails;
s3: in the internationalized data synchronization stage, after the service system takes full internationalized data, the service system processes the full internationalized data to obtain a corresponding data structure and stores the corresponding data structure into an internationalized cache pool;
s4: at regular intervals, the SDK reads the incremental data from the server, stores the incremental data into the international cache pool in the same way after receiving the incremental data, and constructs metadata for a response object in a service system by using an international tangent plane annotation mode;
s5: and in the interface dynamic data internationalization stage, the front end of the user initiates a request, the request head is attached with language information of the current user, the back end receives the request, content matching replacement is carried out on fields needing internationalization according to metadata and languages of the response object, and the interface of the service system responds to the VO object internationally matching replacement and then responds to the front end of the calling party.
4. The internationalized service method for acquiring data based on the SDK asynchronous thread as recited in claim 3, wherein in an internationalized data importing stage in S1, the service system interface adopts an excel data importing mode, which controls development cost of internationalized contrast import.
5. The method of claim 4 for internationalized service based on SDK asynchronous thread data acquisition, wherein in S1, the annotation of the internationalized cut plane is internationalized annotation @ I18n, and the original service is made transparent by the internationalized annotation @ I18n without considering a specific country/language environment.
6. The internationalized service method for acquiring data based on the SDK asynchronous thread as recited in claim 5, wherein in S2, the internationalized information is asynchronously loaded by using the asynchronous thread, thereby isolating strong coupling between the service system and the internationalized server and ensuring synchronization between the full amount of data and the server.
7. The internationalized service method for acquiring data based on an SDK asynchronous thread as recited in claim 6, wherein in S4, the internationalized cache pool is stored for 50-300S at regular intervals, and a caching mechanism is added to put down an internationalized service end without affecting the start and normal operation of the service system.
8. The internationalized service method for acquiring data based on an SDK asynchronous thread as recited in claim 7, wherein, in an interface dynamic data internationalization stage in S5, a matching manner in which the internationalized client SDK performs cause data matching replacement is hash matching, and time complexity is low.
CN202111306946.7A 2021-11-05 2021-11-05 International service method and platform for acquiring data based on SDK asynchronous thread Pending CN114116045A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111306946.7A CN114116045A (en) 2021-11-05 2021-11-05 International service method and platform for acquiring data based on SDK asynchronous thread

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111306946.7A CN114116045A (en) 2021-11-05 2021-11-05 International service method and platform for acquiring data based on SDK asynchronous thread

Publications (1)

Publication Number Publication Date
CN114116045A true CN114116045A (en) 2022-03-01

Family

ID=80380912

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111306946.7A Pending CN114116045A (en) 2021-11-05 2021-11-05 International service method and platform for acquiring data based on SDK asynchronous thread

Country Status (1)

Country Link
CN (1) CN114116045A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2005045739A2 (en) * 2003-10-24 2005-05-19 Microsoft Corporation Scalable synchronous and asynchronous processing of monitoring rules
CN104850386A (en) * 2014-01-09 2015-08-19 武汉联影医疗科技有限公司 Software system internationalization resource processing method
CN111400408A (en) * 2020-04-13 2020-07-10 上海东普信息科技有限公司 Data synchronization method, device, equipment and storage medium
CN113392132A (en) * 2021-05-07 2021-09-14 杭州数知梦科技有限公司 Distributed caching method and system for IOT scene

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2005045739A2 (en) * 2003-10-24 2005-05-19 Microsoft Corporation Scalable synchronous and asynchronous processing of monitoring rules
CN104850386A (en) * 2014-01-09 2015-08-19 武汉联影医疗科技有限公司 Software system internationalization resource processing method
CN111400408A (en) * 2020-04-13 2020-07-10 上海东普信息科技有限公司 Data synchronization method, device, equipment and storage medium
CN113392132A (en) * 2021-05-07 2021-09-14 杭州数知梦科技有限公司 Distributed caching method and system for IOT scene

Similar Documents

Publication Publication Date Title
CN107391653B (en) Distributed NewSQL database system and picture data storage method
CN107038222B (en) Database cache implementation method and system
US20210216701A1 (en) Method, apparatus, device and storage medium for determining page theme
CN109522029A (en) A kind of method and device for disposing cloud platform technology component
CN111177161B (en) Data processing method, device, computing equipment and storage medium
JP2021096857A (en) Data processing method, device, electronic apparatus, and storage medium
US9910733B2 (en) Transaction completion in a synchronous replication environment
CN104113587A (en) Client metadata buffer optimization method of distributed file system
CN111367991B (en) MongoDB data real-time synchronization method and system based on message queue
CN105095424A (en) Method for realizing high-concurrency retrieval of medicine in hospital HIS system
CN105610917B (en) Method and system for realizing synchronous data repair in system
CN113886485A (en) Data processing method, device, electronic equipment, system and storage medium
CN115408391A (en) Database table changing method, device, equipment and storage medium
CN112905618A (en) Data processing method and device
CN114116045A (en) International service method and platform for acquiring data based on SDK asynchronous thread
CN116975159B (en) Incremental data synchronization processing method
US20110106760A1 (en) Synchronizing database and non-database resources without a commit coordinator
CN111309740A (en) Data processing method, device, equipment and storage medium
NO316006B1 (en) Space-saving file management in servers
WO2003081464A2 (en) Database system comprising database access object with cache
CN107590199A (en) A kind of multi-thread data storehouse design method towards internal memory
CN112612647A (en) Log parallel replay method, device, equipment and storage medium
CN112307023B (en) General processing method for fly stream dimension Join based on event heartbeat and multiple versions
CN112685431B (en) Asynchronous caching method, device, system, electronic equipment and storage medium
CN114398453A (en) Data access method based on Redis cache technology

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