With the Enterprise Edition of KonaKart it is possible to configure KonaKart to use RMI versions of the engines. In simple terms, RMI ("Remote Method Invocation") is a way of distributing KonaKart processing over a network rather like SOAP web services but using a different protocol.
This section describes a step-by-step guide to setting up KonaKart on two servers that communicate using RMI.
This guide assumes that we will be setting up KonaKart on two machines (we'll call them chester (our "client") and wolves (our "server")).
On the "client" machine (chester) we will run only the KonaKart application client engine (KKAppEng) which is used by the storefront client and the Admin Application client part. The KKAppEng client engine will communicate with the application engine (KKEng) on the server machine. The Admin Application client will communicate with the Admin Engine (KKAdmin) on the server machine.
The KonaKart application server engine (KKEng) and the KonaKart admin server engine (KKAdmin) will both run on the "server" machine (wolves).
<!-- START: This one for a full konakart.war configuration <plug-in className="com.konakart.plugins.KKEngPlugin"> <set-property property="propertiesPath" value="konakart.properties"/> <set-property property="mode" value="2"/> <set-property property="customersShared" value="false"/> <set-property property="productsShared" value="false"/> <set-property property="definitions-debug" value="2"/> </plug-in> END: This one for a full konakart.war configuration -->
# ----------------------------------------------------------------------------------- # KonaKart engine class used by the KonaKart Application users # # For the default engine use: com.konakart.app.KKEng # For the JAXWS engine use: com.konakart.jws.KKJAXWSEng # For the web services engine use: com.konakart.app.KKWSEng # For the RMI services engine use: com.konakart.rmi.KKRMIEng #konakart.app.engineclass=com.konakart.app.KKEng #konakart.app.engineclass=com.konakart.jws.KKJAXWSEng #konakart.app.engineclass=com.konakart.app.KKWSEng konakart.app.engineclass=com.konakart.rmi.KKRMIEng
# ----------------------------------------------------------------------------------- # RMI Registry Location - This is used to locate (not create) the RMI Registry # The definition for the port that the RMI Registry will listen on is in the web.xml konakart.rmi.host = wolves konakart.rmi.port = 8790
# ---------------------------------------------------------------------- # KonaKart engine class used by the KonaKart Admin Application users # # For the default engine use: com.konakartadmin.bl.KKAdmin # For the web services engine use: com.konakartadmin.ws.KKWSAdmin # For the RMI services engine use: com.konakartadmin.rmi.KKRMIAdminEng # For the JSON services engine use: com.konakartadmin.json.KKJSONAdminEng #konakartadmin.gwt.engineclass=com.konakartadmin.bl.KKAdmin #konakartadmin.gwt.engineclass=com.konakartadmin.ws.KKWSAdmin konakartadmin.gwt.engineclass=com.konakartadmin.rmi.KKRMIAdminEng #konakartadmin.gwt.engineclass=com.konakartadmin.json.KKJSONAdminEng
# ----------------------------------------------------------------------------------- # RMI Registry Location - This is used to locate (not create) the RMI Registry # The definition for the port that the RMI Registry will listen on is in the web.xml konakart.rmi.host = wolves konakart.rmi.port = 8790
<!-- RMI Server --> <servlet> <servlet-name>KonakartRMIServlet</servlet-name> <display-name>KonaKart RMI Server</display-name> <description>KonaKart RMI Server</description> <servlet-class> com.konakart.rmi.KKRMIServer </servlet-class> <init-param> <param-name>port</param-name> <param-value>8790</param-value> </init-param> <init-param> <param-name>rmiEnabled</param-name> <param-value>true</param-value> </init-param> <load-on-startup>20</load-on-startup> </servlet> <!-- End of RMI Server -->
<!-- RMI Server --> <servlet> <servlet-name>KonakartAdminRMIServlet</servlet-name> <display-name>KonaKartAdmin RMI Server</display-name> <description>KonaKartAdmin RMI Server</description> <servlet-class> com.konakartadmin.rmi.KKRMIAdminServer </servlet-class> <init-param> <param-name>port</param-name> <param-value>8790</param-value> </init-param> <init-param> <param-name>rmiEnabled</param-name> <param-value>true</param-value> </init-param> <load-on-startup>20</load-on-startup> </servlet> <!-- End of RMI Server -->