KR20240074579A - Gateway device and method for routing management based on response information - Google Patents

Gateway device and method for routing management based on response information Download PDF

Info

Publication number
KR20240074579A
KR20240074579A KR1020220156812A KR20220156812A KR20240074579A KR 20240074579 A KR20240074579 A KR 20240074579A KR 1020220156812 A KR1020220156812 A KR 1020220156812A KR 20220156812 A KR20220156812 A KR 20220156812A KR 20240074579 A KR20240074579 A KR 20240074579A
Authority
KR
South Korea
Prior art keywords
gateway device
routing
target server
threads
sub
Prior art date
Application number
KR1020220156812A
Other languages
Korean (ko)
Inventor
장영휘
이연주
김용혁
Original Assignee
주식회사 위베어소프트
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 주식회사 위베어소프트 filed Critical 주식회사 위베어소프트
Priority to KR1020220156812A priority Critical patent/KR20240074579A/en
Publication of KR20240074579A publication Critical patent/KR20240074579A/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/63Routing a service request depending on the request content or context
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/66Arrangements for connecting between networks having differing types of switching systems, e.g. gateways
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

응답정보를 기반으로 라우팅 관리를 하는 게이트웨이 장치 및 방법이 개시된다. 복수의 클라이언트 단말과 복수의 타겟 서버 사이에서 통신 연결을 중개하는 게이트웨이 장치는 클라이언트 단말의 태스크(task)에 대해 상기 타겟 서버로 요청하고, 요청에 대한 응답정보를 파싱(parsing)하는 복수의 서브 스레드 및 복수의 서브 스레드와 연결되고, 복수의 서브 스레드로부터 파싱된 응답정보가 수신되면 수신된 응답정보를 이용하여 각 타겟 서버의 에러 응답률을 산출하며, 산출된 에러 응답률을 기반으로 라우팅 정책을 설정하고, 설정된 라우팅 정책을 복수의 서브 스레드로 전달하는 메인 스레드를 포함한다. A gateway device and method for routing management based on response information are disclosed. A gateway device that mediates a communication connection between a plurality of client terminals and a plurality of target servers requests the target server for a task of the client terminal and includes a plurality of sub-threads that parse response information to the request. And it is connected to a plurality of sub-threads, and when response information parsed from the plurality of sub-threads is received, the error response rate of each target server is calculated using the received response information, and a routing policy is set based on the calculated error response rate. , includes a main thread that transfers the set routing policy to multiple subthreads.

Description

응답정보를 기반으로 라우팅 관리를 하는 게이트웨이 장치 및 방법{Gateway device and method for routing management based on response information}Gateway device and method for routing management based on response information}

본 발명은 라우팅 관리 기술에 관한 것으로, 더욱 상세하게는 타겟 서버의 응답정보에 대한 에러 응답률을 기반으로 라우팅을 관리하는 응답정보를 기반으로 라우팅 관리를 하는 게이트웨이 장치 및 방법에 관한 것이다.The present invention relates to routing management technology, and more specifically, to a gateway device and method for managing routing based on response information that manages routing based on the error response rate for response information of a target server.

멀티 스레드(multi thread) 기반의 게이트웨이(gateway) 또는 프록시 서버(proxy server)에서 여러 지정된 타겟 서버에 요청을 주고, 요청에 대응하는 응답을 받는다. A multi-threaded gateway or proxy server sends requests to multiple designated target servers and receives responses corresponding to the requests.

일반적으로 게이트웨이 또는 프록시 서버는 이러한 과정을 라운드 로빈(Round Robin, RR) 방식 또는 프라이머리/백업(Primary/backup) 방식으로 타겟 서버를 선택하여 TCP(Transmission Control Protocol) 연결을 맺고 요청을 보내고 응답을 받아 처리한다.Typically, a gateway or proxy server performs this process by selecting a target server in a round robin (RR) method or primary/backup method and transmitting TCP (Transmission) to the target server. Control Protocol) establishes a connection, sends a request, receives a response, and processes it.

하지만 라운드 로빈 방식은 사용 도중에 에러나 문제가 발생한 타겟 서버가 있다 하더라도, 이를 고려하지 못하는 문제가 있고, 프라이머리/백업 방식은 백업 서버의 자원(resource)이 낭비되는 문제가 있다. 또한 특정 서버에 TCP 연결은 되지만 HTTP 요청에 대한 응답이 정상응답이 아닌 경우에 대한 고려가 잘 반영되지 않는 문제도 있다.However, the round robin method has a problem in that it cannot take into account even if there is a target server that has an error or problem during use, and the primary/backup method has a problem in that the resources of the backup server are wasted. There is also a problem that consideration of cases where a TCP connection is made to a specific server but the response to the HTTP request is not a normal response is not properly reflected.

한국등록특허공보 제10-1982578호(2019.05.21.)Korean Patent Publication No. 10-1982578 (2019.05.21.)

본 발명이 해결하고자 하는 과제는, 타겟 서버의 응답정보에 대한 에러 응답률을 기반으로 에러 응답률이 낮은 타겟 서버를 우선적으로 선택하여 원활한 통신을 제공하는 응답정보를 기반으로 라우팅 관리를 하는 게이트웨이 장치 및 방법을 제공하는 것이다. The problem to be solved by the present invention is to provide a gateway device and method for routing management based on response information that provides smooth communication by preferentially selecting a target server with a low error response rate based on the error response rate for response information of the target server. is to provide.

상기 과제를 해결하기 위해 본 발명에 따른 복수의 클라이언트 단말과 복수의 타겟 서버 사이에서 통신 연결을 중개하는 게이트웨이 장치는, 상기 클라이언트 단말의 태스크(task)에 대해 상기 타겟 서버로 요청하고, 상기 요청에 대한 응답정보를 파싱(parsing)하는 복수의 서브 스레드 및 상기 복수의 서브 스레드와 연결되고, 상기 복수의 서브 스레드로부터 상기 파싱된 응답정보가 수신되면 상기 수신된 응답정보를 이용하여 각 타겟 서버의 에러 응답률을 산출하며, 상기 산출된 에러 응답률을 기반으로 라우팅 정책을 설정하고, 상기 설정된 라우팅 정책을 상기 복수의 서브 스레드로 전달하는 메인 스레드를 포함한다.In order to solve the above problem, a gateway device that mediates a communication connection between a plurality of client terminals and a plurality of target servers according to the present invention requests the target server for a task of the client terminal, and responds to the request. It is connected to a plurality of sub-threads that parse response information for the target server, and when the parsed response information is received from the plurality of sub-threads, an error of each target server is detected using the received response information. It includes a main thread that calculates a response rate, sets a routing policy based on the calculated error response rate, and transmits the set routing policy to the plurality of sub-threads.

또한 상기 메인 스레드는, 상기 응답정보에 포함된 코드정보를 기반으로 해시 맵(hash map) 형태로 관리하는 것을 특징으로 한다.In addition, the main thread is characterized in that it manages the code information included in the response information in the form of a hash map.

또한 상기 메인 스레드는, 타겟 서버의 응답정보에 대한 개수가 기 설정된 기준 이상이고, 해당 타겟 서버의 에러 응답률이 기 설정된 기준에 도달하면 상기 에러 응답률에 적용하며, 상기 에러 응답률이 적용됨을 알려주는 알림 메시지가 상기 라우팅 정책을 관리하는 API 매니저 장치로 제공되도록 제어하는 것을 특징으로 한다.In addition, the main thread applies the error response rate when the number of response information of the target server is more than a preset standard and the error response rate of the target server reaches the preset standard, and a notification notifies that the error response rate is applied. It is characterized by controlling the message to be provided to the API manager device that manages the routing policy.

또한 상기 메인 스레드는, 상기 에러 응답률이 낮은 타겟 서버부터 우선적으로 선택하여 라우팅되도록 상기 라우팅 정책을 설정하는 것을 특징으로 한다.In addition, the main thread sets the routing policy to preferentially select and route the target server with the lowest error response rate.

또한 상기 메인 스레드는, 상기 에러 응답률이 동일한 타겟 서버가 존재하는 경우, 라운드 로빈(Round Robin) 방식으로 상기 라우팅 정책을 설정하는 것을 특징으로 한다.Additionally, the main thread is characterized in that it sets the routing policy in a round robin method when there is a target server with the same error response rate.

또한 상기 메인 스레드는, 기 설정된 주기마다 상기 에러 응답률을 초기화하고, 새로운 에러 응답률을 산출하는 것을 특징으로 한다.Additionally, the main thread initializes the error response rate at each preset period and calculates a new error response rate.

또한 상기 메인 스레드는, 상기 복수의 서브 스레드와 파이프 라인으로 연결되는 것을 특징으로 한다.Additionally, the main thread is connected to the plurality of sub-threads through a pipeline.

본 발명에 따른 복수의 클라이언트 단말과 복수의 타겟 서버 사이에서 통신 연결을 중개하는 멀티 스레드 기반 게이트웨이 장치의 라우팅 방법은, 상기 게이트웨이 장치의 복수의 서브 스레드가 상기 클라이언트 단말의 태스크에 대해 상기 타겟 서버로 요청하고, 상기 요청에 대한 응답정보를 파싱하는 단계, 상기 게이트웨이 장치의 메인 스레드가 상기 복수의 서브 스레드로부터 상기 파싱된 응답정보가 수신되면 상기 수신된 응답정보를 이용하여 각 타겟 서버의 에러 응답률을 산출하는 단계, 상기 메인 스레드가 상기 산출된 에러 응답률을 기반으로 라우팅 정책을 설정하는 단계, 상기 메인 스레드가 상기 설정된 라우팅 정책을 상기 복수의 서브 스레드로 전달하는 단계 및 상기 복수의 서브 스레드가 상기 수신된 라우팅 정책에 따라 라우팅하는 단계를 포함한다.The routing method of a multi-threaded gateway device that mediates communication connections between a plurality of client terminals and a plurality of target servers according to the present invention includes a plurality of sub-threads of the gateway device to the target server for tasks of the client terminal. Requesting and parsing response information for the request, when the main thread of the gateway device receives the parsed response information from the plurality of sub-threads, uses the received response information to determine the error response rate of each target server. calculating, the main thread setting a routing policy based on the calculated error response rate, the main thread transmitting the set routing policy to the plurality of sub-threads, and the plurality of sub-threads receiving the It includes routing according to the established routing policy.

본 발명에 따른 라우팅 시스템은 복수의 클라이언트 단말과 복수의 타겟 서버 사이에서 통신 연결을 중개하는 복수의 게이트웨이 장치 및 상기 복수의 게이트웨이 장치로부터 상기 통신 연결에 대한 라우팅 정책을 수집하고, 상기 수집된 라우팅 정책을 관리하는 API 매니저 장치를 포함하되, 상기 복수의 게이트웨이 장치 각각은, 상기 클라이언트 단말의 태스크(task)에 대해 상기 타겟 서버에 요청하고, 상기 요청에 대한 응답정보를 파싱(parsing)하는 복수의 서브 스레드 및 상기 복수의 서브 스레드와 연결되고, 상기 복수의 서브 스레드로부터 상기 파싱된 응답정보가 수신되면 상기 수신된 응답정보를 이용하여 각 타겟 서버의 에러 응답률을 산출하며, 상기 산출된 에러 응답률을 기반으로 상기 라우팅 정책을 설정하고, 상기 설정된 라우팅 정책을 상기 복수의 서브 스레드로 전달하는 메인 스레드를 포함한다.A routing system according to the present invention collects a plurality of gateway devices that mediate communication connections between a plurality of client terminals and a plurality of target servers and a routing policy for the communication connection from the plurality of gateway devices, and the collected routing policy Includes an API manager device that manages, wherein each of the plurality of gateway devices requests the target server for a task of the client terminal and a plurality of servers that parse response information to the request. It is connected to a thread and the plurality of sub-threads, and when the parsed response information is received from the plurality of sub-threads, the error response rate of each target server is calculated using the received response information, and based on the calculated error response rate. It includes a main thread that sets the routing policy and transfers the set routing policy to the plurality of sub-threads.

또한 상기 API 매니저 장치는, 상기 복수의 게이트웨이 장치 중 적어도 하나의 게이트웨이 장치가 상기 라우팅 정책을 요청하는 경우, 해당 게이트웨이 장치로 관리 중인 라우팅 정책을 전송하는 것을 특징으로 한다.Additionally, the API manager device is characterized in that when at least one gateway device among the plurality of gateway devices requests the routing policy, the API manager device transmits the routing policy being managed to the corresponding gateway device.

본 발명의 실시예에 따르면, 타겟 서버의 응답정보를 이용하여 해당 타겟 서버의 에러 응답률을 산출하고, 산출된 에러 응답률을 기반으로 라우팅 정책을 설정함으로써, 에러 응답률이 낮은 타겟 서버를 우선적으로 라우팅하여 사용자에게 원활한 통신을 제공할 수 있다.According to an embodiment of the present invention, the error response rate of the target server is calculated using the response information of the target server, and a routing policy is set based on the calculated error response rate, thereby preferentially routing the target server with a low error response rate. It can provide smooth communication to users.

또한 시스템에 새롭게 추가 또는 생성된 게이트웨이 장치로 라우팅 정책을 제공하여 해당 게이트웨이 장치가 초기 설정하는 시간 및 비용을 줄여줄 수 있다.Additionally, by providing a routing policy to a gateway device newly added or created in the system, the time and cost for initial setup of the gateway device can be reduced.

도 1은 본 발명의 실시예에 따른 라우팅 시스템을 설명하기 위한 구성도이다.
도 2는 본 발명의 실시예에 따른 게이트웨이 장치를 설명하기 위한 블록도이다.
도 3은 본 발명의 실시예에 따른 라우팅 과정을 설명하기 위한 도면이다.
도 4는 본 발명의 실시예에 따른 게이트웨이 장치의 라우팅 방법을 설명하기 위한 순서도이다.
도 5는 본 발명의 실시예에 따른 API 매니저 장치의 정보관리 방법을 설명하기 위한 순서도이다.
도 6은 본 발명의 실시예에 따른 컴퓨팅 장치를 설명하기 위한 블록도이다.
1 is a configuration diagram for explaining a routing system according to an embodiment of the present invention.
Figure 2 is a block diagram for explaining a gateway device according to an embodiment of the present invention.
Figure 3 is a diagram for explaining the routing process according to an embodiment of the present invention.
Figure 4 is a flowchart for explaining a routing method of a gateway device according to an embodiment of the present invention.
Figure 5 is a flow chart to explain the information management method of the API manager device according to an embodiment of the present invention.
Figure 6 is a block diagram for explaining a computing device according to an embodiment of the present invention.

아래에서는 첨부한 도면을 참고로 하여 본 발명의 실시예에 대하여 본 발명이 속하는 기술 분야에서 통상의 지식을 가진 자가 용이하게 실시할 수 있도록 상세히 설명한다. 그러나 본 발명은 여러 가지 상이한 형태로 구현될 수 있으며 여기에서 설명하는 실시예에 한정되지 않는다. 그리고 도면에서 본 발명을 명확하게 설명하기 위해서 설명과 관계없는 부분은 생략하였으며, 명세서 전체를 통하여 유사한 부분에 대해서는 유사한 도면 부호를 붙였다. Below, with reference to the attached drawings, embodiments of the present invention will be described in detail so that those skilled in the art can easily implement the present invention. However, the present invention may be implemented in many different forms and is not limited to the embodiments described herein. In order to clearly explain the present invention in the drawings, parts unrelated to the description are omitted, and similar parts are given similar reference numerals throughout the specification.

본 명세서 및 도면(이하 '본 명세서')에서, 동일한 구성요소에 대해서 중복된 설명은 생략한다.In this specification and drawings (hereinafter referred to as “this specification”), duplicate descriptions of the same components are omitted.

또한 본 명세서에서, 어떤 구성요소가 다른 구성요소에 '연결되어' 있다거나 '접속되어' 있다고 언급된 때에는, 그 다른 구성요소에 직접적으로 연결되어 있거나 또는 접속되어 있을 수도 있지만, 중간에 다른 구성요소가 존재할 수도 있다고 이해되어야 할 것이다. 반면에 본 명세서에서, 어떤 구성요소가 다른 구성요소에 '직접 연결되어' 있다거나 '직접 접속되어' 있다고 언급된 때에는, 중간에 다른 구성요소가 존재하지 않는 것으로 이해되어야 할 것이다.Also, in this specification, when a component is mentioned as being 'connected' or 'connected' to another component, it may be directly connected or connected to the other component, but may be connected to the other component in the middle. It should be understood that may exist. On the other hand, in this specification, when it is mentioned that a component is 'directly connected' or 'directly connected' to another component, it should be understood that there are no other components in between.

또한, 본 명세서에서 사용되는 용어는 단지 특정한 실시예를 설명하기 위해 사용되는 것으로써, 본 발명을 한정하려는 의도로 사용되는 것이 아니다. Additionally, the terms used in this specification are merely used to describe specific embodiments and are not intended to limit the present invention.

또한 본 명세서에서, 단수의 표현은 문맥상 명백하게 다르게 뜻하지 않는 한, 복수의 표현을 포함할 수 있다. Also, in this specification, singular expressions may include plural expressions, unless the context clearly dictates otherwise.

또한 본 명세서에서, '포함하다' 또는 '가지다' 등의 용어는 명세서에 기재된 특징, 숫자, 단계, 동작, 구성요소, 부품, 또는 이들을 조합한 것이 존재함을 지정하려는 것일 뿐, 하나 또는 그 이상의 다른 특징, 숫자, 단계, 동작, 구성요소, 부품 또는 이들을 조합한 것의 존재 또는 부가 가능성을 미리 배제하지 않는 것으로 이해되어야 할 것이다.In addition, in this specification, terms such as 'include' or 'have' are only intended to designate the presence of features, numbers, steps, operations, components, parts, or combinations thereof described in the specification, and one or more It should be understood that this does not exclude in advance the presence or addition of other features, numbers, steps, operations, components, parts, or combinations thereof.

또한 본 명세서에서, '및/또는' 이라는 용어는 복수의 기재된 항목들의 조합 또는 복수의 기재된 항목들 중의 어느 항목을 포함한다. 본 명세서에서, 'A 또는 B'는, 'A', 'B', 또는 'A와 B 모두'를 포함할 수 있다.Also, in this specification, the term 'and/or' includes a combination of a plurality of listed items or any of the plurality of listed items. In this specification, 'A or B' may include 'A', 'B', or 'both A and B'.

또한 본 명세서에서, 본 발명의 요지를 흐리게 할 수 있는 공지 기능 및 구성에 대한 상세한 설명은 생략될 것이다.Additionally, in this specification, detailed descriptions of well-known functions and configurations that may obscure the gist of the present invention will be omitted.

도 1은 본 발명의 실시예에 따른 라우팅 시스템을 설명하기 위한 구성도이다.1 is a configuration diagram for explaining a routing system according to an embodiment of the present invention.

도 1을 참조하면, 라우팅 시스템(600)은 타겟 서버의 응답정보에 대한 에러 응답률을 기반으로 에러 응답률이 낮은 타겟 서버를 우선적으로 선택하여 원활한 통신을 제공한다. 라우팅 시스템(600)는 클라우드(cloud) 환경에서의 시스템일 수 있으나, 이에 한정하지 않는다. 라우팅 시스템(600)은 적어도 하나의 게이트웨이 장치(100), 복수의 클라이언트 단말(200), 복수의 타겟 서버(300), API 매니저 장치(400) 및 사용자 단말(500)을 포함한다.Referring to FIG. 1, the routing system 600 provides smooth communication by preferentially selecting a target server with a low error response rate based on the error response rate of response information of the target server. The routing system 600 may be a system in a cloud environment, but is not limited to this. The routing system 600 includes at least one gateway device 100, a plurality of client terminals 200, a plurality of target servers 300, an API manager device 400, and a user terminal 500.

게이트웨이 장치(100)는 복수의 클라이언트 단말(200)과 복수의 타겟 서버(300) 사이에서 통신 연결을 중개한다. 게이트웨이 장치(100)는 적어도 하나를 포함할 수 있고, 멀티 스레드(multi thread) 기반으로 구성될 수 있다. The gateway device 100 mediates a communication connection between a plurality of client terminals 200 and a plurality of target servers 300. The gateway device 100 may include at least one device and may be configured on a multi-thread basis.

게이트웨이 장치(100)는 클라이언트 단말(200)의 태스크(task)에 대해 타겟 서버(300)로 요청하고, 요청에 대한 응답정보를 파싱(pasing)한다. 여기서 요청은 HTTP(hypertext transfer protocol) 요청을 의미하고, 파싱은 응답정보에 포함된 코드정보를 분석하는 과정을 의미한다. 게이트웨이 장치(100)는 파싱된 응답정보를 이용하여 각 타겟 서버의 에러 응답률을 산출한다. 게이트웨이 장치(100)는 산출된 에러 응답률을 기반으로 라우팅 정책을 설정한다. 여기서 라우팅 정책은 타겟 서버(300)와의 연결 방법을 나타내는 정책으로써, 기본적으로 라운딩 로빈 방식을 설정하되, 에러 응답률이 낮은 타겟 서버부터 우선적으로 선택되도록 설정할 수 있다. 또한 라우팅 정책은 기 설정된 주기마다 업데이트하여 최신 에러 응답 에러율을 반영할 수 있다. 게이트웨이 장치(100)는 설정된 라우팅 정책에 따라 복수의 클라이언트 단말(200)과 복수의 타겟 서버(300)의 통신을 지원한다.The gateway device 100 requests the target server 300 for a task of the client terminal 200 and parses response information to the request. Here, request refers to an HTTP (hypertext transfer protocol) request, and parsing refers to the process of analyzing code information included in response information. The gateway device 100 calculates the error response rate of each target server using the parsed response information. The gateway device 100 sets a routing policy based on the calculated error response rate. Here, the routing policy is a policy indicating a connection method with the target server 300. Basically, a rounding robin method can be set, but the target server with a low error response rate is preferentially selected. Additionally, the routing policy can be updated at preset intervals to reflect the latest error response error rate. The gateway device 100 supports communication between a plurality of client terminals 200 and a plurality of target servers 300 according to a set routing policy.

클라이언트 단말(200)은 클라이언트가 사용하는 단말로써, 복수개(200a, 200b, 200c, 200d)를 포함할 수 있다. 각 클라이언트 단말(200)은 태스크에 대한 요청을 하고, 요청에 대한 응답을 수신하여 출력한다. 이때 클라이언트 단말(200)은 게이트웨이 장치(100)를 통해 타겟 서버(300)와 통신을 수행할 수 있다. 바람직하게는 클라이언트 단말(200)은 스마트폰, 데스크톱, 랩톱, 태블릿 PC, 핸드헬드 PC 등을 포함하는 컴퓨팅 시스템일 수 있다.The client terminal 200 is a terminal used by a client and may include a plurality of terminals 200a, 200b, 200c, and 200d. Each client terminal 200 makes a request for a task, receives a response to the request, and outputs it. At this time, the client terminal 200 may communicate with the target server 300 through the gateway device 100. Preferably, the client terminal 200 may be a computing system including a smartphone, desktop, laptop, tablet PC, handheld PC, etc.

타겟 서버(300)는 다양한 콘텐츠를 제공하는 서버로써, 복수개(300a, 300b, 300c, 300d)를 포함할 수 있다. 이때 타겟 서버(300)는 하나의 사이트에 대한 데이터를 분산화한 서버일 수 있으나, 이에 한정하지 않는다. 각 타겟 서버(300)는 고유한 IP(internet protocol) 주소를 가지고 있어서 해당 IP 주소를 통해 TCP 연결이 가능하다. 타겟 서버(300)는 TCP 연결이 되어 태스크와 관련된 요청을 수신하면 해당 요청에 대한 응답정보를 제공한다. 이때 타겟 서버(300)는 응답정보를 게이트웨이 장치(100)로 전송할 수 있다. 바람직하게는 타겟 서버(300)는 서버 컴퓨터, 클러스터 컴퓨터 등을 포함하는 컴퓨팅 시스템일 수 있다. The target server 300 is a server that provides various contents and may include a plurality of servers 300a, 300b, 300c, and 300d. At this time, the target server 300 may be a server that decentralizes data for one site, but is not limited to this. Each target server 300 has a unique IP (internet protocol) address, so a TCP connection is possible through the IP address. When the target server 300 establishes a TCP connection and receives a task-related request, it provides response information for the request. At this time, the target server 300 may transmit response information to the gateway device 100. Preferably, the target server 300 may be a computing system including a server computer, a cluster computer, etc.

API(application programming interface) 매니저 장치(400)는 적어도 하나의 게이트웨이 장치(100)로부터 라우팅 정책을 수신하고, 수신된 라우팅 정책을 관리한다. 게이트웨이 장치(100)가 복수인 경우, API 매니저 장치(400)는 각 게이트웨이 장치(100)로부터 라우팅 정책을 각각 수신하고, 수신된 라우팅 정책을 병합하여 관리할 수 있다. 즉 API 매니저 장치(400)는 수신된 복수의 라우팅 정책에 포함된 각 타겟 서버(300a, 300b, 300c, 300d)의 에러 응답률을 평균화하여 시스템 전체에 대한 라우팅 정책을 도출한다. API 매니저 장치(400)는 도출된 라우팅 정책을 저장하여 관리하되, 기 설정된 주기마다 복수의 게이트웨이 장치(100)로부터 최신 라우팅 정책을 수신하여 관리 중인 라우팅 정책을 업데이트할 수 있다. 한편 API 매니저 장치(400)는 복수의 게이트웨이 장치 중 적어도 하나의 게이트웨이 장치가 라우팅 정책을 요청하는 경우, 해당 게이트웨이 장치로 관리 중인 라우팅 정책을 전송하여 해당 게이트웨이가 전송된 라우팅 정책을 기반으로 라우팅하도록 할 수 있다. 여기서 라우팅 정책을 요청하는 게이트웨이 장치는 라우팅 시스템(600)에 새롭게 생성되거나, 추가된 장치일 수 있다.The API (application programming interface) manager device 400 receives a routing policy from at least one gateway device 100 and manages the received routing policy. When there are multiple gateway devices 100, the API manager device 400 may receive routing policies from each gateway device 100 and manage the received routing policies by merging them. That is, the API manager device 400 averages the error response rates of each target server 300a, 300b, 300c, and 300d included in the plurality of received routing policies to derive a routing policy for the entire system. The API manager device 400 stores and manages the derived routing policy, and can update the routing policy being managed by receiving the latest routing policy from a plurality of gateway devices 100 at preset intervals. Meanwhile, when at least one gateway device among a plurality of gateway devices requests a routing policy, the API manager device 400 transmits the routing policy being managed to the corresponding gateway device and allows the gateway to route based on the transmitted routing policy. You can. Here, the gateway device requesting the routing policy may be a device newly created or added to the routing system 600.

사용자 단말(500)은 사용자(시스템 관리자)가 사용하는 단말로써, API 매니저 장치(400)와 통신을 수행한다. 사용자 단말(500)은 API 매니저 장치(400)로부터 최신 라우팅 정책을 수신하고, 수신된 라우팅 정책을 출력한다. 이때 사용자 단말(500)은 에러 응답률이 높은 타겟 서버를 별도 표시하여 출력할 수 있다. 이를 통해 사용자는 해당 타겟 서버와의 TCP 연결에 문제가 있음을 직관적으로 인지할 수 있다. 바람직하게는 사용자 단말(500)은 스마트폰, 데스크톱, 랩톱, 태블릿 PC, 핸드헬드 PC 등을 포함하는 컴퓨팅 시스템일 수 있다.The user terminal 500 is a terminal used by a user (system administrator) and communicates with the API manager device 400. The user terminal 500 receives the latest routing policy from the API manager device 400 and outputs the received routing policy. At this time, the user terminal 500 may separately display and output the target server with a high error response rate. Through this, the user can intuitively recognize that there is a problem with the TCP connection with the target server. Preferably, the user terminal 500 may be a computing system including a smartphone, desktop, laptop, tablet PC, handheld PC, etc.

도 2는 본 발명의 실시예에 따른 게이트웨이 장치를 설명하기 위한 블록도이고, 도 3은 본 발명의 실시예에 따른 라우팅 과정을 설명하기 위한 도면이다.FIG. 2 is a block diagram for explaining a gateway device according to an embodiment of the present invention, and FIG. 3 is a diagram for explaining a routing process according to an embodiment of the present invention.

도 1 내지 도 3을 참조하면, 게이트웨이 장치(100)는 통신부(10), 제어부(30) 및 저장부(50)를 포함한다.1 to 3, the gateway device 100 includes a communication unit 10, a control unit 30, and a storage unit 50.

통신부(10)는 클라이언트 단말(200) 및 타겟 서버(300)와 통신을 수행하고, API 매니저 장치(400)와 더 통신을 수행할 수 있다. 통신부(10)는 클라이언트 단말(200)로부터 태스크와 관련된 요청을 수신하고, 해당 요청에 대응되는 응답정보를 클라이언트 단말(200)로 전송한다. 통신부(10)는 태스크와 관련된 요청을 타겟 서버(300)로 전송하고, 타겟 서버(300)로부터 해당 요청에 대응되는 응답정보를 수신한다. 통신부(10)는 라우팅하는 방법을 나타내는 라우팅 정책을 API 매니저 장치(400)로 전송한다. The communication unit 10 may communicate with the client terminal 200 and the target server 300, and further communicate with the API manager device 400. The communication unit 10 receives a task-related request from the client terminal 200 and transmits response information corresponding to the request to the client terminal 200. The communication unit 10 transmits a request related to the task to the target server 300 and receives response information corresponding to the request from the target server 300. The communication unit 10 transmits a routing policy indicating a routing method to the API manager device 400.

제어부(30)는 게이트웨이 장치(100)의 전반적인 제어를 수행한다. 제어부(300)는 복수의 스레드로 구성되고, 복수의 스레드를 통해 라우팅을 제어한다. 제어부(30)는 메인 스레드(41) 및 복수의 서브 스레드(42, 43, 44)를 포함한다. 여기서 메인 스레드(41)는 복수의 서브 스레드(42, 43, 44)와 파이프 라인으로 연결된다.The control unit 30 performs overall control of the gateway device 100. The control unit 300 is composed of a plurality of threads and controls routing through the plurality of threads. The control unit 30 includes a main thread 41 and a plurality of sub-threads 42, 43, and 44. Here, the main thread 41 is connected to a plurality of sub-threads 42, 43, and 44 through a pipeline.

메인 스레드(41)는 게이트웨이 장치(100)의 라우팅에 대한 제어를 수행한다. 이를 위해 메인 스레드(41)는 태스크와 관련된 요청 처리를 수행하지 않고, 타겟 서버의 응답정보를 기반으로 라우팅 정책을 설정한다.The main thread 41 controls routing of the gateway device 100. To this end, the main thread 41 does not process requests related to the task, but sets a routing policy based on the response information of the target server.

상세하게는 메인 스레드(41)는 복수의 서브 스레드(42, 43, 44)로부터 파싱(parsing)된 응답정보를 수신하면 수신된 응답정보를 관리한다. 이때 메인 스레드(41)는 응답정보에 포함된 코드정보를 기반으로 해시 맵(hash map) 형태로 관리할 수 있다. 메인 스레드(41)는 해시 맵을 통해 키를 값에 매핑하여 보다 원활한 자료 관리를 할 수 있다. 메인 스레드(41)는 응답정보를 이용하여 각 타겟 서버의 에러 응답률을 산출한다. 메인 스레드(41)는 타겟 서버의 응답정보에 대한 개수가 기 설정된 기준 이상이고, 해당 타겟 서버의 에러 응답률이 기 설정된 기준에 도달하면 에러 응답률에 적용할 수 있으며, 바람직하게는 에러 응답률이 30% 내지 40% 이상인 경우부터 에러 응답률에 적용할 수 있으나, 이에 한정하지 않는다. 즉 메인 스레드(41)는 응답정보에 대한 개수가 기준치 이하이면 데이터의 신뢰도가 낮기 때문에 에러 응답률이 높더라도 에러 응답률을 해당 타겟 서버의 에러 응답률이라고 판단하지 않을 수 있다. 또한 메인 스레드(41)는 응답정보에 대한 개수가 기준치 이상이더라도 에러 응답률이 30% 내지 40% 이하이면 TCP 연결에 크게 영향을 주지 않는다고 판단하여 에러 응답률을 0%로 산출할 수 있다. In detail, when the main thread 41 receives response information parsed from a plurality of sub-threads 42, 43, and 44, it manages the received response information. At this time, the main thread 41 can manage the code information included in the response information in the form of a hash map. The main thread 41 can manage data more smoothly by mapping keys to values through a hash map. The main thread 41 uses the response information to calculate the error response rate of each target server. The main thread 41 can apply the error response rate when the number of response information of the target server is more than a preset standard and the error response rate of the target server reaches the preset standard. Preferably, the error response rate is 30%. It can be applied to the error response rate starting from 40% or more, but is not limited to this. That is, if the number of response information is less than the standard value, the main thread 41 may not determine that the error response rate is the error response rate of the target server even if the error response rate is high because the reliability of the data is low. In addition, the main thread 41 may calculate the error response rate as 0% by determining that it does not significantly affect the TCP connection if the error response rate is 30% to 40% or less even if the number of response information is more than the standard value.

IP 주소IP address 정상응답normal response 에러응답Error response 에러 응답률error response rate 1.1.1.11.1.1.1 66 44 40%40% 2.2.2.22.2.2.2 2020 55 0%0% 3.3.3.33.3.3.3 44 44 0%0%

예를 들어 메인 스레드(41)는 [표 1]과 같이 에러 응답률을 산출할 수 있다. 여기서 타겟 서버는 IP 주소가 1.1.1.1인 타겟 서버(300a), 2.2.2.2인 타겟 서버(300b) 및 3.3.3.3인 타겟 서버(300c)를 포함하고, 에러 응답률을 산출하기 위한 최소 전체 응답정보 개수는 10개이며, 에러 응답률이 적용되는 시작 에러 응답률은 30%인 경우를 가정하였다. 메인 스레드(41)는 복수의 서브 스레드(42, 43, 44)로부터 타겟 서버(300a)의 응답정보를 수신한다. 이때 응답정보의 총 개수가 10개이고, 그 중 정상응답이 6개, 에러응답이 4개이면 메인 스레드(41)는 에러 응답률을 40%로 산출하고, 산출된 에러 응답률을 타겟 서버(300a)의 에러 응답률로 적용한다. 또한 메인 스레드(41)는 복수의 서브 스레드(42, 43, 44)로부터 타겟 서버(300b)의 응답정보를 수신한다. 이때 응답정보의 총 개수가 25개이고, 그 중 정상응답이 20개, 에러응답이 5개이면 메인 스레드(41)는 에러 응답률을 20%로 산출할 수 있으나, 산출된 에러 응답률이 시작 에러 응답률인 30%를 넘지 않으므로, 산출된 에러 응답률을 타겟 서버(300b)의 에러 응답률로 적용하지 않는다. 또한 메인 스레드(41)는 복수의 서브 스레드(42, 43, 44)로부터 타겟 서버(300c)의 응답정보를 수신한다. 이때 응답정보의 총 개수가 9개이고, 그 중 정상응답이 4개, 에러응답이 4개이면 메인 스레드(41)는 에러 응답률을 50%로 산출할 수 있으나, 응답정보의 총 개수가 최소 전체 응답정보 개수보다 낮으므로, 산출된 에러 응답률을 타겟 서버(300c)의 에러 응답률로 적용하지 않는다.For example, the main thread 41 can calculate the error response rate as shown in [Table 1]. Here, the target server includes a target server (300a) with an IP address of 1.1.1.1, a target server (300b) with an IP address of 2.2.2.2, and a target server (300c) with an IP address of 3.3.3.3, and the minimum total response information for calculating the error response rate. The number is 10, and the starting error response rate to which the error response rate is applied is assumed to be 30%. The main thread 41 receives response information of the target server 300a from a plurality of sub-threads 42, 43, and 44. At this time, if the total number of response information is 10, of which 6 are normal responses and 4 are error responses, the main thread 41 calculates the error response rate as 40%, and sends the calculated error response rate to the target server 300a. Applies to error response rate. Additionally, the main thread 41 receives response information of the target server 300b from a plurality of sub-threads 42, 43, and 44. At this time, if the total number of response information is 25, of which 20 are normal responses and 5 are error responses, the main thread 41 can calculate the error response rate as 20%, but the calculated error response rate is the starting error response rate. Since it does not exceed 30%, the calculated error response rate is not applied as the error response rate of the target server 300b. Additionally, the main thread 41 receives response information of the target server 300c from a plurality of sub-threads 42, 43, and 44. At this time, if the total number of response information is 9, of which 4 are normal responses and 4 are error responses, the main thread 41 can calculate the error response rate as 50%, but the total number of response information is at least the total response. Since it is lower than the number of information, the calculated error response rate is not applied as the error response rate of the target server 300c.

여기서 메인 스레드(41)는 에러 응답률이 적용됨을 알려주는 알림 메시지가 API 매니저 장치(400)로 제공되도록 제어할 수 있다. 이를 통해 API 매니저 장치(400)는 사용자 단말(500)로 해당 알림 메시지를 제공할 수 있다.Here, the main thread 41 can control a notification message indicating that the error response rate is applied to be provided to the API manager device 400. Through this, the API manager device 400 can provide the corresponding notification message to the user terminal 500.

메인 스레드(41)는 산출된 에러 응답률을 기반으로 라우팅 정책을 설정한다. 메인 스레드(41)는 에러 응답률이 낮은 타겟 서버부터 우선적으로 선택하여 라우팅되도록 라우팅 정책을 설정한다. 여기서 메인 스레드(41)는 에러 응답률이 동일한 타겟 서버가 존재하는 경우, 라운드 로빈 방식으로 라우팅 정책을 설정할 수 있다. 예를 들어 [표 1]과 같은 에러 응답률이 나온 경우, 메인 스레드(41)는 타겟 서버(300b)과 타겟 서버(300c)를 라운드 로빈 방식으로 선택한 후, 타겟 서버(300a)를 다음 순서로 선택하거나, 타겟 서버(300a)를 제외하고 타겟 서버(300b)과 타겟 서버(300c)를 라운드 로빈 방식으로 선택할 수 있다. 또한 메인 스레드(41)는 기 설정된 주기마다 에러 응답률을 초기화하고, 새로운 에러 응답률을 산출하여 최신 라우팅 정책을 설정할 수 있다. 즉 메인 스레드(41)는 에러가 발생되었던 타겟 서버가 복구된 경우, 에러가 발생되지 않던 타겟 서버에서 에러가 발생되는 경우 등에 대한 대응을 빠르게 하기 위해 최신 라우팅 정책을 기 설정된 주기마다 설정할 수 있다.The main thread 41 sets a routing policy based on the calculated error response rate. The main thread 41 sets a routing policy to preferentially select and route target servers with low error response rates. Here, the main thread 41 can set the routing policy in a round-robin method when there are target servers with the same error response rate. For example, when the error response rate is as shown in [Table 1], the main thread 41 selects the target server 300b and target server 300c in a round-robin method, and then selects the target server 300a in the following order. Alternatively, the target server 300b and the target server 300c can be selected in a round-robin manner, excluding the target server 300a. Additionally, the main thread 41 can initialize the error response rate at each preset cycle, calculate a new error response rate, and set the latest routing policy. That is, the main thread 41 can set the latest routing policy at preset intervals in order to quickly respond to cases where a target server where an error occurred is restored or an error occurs at a target server where an error did not occur, etc.

메인 스레드(41)는 설정된 라우팅 정책을 복수의 서브 스레드(42, 43, 44)로 전달하여 복수의 서브 스레드(42, 43, 44)를 통해 라우팅이 이루어지도록 제어한다. 또한 메인 스레드(41)는 설정된 라우팅 정책을 API 매니저 장치(400)로 전송시켜 API 매니저 장치(400)가 전체 시스템에 대한 라우팅을 관리할 수 있도록 지원할 수 있다. The main thread 41 transfers the set routing policy to the plurality of sub-threads 42, 43, and 44 and controls routing to be performed through the plurality of sub-threads 42, 43, and 44. Additionally, the main thread 41 can transmit the set routing policy to the API manager device 400 so that the API manager device 400 can manage routing for the entire system.

복수의 서브 스레드(42, 43, 44)는 메인 스레드(41)와 연결되고, 클라이언트 단말(200)의 태스크에 대한 처리를 수행한다. 즉 복수의 서브 스레드(42, 43, 44)는 태스크에 대해 타겟 서버(300)로 요청하고, 요청에 대한 응답정보를 수신하여 파싱한다. 이때 복수의 서브 스레드(42, 43, 44)는 응답정보에 포함된 코드정보를 파싱할 수 있다. 복수의 서브 스레드(42, 43, 44)는 파싱된 응답정보를 메인 스레드(41)로 전달한다. 복수의 서브 스레드(42, 43, 44)는 메인 스레드(41)로부터 응답정보를 기반으로 설정된 라우팅 정책을 각각 수신하고, 수신된 라우팅 정책에 따라 라우팅을 수행한다.A plurality of sub-threads 42, 43, and 44 are connected to the main thread 41 and process tasks of the client terminal 200. That is, the plurality of sub-threads 42, 43, and 44 request the target server 300 for a task, receive response information for the request, and parse it. At this time, the plurality of sub-threads 42, 43, and 44 may parse the code information included in the response information. A plurality of sub-threads 42, 43, and 44 transmit the parsed response information to the main thread 41. The plurality of sub-threads 42, 43, and 44 each receive a routing policy set based on response information from the main thread 41 and perform routing according to the received routing policy.

저장부(50)는 게이트웨이 장치(100)가 구동되기 위한 프로그램 또는 알고리즘이 저장된다. 저장부(50)는 태스크와 관련된 정보(요청, 응답)가 저장된다. 저장부(50)는 에러 응답율이 저장되고, 라우팅 정책이 저장된다. 저장부(50)는 플래시 메모리 타입(flash memory type), 하드디스크 타입(hard disk type), 미디어 카드 마이크로 타입(multimedia card micro type), 카드 타입의 메모리(예를 들어 SD 또는 XD 메모리 등), 램(Random Access Memory, RAM), SRAM(Static Random Access Memory), 롬(Read-Only Memory, ROM), EEPROM(Electrically Erasable Programmable Read-Only Memory), PROM(Programmable Read-Only Memory), 자기메모리, 자기 디스크 및 광디스크 중 적어도 하나의 저장매체를 포함할 수 있다. The storage unit 50 stores a program or algorithm for driving the gateway device 100. The storage unit 50 stores task-related information (request, response). The storage unit 50 stores the error response rate and routing policy. The storage unit 50 includes a flash memory type, hard disk type, multimedia card micro type, card type memory (for example, SD or XD memory, etc.), Random Access Memory (RAM), Static Random Access Memory (SRAM), Read-Only Memory (ROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Programmable Read-Only Memory (PROM), magnetic memory, It may include at least one storage medium of a magnetic disk and an optical disk.

도 4는 본 발명의 실시예에 따른 게이트웨이 장치의 라우팅 방법을 설명하기 위한 순서도이다.Figure 4 is a flowchart for explaining a routing method of a gateway device according to an embodiment of the present invention.

도 1 및 도 4를 참조하면, 게이트웨이 장치(100)의 라우팅 방법은 타겟 서버(300)의 응답정보를 이용하여 해당 타겟 서버의 에러 응답률을 산출하고, 산출된 에러 응답률을 기반으로 라우팅 정책을 설정한다. 이를 통해 라우팅 방법은 에러 응답률이 낮은 타겟 서버를 우선적으로 라우팅하여 사용자에게 원활한 통신을 제공할 수 있다.Referring to Figures 1 and 4, the routing method of the gateway device 100 uses response information of the target server 300 to calculate the error response rate of the target server and sets a routing policy based on the calculated error response rate. do. Through this, the routing method can provide smooth communication to users by preferentially routing target servers with low error response rates.

S110 단계에서, 게이트웨이 장치(100)는 타겟 서버(300)로부터 응답정보를 수신한다. 게이트웨이 장치(100)는 태스크의 요청에 대응하는 응답정보를 수신한다. 게이트웨이 장치(100)는 수신된 응답정보를 파싱하고, 파싱된 응답정보를 해시 맵 형태로 관리할 수 있다.In step S110, the gateway device 100 receives response information from the target server 300. The gateway device 100 receives response information corresponding to the task request. The gateway device 100 may parse the received response information and manage the parsed response information in the form of a hash map.

S120 단계에서, 게이트웨이 장치(100)는 각 타겟 서버별 에러 응답률을 산출한다. 게이트웨이 장치(100)는 각 타겟 서버별 전체 응답정보 개수에서 에러 응답정보 개수를 나눈 값에 백분율로 계산하여 에러 응답률을 산출한다. 이때 게이트웨이 장치(100)는 타겟 서버의 응답정보에 대한 개수가 기 설정된 기준 이상이고, 해당 타겟 서버의 에러 응답률이 기 설정된 기준에 도달하면 해당 에러 응답률을 적용할 수 있다. 이때 게이트웨이 장치(100)는 에러 응답률이 적용됨을 알려주는 알림 메시지가 API 매니저 장치(400)로 전달할 수 있다.In step S120, the gateway device 100 calculates the error response rate for each target server. The gateway device 100 calculates the error response rate by dividing the number of error response information by the total number of response information for each target server and calculating it as a percentage. At this time, the gateway device 100 may apply the corresponding error response rate when the number of response information of the target server is greater than the preset standard and the error response rate of the target server reaches the preset standard. At this time, the gateway device 100 may transmit a notification message indicating that the error response rate is applied to the API manager device 400.

S130 단계에서, 게이트웨이 장치(100)는 라우팅 정책을 설정한다. 게이트웨이 장치(100)는 산출된 에러 응답률을 기반으로 라우팅 정책을 설정한다. 게이트웨이 장치(100)는 에러 응답률이 낮은 타겟 서버부터 우선적으로 선택하여 라우팅되도록 라우팅 정책을 설정할 수 있다. 이때 게이트웨이 장치(100)는 에러 응답률이 동일한 타겟 서버가 존재하는 경우, 라운드 로빈 방식으로 라우팅 정책을 설정할 수 있다.In step S130, the gateway device 100 sets a routing policy. The gateway device 100 sets a routing policy based on the calculated error response rate. The gateway device 100 may set a routing policy to preferentially select and route a target server with a low error response rate. At this time, if there are target servers with the same error response rate, the gateway device 100 may set the routing policy in a round-robin method.

S140 단계에서, 게이트웨이 장치(100)는 라우팅을 한다. 게이트웨이 장치(100)는 설정된 라우팅 정책에 따라 라우팅을 수행한다. In step S140, the gateway device 100 performs routing. The gateway device 100 performs routing according to a set routing policy.

도 5는 본 발명의 실시예에 따른 API 매니저 장치의 정보관리 방법을 설명하기 위한 순서도이다.Figure 5 is a flowchart for explaining the information management method of the API manager device according to an embodiment of the present invention.

도 1 및 도 5를 참조하면, API 매니저 장치(400)의 정보관리 방법은 시스템에 새롭게 추가 또는 생성된 게이트웨이 장치로 라우팅 정책을 제공하여 해당 게이트웨이 장치가 초기 설정하는 시간 및 비용을 줄여줄 수 있다.Referring to Figures 1 and 5, the information management method of the API manager device 400 provides a routing policy to a gateway device newly added or created in the system, thereby reducing the time and cost for initial setup of the corresponding gateway device. .

S210 단계에서, API 매니저 장치(400)는 라우팅 정책을 수집한다. API 매니저 장치(400)는 각 게이트웨이 장치(100)로부터 라우팅 정책을 수집한다. 이때 각 게이트웨이 장치별로 라우팅 정책은 일부 차이가 있을 수 있다.In step S210, the API manager device 400 collects routing policies. The API manager device 400 collects routing policies from each gateway device 100. At this time, there may be some differences in the routing policy for each gateway device.

S220 단계에서, API 매니저 장치(400)는 수집된 라우팅 정책을 하나의 통합된 라우팅 정책으로 병합한다. API 매니저 장치(400)는 라우팅 정책에 포함된 각 타겟 서버(300)별 에러 응답률을 평균화하여 하나의 통합된 라우팅 정책을 생성한다.In step S220, the API manager device 400 merges the collected routing policies into one integrated routing policy. The API manager device 400 generates one integrated routing policy by averaging the error response rate for each target server 300 included in the routing policy.

S230 단계에서, API 매니저 장치(400)는 라우팅 정책을 요청한 게이트웨이 장치가 있는지 판단한다. API 매니저 장치(400)는 라우팅 정책을 요청한 게이트웨이 장치가 있으면 S240 단계를 수행하고, 라우팅 정책을 요청한 게이트웨이 장치가 없으면 S250 단계를 수행한다.In step S230, the API manager device 400 determines whether there is a gateway device that has requested a routing policy. The API manager device 400 performs step S240 if there is a gateway device that has requested a routing policy, and performs step S250 if there is no gateway device that has requested a routing policy.

S240 단계에서, API 매니저 장치(400)는 해당 게이트웨이 장치로 라우팅 정책을 전송한다. API 매니저 장치(400)는 라우팅 정책을 요청한 게이트웨이 장치로 관리 중인 라우팅 정책을 전송한다.In step S240, the API manager device 400 transmits a routing policy to the corresponding gateway device. The API manager device 400 transmits the routing policy being managed to the gateway device that requested the routing policy.

S250 단계에서, API 매니저 장치(400)는 기 설정된 주기가 되었는지 판단한다. API 매니저 장치(400)는 기 설정된 주기가 도달하면 S210 단계를 수행하고, 기 설정된 주기가 도달하지 않으면 S230 단계를 수행한다.In step S250, the API manager device 400 determines whether a preset period has been reached. The API manager device 400 performs step S210 when the preset period reaches, and performs step S230 when the preset period does not reach.

도 6은 본 발명의 실시예에 따른 컴퓨팅 장치를 설명하기 위한 블록도이다.Figure 6 is a block diagram for explaining a computing device according to an embodiment of the present invention.

도 6을 참조하면, 컴퓨팅 장치(TN100)는 본 명세서에서 기술된 장치(예를 들면 게이트웨이 장치, 클라이언트 단말, 타겟 서버, API 매니저 장치, 사용자 단말 등) 일 수 있다. Referring to FIG. 6, the computing device TN100 may be a device described in this specification (eg, a gateway device, a client terminal, a target server, an API manager device, a user terminal, etc.).

컴퓨팅 장치(TN100)는 적어도 하나의 프로세서(TN110), 송수신 장치(TN120), 및 메모리(TN130)를 포함할 수 있다. 또한, 컴퓨팅 장치(TN100)는 저장 장치(TN140), 입력 인터페이스 장치(TN150), 출력 인터페이스 장치(TN160) 등을 더 포함할 수 있다. 컴퓨팅 장치(TN100)에 포함된 구성 요소들은 버스(bus)(TN170)에 의해 연결되어 서로 통신을 수행할 수 있다.The computing device TN100 may include at least one processor TN110, a transceiver device TN120, and a memory TN130. Additionally, the computing device TN100 may further include a storage device TN140, an input interface device TN150, an output interface device TN160, etc. Components included in the computing device TN100 may be connected by a bus TN170 and communicate with each other.

프로세서(TN110)는 메모리(TN130) 및 저장 장치(TN140) 중에서 적어도 하나에 저장된 프로그램 명령(program command)을 실행할 수 있다. 프로세서(TN110)는 중앙 처리 장치(CPU: central processing unit), 그래픽 처리 장치(GPU: graphics processing unit), 또는 본 발명의 실시예에 따른 방법들이 수행되는 전용의 프로세서를 의미할 수 있다. 프로세서(TN110)는 본 발명의 실시예와 관련하여 기술된 절차, 기능, 및 방법 등을 구현하도록 구성될 수 있다. 프로세서(TN110)는 컴퓨팅 장치(TN100)의 각 구성 요소를 제어할 수 있다.The processor TN110 may execute a program command stored in at least one of the memory TN130 and the storage device TN140. The processor TN110 may refer to a central processing unit (CPU), a graphics processing unit (GPU), or a dedicated processor on which methods according to embodiments of the present invention are performed. Processor TN110 may be configured to implement procedures, functions, and methods described in connection with embodiments of the present invention. The processor TN110 may control each component of the computing device TN100.

메모리(TN130) 및 저장 장치(TN140) 각각은 프로세서(TN110)의 동작과 관련된 다양한 정보를 저장할 수 있다. 메모리(TN130) 및 저장 장치(TN140) 각각은 휘발성 저장 매체 및 비휘발성 저장 매체 중에서 적어도 하나로 구성될 수 있다. 예를 들어, 메모리(TN130)는 읽기 전용 메모리(ROM: read only memory) 및 랜덤 액세스 메모리(RAM: random access memory) 중에서 적어도 하나로 구성될 수 있다. Each of the memory TN130 and the storage device TN140 can store various information related to the operation of the processor TN110. Each of the memory TN130 and the storage device TN140 may be comprised of at least one of a volatile storage medium and a non-volatile storage medium. For example, the memory TN130 may be comprised of at least one of read only memory (ROM) and random access memory (RAM).

송수신 장치(TN120)는 유선 신호 또는 무선 신호를 송신 또는 수신할 수 있다. 송수신 장치(TN120)는 네트워크에 연결되어 통신을 수행할 수 있다. The transceiving device TN120 can transmit or receive wired signals or wireless signals. The transmitting and receiving device (TN120) can be connected to a network and perform communication.

한편, 본 발명의 실시예는 지금까지 설명한 장치 및/또는 방법을 통해서만 구현되는 것은 아니며, 본 발명의 실시예의 구성에 대응하는 기능을 실현하는 프로그램 또는 그 프로그램이 기록된 기록 매체를 통해 구현될 수도 있으며, 이러한 구현은 상술한 실시예의 기재로부터 본 발명이 속하는 기술 분야의 통상의 기술자라면 쉽게 구현할 수 있는 것이다. Meanwhile, the embodiments of the present invention are not only implemented through the apparatus and/or method described so far, but may also be implemented through a program that realizes the function corresponding to the configuration of the embodiment of the present invention or a recording medium on which the program is recorded. This implementation can be easily implemented by anyone skilled in the art from the description of the above-described embodiments.

이상에서 본 발명의 실시예에 대하여 상세하게 설명하였지만 본 발명의 권리범위는 이에 한정되는 것은 아니고 다음의 청구범위에서 정의하고 있는 본 발명의 기본 개념을 이용한 통상의 기술자의 여러 변형 및 개량 형태 또한 본 발명의 권리범위에 속하는 것이다.Although the embodiments of the present invention have been described in detail above, the scope of the present invention is not limited thereto, and various modifications and improvements made by those skilled in the art using the basic concept of the present invention defined in the following claims are also possible. It falls within the scope of invention rights.

10: 통신부
30: 제어부
41: 메인 스레드
42: 제1 서브 스레드
43: 제2 서브 스레드
44: 제n 서브 스레드
100: 게이트웨이 장치
200: 클라이언트 단말
300: 타겟 서버
400: API 매니저 장치
500: 사용자 단말
600: 라우팅 시스템
10: Department of Communications
30: control unit
41: main thread
42: first sub-thread
43: second sub-thread
44: nth subthread
100: gateway device
200: client terminal
300: Target server
400: API manager device
500: user terminal
600: Routing system

Claims (10)

복수의 클라이언트 단말과 복수의 타겟 서버 사이에서 통신 연결을 중개하는 게이트웨이 장치에 있어서,
상기 클라이언트 단말의 태스크(task)에 대해 상기 타겟 서버로 요청하고, 상기 요청에 대한 응답정보를 파싱(parsing)하는 복수의 서브 스레드; 및
상기 복수의 서브 스레드와 연결되고, 상기 복수의 서브 스레드로부터 상기 파싱된 응답정보가 수신되면 상기 수신된 응답정보를 이용하여 각 타겟 서버의 에러 응답률을 산출하며, 상기 산출된 에러 응답률을 기반으로 라우팅 정책을 설정하고, 상기 설정된 라우팅 정책을 상기 복수의 서브 스레드로 전달하는 메인 스레드;
를 포함하는 게이트웨이 장치.
In the gateway device that mediates communication connections between a plurality of client terminals and a plurality of target servers,
a plurality of sub-threads that request a task of the client terminal from the target server and parse response information to the request; and
It is connected to the plurality of sub-threads, and when the parsed response information is received from the plurality of sub-threads, the error response rate of each target server is calculated using the received response information, and routing is performed based on the calculated error response rate. a main thread that sets a policy and transfers the set routing policy to the plurality of sub-threads;
A gateway device containing a.
제 1항에 있어서,
상기 메인 스레드는,
상기 응답정보에 포함된 코드정보를 기반으로 해시 맵(hash map) 형태로 관리하는 것을 특징으로 하는 게이트웨이 장치.
According to clause 1,
The main thread is,
A gateway device characterized in that it is managed in the form of a hash map based on the code information included in the response information.
제 1항에 있어서,
상기 메인 스레드는,
타겟 서버의 응답정보에 대한 개수가 기 설정된 기준 이상이고, 해당 타겟 서버의 에러 응답률이 기 설정된 기준에 도달하면 상기 에러 응답률에 적용하며, 상기 에러 응답률이 적용됨을 알려주는 알림 메시지가 상기 라우팅 정책을 관리하는 API 매니저 장치로 제공되도록 제어하는 것을 특징으로 하는 게이트웨이 장치.
According to clause 1,
The main thread is,
If the number of response information of the target server is more than the preset standard and the error response rate of the target server reaches the preset standard, the error response rate is applied, and a notification message notifying that the error response rate is applied is sent to the routing policy. A gateway device characterized in that it is controlled to be provided to a managed API manager device.
제 1항에 있어서,
상기 메인 스레드는,
상기 에러 응답률이 낮은 타겟 서버부터 우선적으로 선택하여 라우팅되도록 상기 라우팅 정책을 설정하는 것을 특징으로 하는 게이트웨이 장치.
According to clause 1,
The main thread is,
A gateway device characterized in that the routing policy is set so that the target server with the lowest error response rate is preferentially selected and routed.
제 1항에 있어서,
상기 메인 스레드는,
상기 에러 응답률이 동일한 타겟 서버가 존재하는 경우, 라운드 로빈(Round Robin) 방식으로 상기 라우팅 정책을 설정하는 것을 특징으로 하는 게이트웨이 장치.
According to clause 1,
The main thread is,
A gateway device characterized in that, when there is a target server with the same error response rate, the routing policy is set in a round robin method.
제 1항에 있어서,
상기 메인 스레드는,
기 설정된 주기마다 상기 에러 응답률을 초기화하고, 새로운 에러 응답률을 산출하는 것을 특징으로 하는 게이트웨이 장치.
According to clause 1,
The main thread is,
A gateway device characterized in that the error response rate is initialized at each preset period and a new error response rate is calculated.
제 1항에 있어서,
상기 메인 스레드는,
상기 복수의 서브 스레드와 파이프 라인으로 연결되는 것을 특징으로 하는 게이트웨이 장치
According to clause 1,
The main thread is,
A gateway device characterized in that it is connected to the plurality of sub-threads and a pipeline.
복수의 클라이언트 단말과 복수의 타겟 서버 사이에서 통신 연결을 중개하는 멀티 스레드 기반 게이트웨이 장치의 라우팅 방법에 있어서,
상기 게이트웨이 장치의 복수의 서브 스레드가 상기 클라이언트 단말의 태스크에 대해 상기 타겟 서버로 요청하고, 상기 요청에 대한 응답정보를 파싱하는 단계;
상기 게이트웨이 장치의 메인 스레드가 상기 복수의 서브 스레드로부터 상기 파싱된 응답정보가 수신되면 상기 수신된 응답정보를 이용하여 각 타겟 서버의 에러 응답률을 산출하는 단계;
상기 메인 스레드가 상기 산출된 에러 응답률을 기반으로 라우팅 정책을 설정하는 단계;
상기 메인 스레드가 상기 설정된 라우팅 정책을 상기 복수의 서브 스레드로 전달하는 단계; 및
상기 복수의 서브 스레드가 상기 수신된 라우팅 정책에 따라 라우팅하는 단계;
를 포함하는 라우팅 방법.
In the routing method of a multi-threaded gateway device that mediates communication connections between a plurality of client terminals and a plurality of target servers,
A plurality of sub-threads of the gateway device requesting the target server for a task of the client terminal and parsing response information to the request;
When the main thread of the gateway device receives the parsed response information from the plurality of sub-threads, calculating an error response rate of each target server using the received response information;
setting, by the main thread, a routing policy based on the calculated error response rate;
transmitting, by the main thread, the set routing policy to the plurality of sub-threads; and
routing by the plurality of sub-threads according to the received routing policy;
Routing method containing .
복수의 클라이언트 단말과 복수의 타겟 서버 사이에서 통신 연결을 중개하는 복수의 게이트웨이 장치; 및
상기 복수의 게이트웨이 장치로부터 상기 통신 연결에 대한 라우팅 정책을 수집하고, 상기 수집된 라우팅 정책을 관리하는 API 매니저 장치;를 포함하되,
상기 복수의 게이트웨이 장치 각각은,
상기 클라이언트 단말의 태스크(task)에 대해 상기 타겟 서버에 요청하고, 상기 요청에 대한 응답정보를 파싱(parsing)하는 복수의 서브 스레드; 및
상기 복수의 서브 스레드와 연결되고, 상기 복수의 서브 스레드로부터 상기 파싱된 응답정보가 수신되면 상기 수신된 응답정보를 이용하여 각 타겟 서버의 에러 응답률을 산출하며, 상기 산출된 에러 응답률을 기반으로 상기 라우팅 정책을 설정하고, 상기 설정된 라우팅 정책을 상기 복수의 서브 스레드로 전달하는 메인 스레드;
를 포함하는 라우팅 시스템.
A plurality of gateway devices that mediate communication connections between a plurality of client terminals and a plurality of target servers; and
Including an API manager device that collects routing policies for the communication connection from the plurality of gateway devices and manages the collected routing policies,
Each of the plurality of gateway devices,
a plurality of sub-threads that request the target server for a task of the client terminal and parse response information to the request; and
It is connected to the plurality of sub-threads, and when the parsed response information is received from the plurality of sub-threads, the error response rate of each target server is calculated using the received response information, and the error response rate of each target server is calculated based on the calculated error response rate. a main thread that sets a routing policy and transfers the set routing policy to the plurality of sub-threads;
A routing system that includes.
제 9항에 있어서,
상기 API 매니저 장치는,
상기 복수의 게이트웨이 장치 중 적어도 하나의 게이트웨이 장치가 상기 라우팅 정책을 요청하는 경우, 해당 게이트웨이 장치로 관리 중인 라우팅 정책을 전송하는 것을 특징으로 하는 라우팅 시스템.
According to clause 9,
The API manager device is,
A routing system, wherein when at least one gateway device among the plurality of gateway devices requests the routing policy, the routing policy being managed is transmitted to the corresponding gateway device.
KR1020220156812A 2022-11-21 2022-11-21 Gateway device and method for routing management based on response information KR20240074579A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020220156812A KR20240074579A (en) 2022-11-21 2022-11-21 Gateway device and method for routing management based on response information

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020220156812A KR20240074579A (en) 2022-11-21 2022-11-21 Gateway device and method for routing management based on response information

Publications (1)

Publication Number Publication Date
KR20240074579A true KR20240074579A (en) 2024-05-28

Family

ID=91277115

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020220156812A KR20240074579A (en) 2022-11-21 2022-11-21 Gateway device and method for routing management based on response information

Country Status (1)

Country Link
KR (1) KR20240074579A (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101982578B1 (en) 2018-02-23 2019-05-27 호남대학교 산학협력단 Multi connect gateway system with signal processing of multi-types end device

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101982578B1 (en) 2018-02-23 2019-05-27 호남대학교 산학협력단 Multi connect gateway system with signal processing of multi-types end device

Similar Documents

Publication Publication Date Title
US11394625B2 (en) Service level agreement based storage access
US10791168B1 (en) Traffic aware network workload management system
JP4876170B2 (en) System and method for tracking security enforcement in a grid system
CN110417842B (en) Fault processing method and device for gateway server
US8767535B2 (en) Dynamic feedback control of resources in computing environments
US7773522B2 (en) Methods, apparatus and computer programs for managing performance and resource utilization within cluster-based systems
US10771533B2 (en) Adaptive communication control device
CN108023953B (en) High-availability implementation method and device for FTP service
US20140337493A1 (en) Client/server network environment setup method and system
KR20150132859A (en) Automatic tuning of virtual data center resource utilization policies
JP2016511490A5 (en)
CN108933829A (en) A kind of load-balancing method and device
US20110173319A1 (en) Apparatus and method for operating server using virtualization technique
US20230161541A1 (en) Screen projection method and system
CN112600761A (en) Resource allocation method, device and storage medium
US11587196B2 (en) Information handling system remote desktop protocol selection
WO2020252724A1 (en) Log processing method and device, and computer-readable storage medium
JP2001156838A (en) Method and device for reserving communication resource and recording medium with communication resource reservation program recorded
KR20240074579A (en) Gateway device and method for routing management based on response information
US20170295220A1 (en) Distributed resource management method and system
US20100057914A1 (en) Method, apparatus and system for scheduling contents
US11055079B2 (en) Systems and methods for just-in-time application implementation
CN110166506B (en) Method for connecting hypertext transfer protocol Http and node equipment
US7908364B2 (en) Method storing socket state information in application space for improving communication efficiency of an application program
CN109510864A (en) A kind of retransmission method of cache request, transmission method and relevant apparatus