CN100401259C - Method for providing service in distribution type service system - Google Patents

Method for providing service in distribution type service system Download PDF

Info

Publication number
CN100401259C
CN100401259C CN 200510090749 CN200510090749A CN100401259C CN 100401259 C CN100401259 C CN 100401259C CN 200510090749 CN200510090749 CN 200510090749 CN 200510090749 A CN200510090749 A CN 200510090749A CN 100401259 C CN100401259 C CN 100401259C
Authority
CN
Grant status
Grant
Patent type
Prior art keywords
service
method
providing
distribution
type
Prior art date
Application number
CN 200510090749
Other languages
Chinese (zh)
Other versions
CN1916856A (en )
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
Grant date

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING; 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/44505Configuring for program initiating, e.g. using registry, configuration files

Abstract

本发明提供一种分布式服务系统的服务提供方法,首先确定要使用的扩展接口、公共管理服务以及要提供的具体服务;然后由所述具体服务实现所述扩展接口,并确定各服务的名称与服务主实现;再根据所述各服务的名称与服务主实现,分别生成描述各服务的配置文件;系统通过读取并解析所述配置文件,分别加载各服务的主实现;发布所述公共管理服务,并将要提供的具体服务在公共管理服务上进行注册发布。 The present invention provides a distributed service system service providing method, first determine the expansion interface, public service management and the specific service to be provided to be used; and the expansion interface implemented by the particular service, and to determine the name of each service a main service implementation; then achieved according to the primary service name of each service, generate configuration files for each service description; the system by reading and parsing the configuration file, the main load of each service are implemented; issuing the common management services and specific services to be provided to register posted on the public administration services. 本发明克服现有技术中存在的访问不一致,难于扩展,以及由于服务的添加或者更改造成的巨大连锁反应等问题。 The present invention overcomes the prior art access is inconsistent, difficult to extend, and the addition of services or change a huge chain reaction caused by other issues.

Description

一种分布式服务系统的服务提供方法技术领域本发明涉及一种计算机数据服务提供方法,尤其涉及一种用于分布式服务系统的服务提供方法。 A distributed service system provides services TECHNICAL FIELD The present invention relates to a computer data service providing method, particularly relates to a distributed service system for providing services. 背景技术分布式服务系统就是将服务系统的功能拆分,将各个功能放在几个独立的组件上,通过这几个组件之间的相互协作,来完成整个系统的功能。 BACKGROUND distributed service function of the system is to split the service system, the respective functions on several independent components, through mutual collaboration between these components, to complete the function of the system. 在这里,几个独立的组件可以是指几个独立的CPU,但更通常的是指网络上的几台计算机。 Here, several independent components may refer to several independent CPU, but more generally refers to several computers on a network. 采用分布式系统,最大的优点表现在系统的处理速度上。 Distributed system, the biggest advantage of the performance of the system in the processing speed. 系统的各个功能放在几个独立的组件上,各部分的组件完成自己的功能块,以并行的方式协同工作。 Various functions of the system on several independent components, each component part of the completion of its functional blocks work together in a parallel fashion. 分布式服务系统另外的优点还在于个功能模块分开,便于管理、 维护和更新,服务器的管理维护在大型的服务系统中也是相当重要的。 A further advantage lies in distributed service system functional modules separately, easy to manage, maintain and update the management server to maintain in large service system is also very important. 一个典型的分布式服务系统大致包括以下几部分:表示层,主要负责业务层与用户之间的交流接口和数据传递工作,是唯一一个直接与用户打交道的部分;业务层,是分布式服务系统的心脏,最主要的数据处理工作和服务就由这一部分完成和提供;数据源,主要用于存储数据。 A typical distributed service system generally includes the following sections: AC interface and data transfer work between the presentation layer, the business layer is responsible for the user, it is the only part of a deal directly with the user; business layer is distributed service system the heart, the most important work and data processing services to provide complete and from this part; data source, mainly used to store data. 然而,和运行在一台机器中的服务提供者和使用者相比,分布式系统在服务提供方面具有大得多的复杂性。 However, service and operation of providers and users in a single machine compared to distributed systems in service delivery have much greater complexity. 造成这种复杂性的原因主要有以下几个方面:1、由于系统分布,服务器程序和客户程序很可能不是由同一个开发团队开发,这就造成服务提供者和客户之间的接口不规范,导致互操作困难,当涉及多个服务提供者和客户时,情况就会变得更加糟糕。 The reason for this complexity mainly in the following aspects: 1, due to the distribution system, the server and the client program is probably not developed by the same development team, which resulted in an interface between the service provider and the customer is not standardized, leading to interoperability difficulties when dealing with multiple service providers and customers, the situation will get worse. 2、 正是由于上面所述的不规范性,造成服务的扩展困难。 2, because of irregularity of the above difficulties resulting in extended service. 当由于需求的变化需要增加新的服务或者对现有服务进行更改时,就会造成严重的连锁反应:那些和改动无关的客户(或者服务器)也不得不进行重新的构建和部署。 When the need to increase due to changes in demand for new services or make changes to existing services, it will cause a serious chain reaction: those changes and unrelated customers (or server) also had to be re-built and deployed. 当系统涉及隶属于多个不同公司的开发团队时,这种连锁反应会造成巨大的不必要的浪费。 When the system is part of a number of different companies involved in the development team, this will cause a chain reaction of enormous unnecessary waste. 3、 部署是分布式服务中的一项重要工作,这项工作的难度直接影响到分布式服务发布和升级的工作量。 3, is an important task to deploy distributed services, the difficulty of this work directly affects the distributed service releases and upgrades workload. 遗憾的是,现在有很多服务提供者在需要升级或者提供新的服务时,都不得不重新构建并重启整个系统,这不仅严重影响了服务的可用性,并且也给升级工作带来了很大的工作量。 Unfortunately, there are many service providers in the need to upgrade or to provide new services, had to rebuild and restart the entire system, which not only seriously affected the availability of the service, and also brings a lot of work to upgrade workload. 正是由于上面的这些原因,使得当前很多分布式系统在服务提供方面非常的不一致、难以扩展和部署。 It is for these reasons above, so that the current system offers many distributed service is very inconsistent, hard to scale and deploy. 而开发这些系统的公司和团体也不得不耗费大量的不必要的资金和精力。 The development of these systems of companies and organizations have to spend a lot of unnecessary money and effort. 发明内容本发明所要解决的技术问题在于提供一种分布式服务系统的服务提供方法,克服现有技术中存在的访问不一致,难于扩展,以及由于服务的添加或者更改造成的巨大连锁反应等问题。 The present invention solves the technical problem is to provide a distributed service system service provides ways to overcome visit prior art inconsistent, difficult to extend, and the addition of services or changes caused by the huge chain reaction and other issues. 本发明提供一种分布式服务系统的服务提供方法,包括如下步骤:确定要使用的扩展接口、公共管理服务以及要提供的具体服务;由所述具体服务实现所述扩展接口,并确定各服务的名称与服务主实现;根据所述各服务的名称与服务主实现,分别生成描述各服务的配置文件;系统通过读取并解析所述配置文件,分别加栽各服务的主实现; 发布所述公共管理服务,并将要提供的具体服务在公共管理服务上进行注册发布。 The present invention provides a distributed service system service providing method, comprising the steps of: determining the expansion interface, public administration services, and to provide specific services to be used; specifically, by the service implementation of the expansion interface, and each service is determined the name and service main realization; name of each service to the service master achieved according to generate configuration files for each service description; the system by reading and parsing the configuration file, the primary plant were added to achieve various services; the release said public administration services, and the specific services to be provided to register posted on the public administration services. 优选的,本发明进一步包括如下步骤:公共管理服务根据用户指示确定用户需要获取的具体服务名称; 公共管理服务根据具体服务名称获取该具体服务实体提供给用户使用。 Preferably, the present invention further comprises the steps of: determining a particular service Public Regulated Service User name needs to be acquired according to a user instruction; public service management entity to obtain the specific services provided to a specific user using the service name. 其中,所述通过扩展接口实现服务,并确定服务名称与服务主实现步骤, 进一步包括确定该服务的实现策略的步骤,包括如下步骤:判断并确定该服务需要分解为不同的实现策略;分解问题领域,解析出需要实现的策略组件;确定策略与服务之间的协作方式;实现出与^^务相协作的策略组件。 Wherein said interface service expansion, and to determine the service name of the service and the main realization step further comprising the step of determining the service policy implemented, comprising by the steps of: determining determines that the service and needs to be decomposed into different implementation strategies; Decomposition of field, parse out the need to implement a policy component; determining collaboration between the policies and services; implement a policy component to cooperate with the task of ^^. 其中,所述生成描述各服务的配置文件步骤,所述配置文件进一步包括信息:组成服务的策略名称、策略实现组件,以及策略在服务实现中的组合方式。 Wherein said step of generating a description of each service profile, the profile information further comprises: the service policy name composed of policy implementation component, and a combination service policy implementation. 其中,所述加栽步骤,进一步包括如下步骤:判断并确定所述配置文件中含有策略配置信息;解析出配置文件中的策略实现及其组合方式,并对其进行加载;根据策略的组合方式,将策略实现组合如服务主实现中。 Wherein said step of adding plant, further comprising the steps of: determining the configuration file and determines the policy contains configuration information; configuration file parsing strategy to achieve and combinations, and subjected to load; according to the combination strategy , will serve as the main strategy to achieve a combination of implementation. 采用本发明所述方法,与现有技术相比,提供了一种高效,便捷, 一致, 并且易于扩展的分布式服务提供方法,采用配置文件的方式方便对服务的组织,服务的配置发布不再采用硬编码的方式,而是采用动态加载和控制反转(Inversion of Control)技术使得服务的表示和实现分离,从而可以很方便地实现服务的多样性。 Using the method of the invention, compared to the prior art, it provides an efficient, convenient, consistent, and easily scalable, distributed service providing method using the profile of the way to facilitate the organization and services, configuration services advertised by then hard-coded manner, but dynamic loading and reverse control (inversion of control) technology and services and so indicates separation, which can easily achieve diversity and services. 运用这种方法,可以极大地节省服务开发的时间,可以帮助分布式服务系统构建底层服务管理框架。 Using this method, can greatly save development time service, we can help build a distributed service system underlying service management framework. 由于控制反转的引入,应用对框架不存在直接依赖,提高了服务组件的可测试性,本发明提供的配置文广,实现了服务的可扩展性,访问的一致性,服务实现的多样性,不同类型服务的易配置和易添加性以及动态加栽性。 Since the introduction of inverted control, there is no direct application to rely on the framework to improve the testability of the service components, the present invention provides a wide configuration file, to achieve scalability and services, access to the consistency service to achieve diversity , as well as easy to configure and easy to add dynamic encryption and planted different types of services. 本发明可以提供高度模块化且可动态、增量扩展的服务,特别适合于电信设备管理中EMS (网元管理系统)和NMS (网络管理系统)之间的服务提供方式。 The present invention can provide a highly modular and dynamic, incremental scaling of the service, the telecommunication device is particularly suitable for the management of EMS (Element Management System) and the service between the NMS (Network Management System) mode provides. 附图说明图1为本发明所述的分布式服务系统的服务提供方法流程示意图; 图2为本发明所述的服务实现及配置文件生成过程示意图; 图3为本发明所述的服务加载与发布流程示意图; 图4为为本发明所述的用户使用服务时的流程示意图。 1 shows a distributed service system according to the present service providing a schematic flowchart of a method invention; FIG. 2 is a schematic view of the service configuration and the implementation file generation process invention; loading services according to the present invention and FIG. 3 publishing a schematic flow; FIG. 4 is a schematic flow chart when the service users of the present invention. 具体实施方式如图1所示,为本发明所述的分布式服务提供方法流程示意图。 DETAILED DESCRIPTION As shown in FIG. 1, the distributed service providing method according to the present invention, a schematic flow chart. 首先,确定要使用的扩展接口、公共管理服务以及要提供的具体服务(步骤ioi); 由所述具体服务实现所述扩展接口,并确定各服务的名称与服务主实现(步骤102);根据所述各服务的名称与服务主实现,分别生成描述各服务的配置文件(步骤103);系统通过读取并解析所述配置文件,分别加栽各服务的主实现(步骤104);发布所述公共管理服务,并将要提供的具体服务在公共管理服务上进行注册发布(步骤105 )。 First, the expansion interface, public administration services, and specific services (step IOI) to be provided to be used; specifically, by the service implementation of the expansion interface, the master and determine the name of each service and the service implementation (step 102); The the name of each service and the main service implemented, generate configuration files for each service description (step 103); the system by reading and parsing the configuration file, the main achievement of the plant were added and services (step 104); it is released said public administration services, and the specific services to be provided to register release (step 105) on the management of public services. 此外,如果具体服务还需要不同的实现策略,那么,本发明还可以进而将不同的策略及其组合方式进一步的描述入配置文件,并在服务加栽时,通过读取和解析配置文件,动态的将不同策略组合入服务主实现中。 Also, if a particular service also require different implementation strategies, then, the present invention may further also different combinations and strategies described further into the profile, and when the plant plus the service, by reading and parsing a configuration file, the dynamic the combination of different strategies into the main service implementation. 本发明所使用的扩展接口,是一种运用在框架中的常用技术。 Expansion interface used in the present invention, is a frame used in the conventional techniques. 该技术可以使得接口的功能变得可扩展而不会影响到已有的使用者。 This technique may be such that functional interface becomes scalable without affecting the existing user. 为了达到这个目的,扩展接口技术提供了一个高层的、 一致的抽象服务接口,该接口中定义了用于服务扩展所需要的方法,比如:服务查询等,由具体的服务实现该接口。 To this end, the expansion interface technology provides a high-level, consistent abstract service interface that defines the method for expansion of services required, such as: service inquiries, to implement the interface by a specific service. 本发明所述的具体服务,其在实现时必须要继承上述确定好的扩展接口。 Specific services according to the present invention, it must be implemented when the above determination inherit good expansion interface. 其中,公共管理服务为系统的一项基本服务,在启动时加载和发布,所有其他服务都通过向公共管理服务注册的方式进行发布。 Among them, public service management as a basic service system, load and release at the start, all other services are carried out by way of registration issued to the public administration services. 本发明所述的描述服务的配置文件采用XML格式,其中的信息可以具体涉及服务名称,服务实现主实现组件,组成服务的策略名称和策略实现组件,以及策略在服务实现中的组合方式。 Description of the service profile of the present invention, an XML format, where the information may relate to specific service name, service implementation to achieve the main assembly, consisting of the name of the service policy and the policy implementation component, and a combination service policy implementation. 使用服务描述的配置文件,系统tr 以在运行时动态地加栽并根据策略名称、组合方式等灵活地组装服务,从而可以在对系统其他部分没有任何影响的情况下,扩展和改变服务的内容。 Use the service description configuration file, the system tr content dynamically at run time to add plant and in accordance with the policy name, combinations and other flexible assembly services, which can without any effect on other parts of the system, the expansion and change services . 所述配置文件的描述格式举例如下: <scrvic6reg>〈service name="sample" imp-"sampleServicelmp"〉<strategy name-"strategyl" imp=" strategy limp"means="setStrategyl,, /> <strategy name=,,strategy2,, imp=" strategy2Imp,,means=,,setStrategy2,, /></service> </servicereg>优选的,在生成配置文件后,可以把具体的服务、策略实现以及对应的配置文件,复制到系统指定的目录下,为服务的加栽和启动做准备。 The configuration file format is described for example as follows: <scrvic6reg> <service name = "sample" imp- "sampleServicelmp"> <strategy name- "strategyl" imp = "strategy limp" means = "setStrategyl ,, /> <strategy name = ,, strategy2 ,, imp = "strategy2Imp ,, means = ,, setStrategy2 ,, /> </ service> </ servicereg> preferably, after generating the profile can be specific services, and the corresponding configuration policy implementation file, copied to the specified directory system, to prepare for services plus plant and start. 系统加载、启动并发布服务时,系统在配置目录读取服务配置文件,采用动态加载和控制反转(Inversion Of Control)技术来完成服务的加栽、组装,并通过把服务注册到公共管理服务的方式发布服务。 System load at startup and publishing services, the system reads the configuration directory service configuration file, dynamic loading and Inversion of Control (Inversion Of Control) technology to complete services plus plant, assembly, and service by registering to the Public Regulated Service the way publishing service. 控制反转是这样一种技术,它可以在运行时动态、灵活地建立起组件之间的依赖关系,而组件本身却无需知晓和其建立起关系的其他组件的细节。 Inversion of Control is a technology that can dynamically and flexibly establish dependencies between components at runtime, but it need not know the details of the component itself and its other components to build relationships. 这样就可以使得组件的开发者集中精力于组件本身。 This will enable developers to concentrate on the components of the component itself. 当客户使用服务,客户可以使用一个统一的访问点去获取公共的管理服务。 When customers use the service, customers can use a single access point to manage access to public services. 通过该服务,客户可以通过服务名称查询自己感兴趣的具体服务,如果服务存在,就可以获取并使用该服务了。 Through this service, customers can search for specific services they are interested in by the name of the service, if the service exists, it can obtain and use the services of. 如图2所示,为本发明所述的服务实现及配置文件生成过程示意图。 2, the implementation and service-based profile generation process schematic invention. 首先,由具体的服务实现去扩展事先定义的扩展接口,也就是实现服务实现, 并确定出服务名称(步骤201);然后,判断服务是否需要分解为不同的实现策略(步骤202 ),若步骤202的判断为假,跳至步骤206;若步骤202 的判断为真,则描述服务实现策略(步骤203 ),就是分解问题领域,解析出需要实现的策略组件;描述服务策略组合方式(步骤204),就是确定策略和服务之间的协作方式;实现服务实现策略(步骤205 ),就是实现出与服务协作的策略组件;生成用于服务描述的配置文件(步骤206),就是将上面分析的服务名称,服务实现组件,组成服务的策略名称和策略实现组件, 以及策略在服务实现中的组合方式描述在在配置文件中。 First, by the particular service implementation despread expansion interface defined in advance, i.e. to achieve service implementation, and it is determined that the service name (step 201); then, it is determined whether the service needs to be decomposed into different implementation strategies (step 202), if the step of determination 202 is false, skip to step 206; if the determination in step 202 is true, then the service implementation strategy is described (step 203), the problem is decomposition of the art, the parsed policy component to be achieved; described combination service policy (step 204 ), is to determine the collaboration between the policies and service; service implementation strategy implemented (step 205), the policy is to achieve a cooperation with a service component; generating a profile for a service description (step 206), the analysis above is service names, service implementation component, consisting of service policy name and policy implementation component, as well as combinations of strategies in the service implementation as described in the configuration file. 如图3所示,为本发明所述的服务加栽与发布流程示意图。 3, the service plus a schematic flow diagram of the plant and the release of the present invention. 首先,触发服务加栽动作(步骤301);然后,读取并解析服务配置文件(步骤302); 加栽服务主实现,对从文件中解析出的服务主实现组件,动态加栽(步骤303 );判断服务配置文件中是否有策略配置,就是看服务配置文件中是否有对服务主实现的策略组件配置(步骤304);如果步骤304判断为假,则' 转步骤307;如果步骤304判断为真,则分析并加栽策略实现(步骤305 ), 就是解析出配置文件中的策略组合方式并动态加栽策略实现组件;再把策略实现组合进服务实现主体(步骤306),根据步骤305解析出的策略组合方式,把策略实现组合进服务实现主体;最后把服务实现注册到公共管理服务中(步骤307),公共管理服务在系统启动时发布,所有的其他服务通过在公共管理服务上注册的方式发布。 First, the plant operation plus trigger service (step 301); and then read and parse the service profile (step 302); Master-added services planted on parsed from the file service implemented main component, plus the dynamic plant (step 303 ); if there is determined the service profile policy configuration, is to see whether there is a policy component to the service master implemented configuration (step 304) the service profile; If step 304 evaluates false, the 'go to step 307; if step 304 determines is true, then the analysis of plant and add policy implementation (step 305), the policy is to interpret combinations profile and dynamically added to achieve assembly plant policy; then combined into a service implementation strategy to achieve the main body (step 306), in accordance with step 305 parse out the strategy combination, the strategies to achieve combined into service implementation body; and finally the service implementation to register (step 307), public administration services posted at system startup public administration services, all other services by the public Regulated service Posted registered way. 如图4所示,为本发明所述的用户使用服务时的流程示意图。 4, a schematic flow chart of the service when the user using the present invention. 首先,客户获取公共管理服务(步骤401);然后,客户告知公共管理服务自己想技取的具体服务名称(步骤402);然后,客户使用公共管理服务获取具体服务实体(步骤403 );最后,客户使用具体服务(步骤404)。 First, the client access to public administration services (step 401); The client then inform the specific name of the service (step 402) Public Administration services they want technology taken; then, customers use public administration services for specific services entity (step 403); and finally, customers use specific services (step 404). 下面用JAVA语言实现的一个例子来说明本发明,该例子中采用CORBA作为分布式对象的基础平台。 The following example using a JAVA language to illustrate the present invention, this example uses CORBA distributed object as the basic platform. 首先确定一个扩展接口,在本例中, 这个扩展接口是一个退化接口:interface CommService{};然后我们再确定一个公共管理服务对象: interface ServiceMng{CommService getService(in string servname);};然后再确定一个要实现的服务,例子采用最简单的HelloWorld样例interface HelloworldService: :CommService{ void sayHello();};上述过程可以采用IDL语言进行描述,IDL是用于CORBA协议的接口定义语言,与此相似的,如果采用其他的协议,可是使用其他的定义语言来完成定义。 First determining one expansion interface, in this embodiment, the expansion interface is an interface degradation: interface CommService {}; then we determine a Public Management Service object: interface ServiceMng {CommService getService (in string servname);}; then determining to realize a service, an example of the most simple HelloWorld sample interface HelloworldService:: CommService {void sayHello ();}; IDL language using the above process may be described, for the interface definition language is IDL CORBA protocol, similar to this if you are using other protocols, but use other language to define the complete definition. 进一步,分析该服务实现中是否需要不同的实现策略,例如在本例的服务中,可以采用不同的语言策略。 Further, analysis of the service implementation need different implementation strategies, such as in this case, the service may use different language strategies. 对中文来说,要说:"世界,你好!", 对英文来说,要说:"HelloWorld!",所以,需要两种不同的语言策略。 For the Chinese, I would say: "! Hello world", the English, it would say: "! HelloWorld", therefore, need two different languages ​​strategy. 下面是这两种策略的具体实现。 Here is a concrete implementation of these two strategies. public interface HelloWorld{public String getHello();Public class EnglishHelloworld implements Hello World { public String getHello()( return "Hello World!";public class ChineseHelloWorld implements HelloWorld( public String getHello(){ return "世界,你好!";接着,实现服务,在该月l务实现中,确定了策略的组合方式。public class HelloworldServicelmpl extends HelloworldService POA { private ORB orb = null; private HelloWorld hello; public void setORBEnv(ORB orb) { this.orb = orb;public void sayHello 0 {System.out.println(hello.getHello());Public void setHello(HelloWorld helloworld){ this.hello = helloworld;接下来,生成描述该服务的配置文件,对于英文来说如下: <servicereg〉〈service name=,,HelloWorld" imp=,,HelloworldServiceImpl,,> <strategy name-"language" imp="EnglishHelloworld" means="setHello" /></s6rvic6> </servicereg> 对于中文来说如下: <servicereg>〈service name="HelloWorld" hnp=,,HelloworldService public interface HelloWorld {public String getHello (); Public class EnglishHelloworld implements Hello World {public String getHello () (return "Hello World!"; public class ChineseHelloWorld implements HelloWorld (public String getHello () {return "Hello world!" ; Next, implement the service, the service implementation l month, determines the combination strategy .public class HelloworldServicelmpl extends HelloworldService POA {private ORB orb = null; private HelloWorld hello; public void setORBEnv (ORB orb) {this.orb = orb; public void sayHello 0 {System.out.println (hello.getHello ()); public void setHello (HelloWorld helloworld) {this.hello = helloworld; Next, the configuration file is generated that describes the service, as the English speaking : <servicereg> <service name = ,, HelloWorld "imp = ,, HelloworldServiceImpl ,,> <strategy name-" language "imp =" EnglishHelloworld "means =" ​​setHello "/> </ s6rvic6> </ servicereg> respect to Chinese He said follows: <servicereg> <service name = "HelloWorld" hnp = ,, HelloworldService Impl"><strategy name=,,language,, imp=" ChineseHelloWorld" means=,,setHello,, /></service> </ssrvicereg>对于本例来说,公共管理服务的实现如下: public class ServiceMnglmpl extends ServiceMngPOA{ public CommService getService(String servname) { return services.getservname );public void registerService(String name, CommService srv) { services—.put(name, srv);private Hashtable services— = new Hashtable();系统在加栽HelloWorld服务时,会读取并分析HelloWorld服务的配置文件。 Impl "> <strategy name = ,, language ,, imp =" ChineseHelloWorld "means = ,, setHello ,, /> </ service> </ ssrvicereg> For this example, the implementation of public services management as follows: public class ServiceMnglmpl extends ServiceMngPOA {public CommService getService (String servname) {return services.getservname); public void registerService (String name, CommService srv) {services-.put (name, srv); private Hashtable services- = new Hashtable (); system plus when planted HelloWorld service, it reads and analyzes the configuration file HelloWorld service. 首先动态加栽该服务的主实现HelloworldServicelmpl,然后分析并加栽相应的策略,并根据所配置的组合手段把策略组合进服务实现中,并通过调用公共管理服务ServiceMnglmpl的registerService方法把自己发布出去。 First, dynamic plus planted Lord of the implementation of the service HelloworldServicelmpl, then analyzed and added planted the appropriate strategy, and according to the combination means configured combine policies into the service implementation, and by calling registerService methods of public administration services ServiceMnglmpl of the release out on my own. .客户要访问HelloWorld服务时,首先获得CORBA的命名服务,然后获得公共管理服务ServiceMnglmpl , 调用ServiceMnglmpl 的getService("HdloWorld")方法获得HelloWorld服务。 Customers want to access the HelloWorld service, first obtain the CORBA naming service, and access to public administration services ServiceMnglmpl, call ServiceMnglmpl of getService ( "HdloWorld") method to obtain HelloWorld service.

Claims (8)

  1. 1. 一种分布式服务系统的服务提供方法,其特征在于,包括如下步骤: 确定要使用的扩展接口、公共管理服务以及要提供的具体服务; 由所述具体服务实现所述扩展接口,并确定各服务的名称与服务主实现; 根据所述各服务的名称与服务主实现,分别生成描述各服务的配置文件; 系统通过读取并解析所述配置文件,使用控制反转技术建立起组件之间的依赖关系,分别加载各服务的主实现; 发布所述公共管理服务,并将要提供的具体服务在公共管理服务上进行注册发布。 A distributed service system, the service providing method comprising the steps of: determining the expansion interface, public administration services, and to provide specific services to be used; specifically, by the service implementation of the expansion interface, and determining the name of each service and the main service implementation; the name of the service for each main service implemented according to generate configuration files for each service description; the system by reading and parsing the configuration file, using the established control assembly reversal technique dependencies between, respectively load the main achievement of the services; publishing the public administration services, and the specific services to be provided to register posted on the public administration services.
  2. 2、 如权利要求l所述的方法,其特征在于,进一步包括如下步骤: 公共管理服务根据用户指示确定用户需要获取的具体服务名称; 2. A method as claimed in claim l, characterized by further comprising the steps of: determining a particular service Public Regulated Service User name needs to be acquired according to a user instruction;
  3. 3、 如权利要求1所述的方法,其特征在于,所述通过扩展接口实现服务,并确定服务名称与服务主实现步骤,进一步包括确定该服务的实现策略的步骤,包括:判断并确定该服务需要分解为不同的实现策略;分解问题领域,解析出需要实现的策略组件;确定策略与服务之间的协作方式;实现出与服务相协作的策略组件。 3. The method as claimed in claim 1, characterized in that, by extending the service interface, and to determine the service name and the service main realization step further comprising the step of determining the service implementation strategy, comprising: determining that the determined and services need to be decomposed into different implementation strategies; decomposition problem areas, parse out the need to implement a policy component; determining collaboration between the policies and services; implement a policy component cooperating with the service.
  4. 4、 如权利要求3所述的方法,其特征在于,所述生成描述各服务的配置文件步骤,所述配置文件进一步包括信息:组成服务的策略名称、策略实现组件,以及策略在服务实现中的组合方式。 Component, and a policy in the policy name service implementation composition and services, policy implementation: 4. The method of claim 3, wherein said step of generating a description of each service profile, the profile further comprises information combinations.
  5. 5、 如权利要求1所述的方法,其特征在于,所述生成描述各服务的配置文件步骤后,进一步包括步骤:将具体的服务实现以及对应的配置文件复制到系统指定的目录下,为加载做准备。 After 5, The method as claimed in claim 1, wherein said step of generating the configuration file of the description of the service, further comprising the step of: copying implement specific services and corresponding system configuration file to the specified directory for load preparation.
  6. 6、 如权利要求4所述的方法,其特征在于,所述生成描述各服务的配置文件步骤后,进一步包括步骤:将具体的服务、策略实现以及对应的配置文件复制到系统指定的目录下。 6. The method as claimed in claim 4, wherein said step of generating the configuration file description of each service, further comprising the step of: copying a particular service, policy implementation and corresponding system configuration file to the specified directory .
  7. 7、 如权利要求4所述的方法,其特征在于,所述加载步骤,进一步包括如下步骤:判断并确定所述配置文件中含有策略配置信息;解析出配置文件中的策略实现及其组合方式,并对其进行加载;根据策略的组合方式,将策略实现组合如服务主实现中。 7. The method as claimed in claim 4, wherein said loading step, further comprising the steps of: determining the configuration file and determines the policy contains configuration information; configuration file parsing strategy to achieve and combinations , and subjected to load; according to the combination strategy, the strategy to achieve such a combination of the main service implementation.
  8. 8、 如权利要求1或4所述的方法,其特征在于,所述的配置文件采用XML格式文件描述。 8. A method as claimed in claim 1 or 4, characterized in that said configuration file is described in XML format.
CN 200510090749 2005-08-15 2005-08-15 Method for providing service in distribution type service system CN100401259C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 200510090749 CN100401259C (en) 2005-08-15 2005-08-15 Method for providing service in distribution type service system

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN 200510090749 CN100401259C (en) 2005-08-15 2005-08-15 Method for providing service in distribution type service system
PCT/CN2005/001976 WO2007019745A1 (en) 2005-08-15 2005-11-23 A service providing method of distributed service system

Publications (2)

Publication Number Publication Date
CN1916856A true CN1916856A (en) 2007-02-21
CN100401259C true CN100401259C (en) 2008-07-09

Family

ID=37737857

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 200510090749 CN100401259C (en) 2005-08-15 2005-08-15 Method for providing service in distribution type service system

Country Status (2)

Country Link
CN (1) CN100401259C (en)
WO (1) WO2007019745A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101882073A (en) * 2009-05-04 2010-11-10 谭家辉 Service-oriented application system and communication method, creator and creating method thereof
CN101826987B (en) * 2010-04-27 2012-05-02 北京邮电大学 System and method for supporting mixed service based on integrated open network

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6484214B1 (en) 1998-03-05 2002-11-19 Mcdonnell Douglas Helicopter Company Method for distributed object communications based on dynamically acquired and assembled software components
CN1608248A (en) 2002-01-15 2005-04-20 国际商业机器公司 Provisioning aggregated services in a distributed computing environment

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005512363A (en) * 2001-11-19 2005-04-28 ノキア コーポレイション The provision of location information
US20030191762A1 (en) * 2002-04-08 2003-10-09 Juha Kalliokulju Group management

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6484214B1 (en) 1998-03-05 2002-11-19 Mcdonnell Douglas Helicopter Company Method for distributed object communications based on dynamically acquired and assembled software components
CN1608248A (en) 2002-01-15 2005-04-20 国际商业机器公司 Provisioning aggregated services in a distributed computing environment

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
反转的控制-组件、容器和IoC. 透明.程序员. 2003
基于MFC创建COM组件. 方霞,郭国强.常德师范学院学报(自然科学版),第15卷第1期. 2003

Also Published As

Publication number Publication date Type
WO2007019745A1 (en) 2007-02-22 application
CN1916856A (en) 2007-02-21 application

Similar Documents

Publication Publication Date Title
Schmidt et al. The enterprise service bus: making service-oriented architecture real
Gronmo et al. Model-driven web services development
Slee et al. Thrift: Scalable cross-language services implementation
Bruneton et al. Recursive and dynamic software composition with sharing
US7287037B2 (en) Method and apparatus for generating service oriented state data mapping between extensible meta-data model and state data including logical abstraction
US6907572B2 (en) Command line interface abstraction engine
US7188158B1 (en) System and method for component-based software development
US7627861B2 (en) Methods, systems, and computer program products for identifying computer program source code constructs
Krieger et al. K42: building a complete operating system
US6742015B1 (en) Base services patterns in a netcentric environment
US6529948B1 (en) Multi-object fetch component
US6438594B1 (en) Delivering service to a client via a locally addressable interface
US6332163B1 (en) Method for providing communication services over a computer network system
Pires et al. Building reliable web services compositions
US6842906B1 (en) System and method for a refreshable proxy pool in a communication services patterns environment
US6601234B1 (en) Attribute dictionary in a business logic services environment
US6601192B1 (en) Assertion component in environment services patterns
US6434628B1 (en) Common interface for handling exception interface name with additional prefix and suffix for handling exceptions in environment services patterns
US6571282B1 (en) Block-based communication in a communication services patterns environment
US6640244B1 (en) Request batcher in a transaction services patterns environment
US7289964B1 (en) System and method for transaction services patterns in a netcentric environment
US6529909B1 (en) Method for translating an object attribute converter in an information services patterns environment
US20030061256A1 (en) Method and system for generalized and adaptive transaction processing between uniform information services and applications
US6289382B1 (en) System, method and article of manufacture for a globally addressable interface in a communication services patterns environment
US6549949B1 (en) Fixed format stream in a communication services patterns environment

Legal Events

Date Code Title Description
C06 Publication
C10 Request of examination as to substance
C14 Granted