ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject incubator-ignite git commit: ignite-471-2: yardstick config
Date Fri, 05 Jun 2015 09:42:47 GMT
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-471-2 9ede9f46f -> 384c3adbc


ignite-471-2: yardstick config


Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/384c3adb
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/384c3adb
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/384c3adb

Branch: refs/heads/ignite-471-2
Commit: 384c3adbcd0734690fb07aef2f9f851619c6c565
Parents: 9ede9f4
Author: Denis Magda <dmagda@gridgain.com>
Authored: Fri Jun 5 12:42:34 2015 +0300
Committer: Denis Magda <dmagda@gridgain.com>
Committed: Fri Jun 5 12:42:34 2015 +0300

----------------------------------------------------------------------
 modules/yardstick/config/ignite-base-config.xml | 87 +++++++++++++++++---
 .../yardstick/cache/model/Organization.java     | 14 +---
 .../ignite/yardstick/cache/model/Person.java    | 20 +----
 3 files changed, 77 insertions(+), 44 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/384c3adb/modules/yardstick/config/ignite-base-config.xml
----------------------------------------------------------------------
diff --git a/modules/yardstick/config/ignite-base-config.xml b/modules/yardstick/config/ignite-base-config.xml
index 9d28774..cd57edc 100644
--- a/modules/yardstick/config/ignite-base-config.xml
+++ b/modules/yardstick/config/ignite-base-config.xml
@@ -112,13 +112,39 @@
 
                     <property name="swapEnabled" value="false"/>
 
-                    <property name="indexedTypes">
+                    <property name="typeMetadata">
                         <list>
-                            <value>java.lang.Integer</value>
-                            <value>org.apache.ignite.yardstick.cache.model.Organization</value>
-
-                            <value>java.lang.Integer</value>
-                            <value>org.apache.ignite.yardstick.cache.model.Person</value>
+                            <bean class="org.apache.ignite.cache.CacheTypeMetadata">
+                                <property name="keyType" value="java.lang.Integer"/>
+                                <property name="valueType" value="org.apache.ignite.yardstick.cache.model.Organization"/>
+
+                                <property name="ascendingFields">
+                                    <map>
+                                        <entry key="id" value="java.lang.Integer"/>
+                                        <entry key="name" value="java.lang.String"/>
+                                    </map>
+                                </property>
+                            </bean>
+
+                            <bean class="org.apache.ignite.cache.CacheTypeMetadata">
+                                <property name="keyType" value="java.lang.Integer"/>
+                                <property name="valueType" value="org.apache.ignite.yardstick.cache.model.Person"/>
+
+                                <property name="ascendingFields">
+                                    <map>
+                                        <entry key="id" value="java.lang.Integer"/>
+                                        <entry key="orgId" value="java.lang.Integer"/>
+                                        <entry key="salary" value="java.lang.Double"/>
+                                    </map>
+                                </property>
+
+                                <property name="queryFields">
+                                    <map>
+                                        <entry key="firstName" value="java.lang.String"/>
+                                        <entry key="lastName" value="java.lang.String"/>
+                                    </map>
+                                </property>
+                            </bean>
                         </list>
                     </property>
                 </bean>
@@ -134,13 +160,39 @@
 
                     <property name="memoryMode" value="OFFHEAP_TIERED"/>
 
-                    <property name="indexedTypes">
+                    <property name="typeMetadata">
                         <list>
-                            <value>java.lang.Integer</value>
-                            <value>org.apache.ignite.yardstick.cache.model.Organization</value>
-
-                            <value>java.lang.Integer</value>
-                            <value>org.apache.ignite.yardstick.cache.model.Person</value>
+                            <bean class="org.apache.ignite.cache.CacheTypeMetadata">
+                                <property name="keyType" value="java.lang.Integer"/>
+                                <property name="valueType" value="org.apache.ignite.yardstick.cache.model.Organization"/>
+
+                                <property name="ascendingFields">
+                                    <map>
+                                        <entry key="id" value="java.lang.Integer"/>
+                                        <entry key="name" value="java.lang.String"/>
+                                    </map>
+                                </property>
+                            </bean>
+
+                            <bean class="org.apache.ignite.cache.CacheTypeMetadata">
+                                <property name="keyType" value="java.lang.Integer"/>
+                                <property name="valueType" value="org.apache.ignite.yardstick.cache.model.Person"/>
+
+                                <property name="ascendingFields">
+                                    <map>
+                                        <entry key="id" value="java.lang.Integer"/>
+                                        <entry key="orgId" value="java.lang.Integer"/>
+                                        <entry key="salary" value="java.lang.Double"/>
+                                    </map>
+                                </property>
+
+                                <property name="queryFields">
+                                    <map>
+                                        <entry key="firstName" value="java.lang.String"/>
+                                        <entry key="lastName" value="java.lang.String"/>
+                                    </map>
+                                </property>
+                            </bean>
                         </list>
                     </property>
                 </bean>
@@ -163,6 +215,17 @@
             <list/>
         </property>
 
+        <property name="marshaller">
+            <bean class="org.gridgain.grid.marshaller.portable.PortableMarshaller">
+                <property name="classNames">
+                    <list>
+                        <value>org.apache.ignite.yardstick.cache.model.*</value>
+                    </list>
+                </property>
+                <property name="metaDataEnabled" value="false" />
+            </bean>
+        </property>
+
         <property name="loadBalancingSpi">
             <bean class="org.apache.ignite.spi.loadbalancing.roundrobin.RoundRobinLoadBalancingSpi">
                 <property name="perTask" value="false"/>

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/384c3adb/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Organization.java
----------------------------------------------------------------------
diff --git a/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Organization.java
b/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Organization.java
index d8bba98..2c9f01c 100644
--- a/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Organization.java
+++ b/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Organization.java
@@ -24,7 +24,7 @@ import java.io.*;
 /**
  * Organization record used for query test.
  */
-public class Organization implements Externalizable {
+public class Organization {
     /** Organization ID. */
     @QuerySqlField(index = true)
     private int id;
@@ -80,18 +80,6 @@ public class Organization implements Externalizable {
     }
 
     /** {@inheritDoc} */
-    @Override public void writeExternal(ObjectOutput out) throws IOException {
-        out.writeInt(id);
-        out.writeUTF(name);
-    }
-
-    /** {@inheritDoc} */
-    @Override public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
{
-        id = in.readInt();
-        name = in.readUTF();
-    }
-
-    /** {@inheritDoc} */
     @Override public boolean equals(Object o) {
         return this == o || (o instanceof Organization) && id == ((Organization)o).id;
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/384c3adb/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Person.java
----------------------------------------------------------------------
diff --git a/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Person.java
b/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Person.java
index df8d58b..461da49 100644
--- a/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Person.java
+++ b/modules/yardstick/src/main/java/org/apache/ignite/yardstick/cache/model/Person.java
@@ -24,7 +24,7 @@ import java.io.*;
 /**
  * Person record used for query test.
  */
-public class Person implements Externalizable {
+public class Person {
     /** Person ID. */
     @QuerySqlField(index = true)
     private int id;
@@ -152,24 +152,6 @@ public class Person implements Externalizable {
     }
 
     /** {@inheritDoc} */
-    @Override public void writeExternal(ObjectOutput out) throws IOException {
-        out.writeInt(id);
-        out.writeInt(orgId);
-        out.writeUTF(firstName);
-        out.writeUTF(lastName);
-        out.writeDouble(salary);
-    }
-
-    /** {@inheritDoc} */
-    @Override public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
{
-        id = in.readInt();
-        orgId = in.readInt();
-        firstName = in.readUTF();
-        lastName = in.readUTF();
-        salary = in.readDouble();
-    }
-
-    /** {@inheritDoc} */
     @Override public boolean equals(Object o) {
         return this == o || (o instanceof Person) && id == ((Person)o).id;
     }


Mime
View raw message