⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 readme

📁 支持组件模型CCM的开源中间件-mico
💻
字号:
CORBA/EJB Interoperability--------------------------This README describes how to achieve CORBA/EJB interoperability. Morespecifically, the sample code in this directory demonstrates how aMICO client can access an EJB server (the other direction is trivial).The source code in this directory is portable to other conformantCORBA/EJB implementations; the only MICO and Sun EJB specific partsare the tools used to compile, deploy and run the application. Itshould be fairly straight forward to adopt it to other CORBA/EJBimplementations.Prerequisites------------- - Sun's J2EE 1.3.1 - Sun's Java2 JDK 1.3.1_02both can be downloaded for free from java.sun.comNOTE: there is currently an unresolved problem with JDK 1.4.0. Don'tuse this version!Manifest--------Converter.java     : EJB interface of 'Converter'ConverterBean.java : EJB implementation of interface 'Converter'ConverterHome.java : EJB home interface for 'Converter'converter-jar.xml  : XML descriptor for the Java Archive (.jar)converter-ri.xml   : XML descriptor for the Enterprise Archive File (.ear)gen-libejbcpp      : Creates libejbcpp.a; a supporting library                     for the C++ clientclient.cc          : CORBA C++ clientdo-deploy          : Deploys the converter EJB applicationrun-client         : Runs the clientRunning the demo----------------Compile all the necessary binaries by typing "make" in this directory.This will generate the MICO client and the EJB-EAR file. Before youcan run the demo, you need to deploy the EJB-EAR. It is assumed thatthe EJB server is running on localhost. Type 'do-deploy' in thisdirectory to deploy the EJB converter application. Once the server isdeployed, simply type 'run-client' to run the MICO client. The outputof client should be 'Result: 1100'.Comments--------The EJB application implements a stateless entity bean that does some(fake) currency conversions. Look at Converter.java for the beaninterface. The Makefile uses Sun's rmic compiler to generate IDL fromthe Java interface, according to the Java-to-IDL mapping (note that weare _not_ talking about the IDL-to-Java mapping!). Even for the simpleConverter interface, this results in over a dozen(!) IDL interfaces.The MICO client is coded against these IDL interfaces. The shellscript 'gen-libejbcpp' creates a C++ library from the IDLspecifications generated by rmic.The rmic tool is invoked with the command line option -noValueMethods.This inhibits the generation of operations for value types. Doing thisreduces dramatically the number of interfaces that the C++ client hasto worry about.MICO's IDL compiler is invoked with the option -DprimaryKey=primKey.This in effect renames all occurances of 'primaryKey' to 'primKey' inthe IDL specifications. This has to be done because the identifier'primaryKey' clashes with the keyword of the CORBA Component Model,which MICO supports.The EJB server runs an OMG compliant CosNaming server where aninstance of the Converter home interface is registered. Theinteroperable naming service name (INS) for this naming service is:corbaloc::1.2@localhost:1050/NameServiceNote that MICO uses GIOP 1.0 and IIOP 1.0 by default. You need to givethe MICO client the command line options -ORBGIOPVersion 1.2-ORBIIOPVersion 1.2That's it!  Enjoy!

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -