Changes
authorAli Younis <ayounis@uci.edu>
Tue, 16 May 2017 03:05:06 +0000 (20:05 -0700)
committerAli Younis <ayounis@uci.edu>
Tue, 16 May 2017 03:05:06 +0000 (20:05 -0700)
version2/src/java/iotcloud/Table.java
version2/src/java/light_fan_embed_benchmark/LightsController.java
version2/src/java/light_fan_embed_benchmark/Setup.java

index 6348ccc273ed40bb3a5e10bbb49f871f86963841..6a00f82222e374244d1a27dfc0af91f6b924f25d 100644 (file)
@@ -166,6 +166,9 @@ final public class Table {
 
                int livec = 0;
                int deadc = 0;
+
+               int casdasd = 0;
+
                for (long i = o; i < (n + 1); i++) {
                        Slot s = buffer.getSlot(i);
 
@@ -174,6 +177,17 @@ final public class Table {
                        for (Entry e : entries) {
                                if (e.isLive()) {
                                        int type = e.getType();
+
+
+                                       if(type == 6)
+                                       {
+                                               RejectedMessage rej = (RejectedMessage)e;
+                                               casdasd++;
+
+                                               System.out.println(rej.getMachineID());
+                                       }
+
+
                                        types[type] = types[type] + 1;
                                        num++;
                                        livec++;
@@ -244,6 +258,9 @@ final public class Table {
                // Just pull the latest slots from the server
                Slot[] newslots = cloud.getSlots(sequenceNumber + 1);
                validateAndUpdate(newslots, true);
+               sendToServer(null);
+                                       updateLiveTransactionsAndStatus();
+
        }
 
        // public String toString() {
index f810cf58fee61f9ca4994f2e03795a5ca3201507..19c1f72ced2c66b424ea82544e34aac58f11a8a0 100644 (file)
@@ -104,8 +104,10 @@ class LightsController {
                 t1.commitTransaction();
 
 
-                t1.update();
-                Thread.sleep(1000);
+                
+
+                
+                
 
                 for (int i = 0; i < 3; i++) {
                     IoTString testValA1 = t1.getCommitted(keys.get(i));
@@ -116,7 +118,7 @@ class LightsController {
                     }
                 }
 
-                
+                Thread.sleep(1000);
 
             } catch (Error e) {
 
index ab6a231d77ee5ab4219ab26ec2e36b532324ed96..1fb86c89ab291fbc2af5d9d676f5807a0eb8faa6 100644 (file)
@@ -5,7 +5,7 @@ class Setup {
 
     public static void main(String[] args) throws Exception {
 
-        Table t1 = new Table("http://dc-6.calit2.uci.edu/test.iotcloud/", "reallysecret", 300, -1);
+        Table t1 = new Table("http://dc-6.calit2.uci.edu/test.iotcloud/", "reallysecret", 321, -1);
         t1.initTable();