• 初探eXtreme scale


    Note: This document was based on WebSphere Extreme Scale 8.6. It doesn’t supported for lower version on some operate.

    1. Download the extreme scale to your own PC, Extract it to a directry.

    Server Side:

    2. Open a DOS window. And direct to ${xs install home}/bin

    3. Start a catalog server.

                    startXsServer ${catalogServer_name}

    Help info:

       <server> [options]

    --------CatalogServer Arguments-------------------------------

    -catalogServiceEndPoints <server:host:port:port,server:host:port:port>

    -quorum true|false

    -heartbeat 0|1|-1|10|-10

    -clusterSecurityFile <cluster security xml file>

    -clusterSecurityUrl <cluster security xml URL>

    -domain <domain name>

    -transport <ORB|XIO>

    --------Common Arguments-------------------------------

    -listenerHost <hostname>

    -listenerPort <port>

    -serverProps <server properties file>

    -JMXServicePort <port>

    -JMXConnectorPort <port>

    -traceSpec <trace specification>

    -traceFile <trace file>

    -timeout <seconds>

    -script <script file>

    -jvmArgs <JVM arguments>

    Note : The default configuration port is [localhost], the default configuration port is [2809].

    Also multiple endpoints was supported only with separated with ‘,’.

    4. Start a container Server:

    StartXsServer.bat  ${container_Server_name}  -objectgridFile ${file_name or  location} –catalogServiceEndpoints  localhost:2809

    Help info:

    <server> -objectgridFile <xml file> [options]

    <server> -objectgridUrl <xml URL> [options]

    ---------------Container Arguments ---------------------------

    -catalogServiceEndPoints <host:port,host:port>

     -deploymentPolicyFile <deployment policy xml file>

     -deploymentPolicyUrl <deployment policy xml URL>

     -haManagerPort <port>

     -zone <zoneName>
    --------Common Arguments-------------------------------

    -listenerHost <hostname>

    -listenerPort <port>

    -serverProps <server properties file>

    -JMXServicePort <port>

    -JMXConnectorPort <port>

    -traceSpec <trace specification>

    -traceFile <trace file>

    -timeout <seconds>

    -script <script file>

    -jvmArgs <JVM arguments>

     

    Example for objectgrid.xml  & deployment_objectgrid.xml

    Objectgrid.xml

    <?xml version="1.0" encoding="UTF-8"?>
    
    <objectGridConfig xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    
         xsi:schemaLocation="http://ibm.com/ws/objectgrid/config ../objectGrid.xsd" 
    
         xmlns="http://ibm.com/ws/objectgrid/config">
    
        <objectGrids>
    
            <objectGrid name="accounting">
    
                <backingMap name="customer" readOnly="false" copyKey="true"/>
    
            </objectGrid>
    
        </objectGrids>
    
    </objectGridConfig>
    
    


     

    Deployment_objectgrid.xml

    <?xml version="1.0" encoding="UTF-8"?>
    <deploymentPolicy xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xsi:schemaLocation="http://ibm.com/ws/objectgrid/deploymentPolicy ../deploymentPolicy.xsd"
         xmlns="http://ibm.com/ws/objectgrid/deploymentPolicy">
     
         <objectgridDeployment objectgridName="accounting">
                <mapSet name="mapSet1" numberOfPartitions="1" minSyncReplicas="0" maxSyncReplicas="2" 
                        maxAsyncReplicas="1">
                        <map ref="customer"/>
                </mapSet>
         </objectgridDeployment>
    </deploymentPolicy>
    

     

    Client Side: (Java code)

    Condition: ObjectGrid.jar must be approved by version 8.6

    5. Get the ObjectGrid

    ObjectGridManager ogManager = ObjectGridManagerFactory.getObjectGridManager();
    
    ClientClusterContext ccContext = ogManager.connect(“localhost:2809”, null, null);
    
    ObjectGrid og = ogManager.getObjectGrid(ccConext, “accounting”);
    
    


    6. Execute query by object query

    Session session = og.getSession();
    
    ObjectMap customerMap =  session.getMap(“customer”);
    
    String customer = customerMap.get(“0001”);
    
    If(customer==null){
    
                    customerMap.insert(“0001”, ”Insert UserName_Freud”);
    
    }else{
    
                    customerMap.update(“0001”, “Updated UserName_Freud”);
    
    }
    
    Customer = (String) customerMap.get(“0001”);
    
    System.out.println(“The customer Name is : ” + customer);
    
    

    7. Parallel query

                    Waiting to be edit…

    8. Map Agent

    Waiting to be edit…

    9. Add Index

    Waiting to be edit…

    10. Relationship – Cascade (Waiting to be edit…)

    One to one

    One to many

    Many to one

  • 相关阅读:
    codeforces 659F F. Polycarp and Hay(并查集+bfs)
    codeforces 659B B. Qualifying Contest(水题+sort)
    codeforces 659E E. New Reform(图论)
    codeforces 659D D. Bicycle Race(水题)
    sql_mode值的含义
    MySQL Query Cache
    Orchestrator安装
    脚本VIP更改为keepalive
    MHA软件下载地址
    MySQL中的事件调度器EVENT
  • 原文地址:https://www.cnblogs.com/riskyer/p/3268840.html
Copyright © 2020-2023  润新知