You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by jl...@apache.org on 2014/11/16 14:48:45 UTC

svn commit: r1639986 - in /ofbiz/branches/release12.04: ./ applications/order/ framework/base/ framework/bi/ framework/entity/src/org/ofbiz/entity/test/ framework/sql/ framework/start/ specialpurpose/shark/

Author: jleroux
Date: Sun Nov 16 13:48:45 2014
New Revision: 1639986

URL: http://svn.apache.org/r1639986
Log:
Forces the branch 12 to use Java 1.7
This is related with the Poodle vulnerability which requires to use Java 1.7
Thanks to Nicolas Malin's patch for "Poodle-disable sslv3" https://issues.apache.org/jira/browse/OFBIZ-5848
Nicolas adapted the EntityTestSuite to work with Java 1.7

Modified:
    ofbiz/branches/release12.04/applications/order/build.xml
    ofbiz/branches/release12.04/build.xml
    ofbiz/branches/release12.04/common.xml
    ofbiz/branches/release12.04/framework/base/build.xml
    ofbiz/branches/release12.04/framework/bi/build.xml
    ofbiz/branches/release12.04/framework/entity/src/org/ofbiz/entity/test/EntityTestSuite.java
    ofbiz/branches/release12.04/framework/sql/build.xml
    ofbiz/branches/release12.04/framework/start/build.xml
    ofbiz/branches/release12.04/macros.xml
    ofbiz/branches/release12.04/specialpurpose/shark/build.xml

Modified: ofbiz/branches/release12.04/applications/order/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/applications/order/build.xml?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/applications/order/build.xml (original)
+++ ofbiz/branches/release12.04/applications/order/build.xml Sun Nov 16 13:48:45 2014
@@ -56,10 +56,10 @@ under the License.
     <!-- ================================================================== -->
 
     <target name="classes" depends="prepare">
-        <javac16>
+        <javac17>
             <!-- exclude the payment processor packages; comment if you have libs -->
             <exclude name="org/ofbiz/order/thirdparty/taxware/**"/>
-        </javac16>
+        </javac17>
     </target>
 
     <target name="jar" depends="classes">

Modified: ofbiz/branches/release12.04/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/build.xml?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/build.xml (original)
+++ ofbiz/branches/release12.04/build.xml Sun Nov 16 13:48:45 2014
@@ -1050,8 +1050,8 @@ under the License.
         <sonar:sonar key="org.apache:ofbiz" version="${info.entry.commit(revision)}" xmlns:sonar="antlib:org.sonar.ant:sonar"/>
         <property name="sonar.dynamicAnalysis" value="reuseReports" />
         <property name="sonar.cobertura.reportPath" value="runtime/logs/cobertura-report/coverage.xml"/>
-        <property name="sonar.java.source" value="1.6" />
-        <property name="sonar.java.target" value="1.6" />
+        <property name="sonar.java.source" value="1.7" />
+        <property name="sonar.java.target" value="1.7" />
         <!-- default for jdbc url: jdbc:mysql://localhost:3306/sonar?useUnicode=true&amp;characterEncoding=utf8-->
         <property name="sonar.jdbc.url" value="${sonar.jdbc.url}"/>
         <property name="sonar.jdbc.driverClassName" value="com.mysql.jdbc.Driver" />

Modified: ofbiz/branches/release12.04/common.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/common.xml?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/common.xml (original)
+++ ofbiz/branches/release12.04/common.xml Sun Nov 16 13:48:45 2014
@@ -88,7 +88,7 @@ under the License.
     <!-- ================================================================== -->
 
     <target name="classes" depends="prepare">
-        <javac16/>
+        <javac17/>
     </target>
 
     <target name="jar" depends="classes">

Modified: ofbiz/branches/release12.04/framework/base/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/framework/base/build.xml?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/framework/base/build.xml (original)
+++ ofbiz/branches/release12.04/framework/base/build.xml Sun Nov 16 13:48:45 2014
@@ -87,7 +87,7 @@ under the License.
     </target>
 
     <target name="classes" depends="prepare,gen-src">
-        <javac16/>
+        <javac17/>
     </target>
 
     <target name="jar" depends="classes">

Modified: ofbiz/branches/release12.04/framework/bi/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/framework/bi/build.xml?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/framework/bi/build.xml (original)
+++ ofbiz/branches/release12.04/framework/bi/build.xml Sun Nov 16 13:48:45 2014
@@ -46,6 +46,6 @@ under the License.
     <!-- ================================================================== -->
 
     <target name="classes" depends="prepare">
-        <javac16 classpathref="local.class.path"/>
+        <javac17 classpathref="local.class.path"/>
     </target>
 </project>

Modified: ofbiz/branches/release12.04/framework/entity/src/org/ofbiz/entity/test/EntityTestSuite.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/framework/entity/src/org/ofbiz/entity/test/EntityTestSuite.java?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/framework/entity/src/org/ofbiz/entity/test/EntityTestSuite.java (original)
+++ ofbiz/branches/release12.04/framework/entity/src/org/ofbiz/entity/test/EntityTestSuite.java Sun Nov 16 13:48:45 2014
@@ -68,25 +68,28 @@ public class EntityTestSuite extends Ent
     }
 
     final static private int _level1max = 3;   // number of TestingNode entities to create
-    
+
     /*
      * Tests storing values with the delegator's .create, .makeValue, and .storeAll methods
      */
     public void testMakeValue() throws Exception {
         // This method call directly stores a new value into the entity engine
-        delegator.create("TestingType", "testingTypeId", "TEST-1", "description", "Testing Type #1");
+        GenericValue createdValue = delegator.create("TestingType", "testingTypeId", "TEST-MAKE-1", "description", "Testing Type #Make-1");
+        assertTrue("Created value is mutable", createdValue.isMutable());
+        assertFalse("Observable has not changed", createdValue.hasChanged());
 
         // This sequence creates the GenericValue entities first, puts them in a List, then calls the delegator to store them all
         List<GenericValue> newValues = new LinkedList<GenericValue>();
 
-        newValues.add(delegator.makeValue("TestingType", "testingTypeId", "TEST-2", "description", "Testing Type #2"));
-        newValues.add(delegator.makeValue("TestingType", "testingTypeId", "TEST-3", "description", "Testing Type #3"));
-        newValues.add(delegator.makeValue("TestingType", "testingTypeId", "TEST-4", "description", "Testing Type #4"));
+        newValues.add(delegator.makeValue("TestingType", "testingTypeId", "TEST-MAKE-2", "description", "Testing Type #Make-2"));
+        newValues.add(delegator.makeValue("TestingType", "testingTypeId", "TEST-MAKE-3", "description", "Testing Type #Make-3"));
+        newValues.add(delegator.makeValue("TestingType", "testingTypeId", "TEST-MAKE-4", "description", "Testing Type #Make-4"));
         delegator.storeAll(newValues);
 
         // finds a List of newly created values.  the second parameter specifies the fields to order results by.
-        List<GenericValue> newlyCreatedValues = delegator.findList("TestingType", null, null, UtilMisc.toList("testingTypeId"), null, false);
-        assertEquals("4 TestingTypes found", 4, newlyCreatedValues.size());
+        EntityCondition condition = EntityCondition.makeCondition("testingTypeId", EntityOperator.LIKE, "TEST-MAKE-%");
+        List<GenericValue> newlyCreatedValues = delegator.findList("TestingType", condition, null, UtilMisc.toList("testingTypeId"), null, false);
+        assertEquals("4 TestingTypes(for make) found", 4, newlyCreatedValues.size());
     }
 
     /*
@@ -94,20 +97,28 @@ public class EntityTestSuite extends Ent
      */
     public void testUpdateValue() throws Exception {
         // retrieve a sample GenericValue, make sure it's correct
-        GenericValue testValue = delegator.findOne("TestingType", false, "testingTypeId", "TEST-1");
-        assertEquals("Retrieved value has the correct description", "Testing Type #1", testValue.getString("description"));
-        testValue.put("description", "New Testing Type #1");
+        delegator.removeByCondition("TestingType", EntityCondition.makeCondition("testingTypeId", EntityOperator.LIKE, "TEST-UPDATE-%"));
+        GenericValue testValue = delegator.findOne("TestingType", false, "testingTypeId", "TEST-UPDATE-1");
+        assertNull("No pre-existing type value", testValue);
+        delegator.create("TestingType", "testingTypeId", "TEST-UPDATE-1", "description", "Testing Type #Update-1");
+        testValue = delegator.findOne("TestingType", false, "testingTypeId", "TEST-UPDATE-1");
+        assertEquals("Retrieved value has the correct description", "Testing Type #Update-1", testValue.getString("description"));
+        testValue.set("description", "New Testing Type #Update-1");
         // now store it
         testValue.store();
         // now retrieve it again and make sure that the updated value is correct
-        testValue = delegator.findOne("TestingType", false, "testingTypeId", "TEST-1");
-        assertEquals("Retrieved value has the correct description", "New Testing Type #1", testValue.getString("description"));
+        testValue = delegator.findOne("TestingType", false, "testingTypeId", "TEST-UPDATE-1");
+        assertEquals("Retrieved value has the correct description", "New Testing Type #Update-1", testValue.getString("description"));
     }
 
     public void testRemoveValue() throws Exception {
         // Retrieve a sample GenericValue, make sure it's correct
-        GenericValue testValue = delegator.findOne("TestingType", false, "testingTypeId", "TEST-4");
-        assertEquals("Retrieved value has the correct description", "Testing Type #4", testValue.getString("description"));
+        delegator.removeByCondition("TestingType", EntityCondition.makeCondition("testingTypeId", EntityOperator.LIKE, "TEST-REMOVE-%"));
+        GenericValue testValue = delegator.findOne("TestingType", false, "testingTypeId", "TEST-REMOVE-1");
+        assertNull("No pre-existing type value", testValue);
+        delegator.create("TestingType", "testingTypeId", "TEST-REMOVE-1", "description", "Testing Type #Remove-1");
+        testValue = delegator.findOne("TestingType", false, "testingTypeId", "TEST-REMOVE-1");
+        assertEquals("Retrieved value has the correct description", "Testing Type #Remove-1", testValue.getString("description"));
         testValue.remove();
         // Test immutable
         try {
@@ -129,11 +140,16 @@ public class EntityTestSuite extends Ent
      */
     public void testEntityCache() throws Exception {
         // Test primary key cache
-        GenericValue testValue = delegator.findOne("TestingType", true, "testingTypeId", "TEST-3");
-        assertEquals("Retrieved from cache value has the correct description", "Testing Type #3", testValue.getString("description"));
+        delegator.removeByCondition("TestingType", EntityCondition.makeCondition("testingTypeId", EntityOperator.LIKE, "TEST-CACHE-%"));
+        delegator.removeByCondition("TestingSubtype", EntityCondition.makeCondition("testingTypeId", EntityOperator.LIKE, "TEST-CACHE-%"));
+        GenericValue testValue = delegator.findOne("TestingType", true, "testingTypeId", "TEST-CACHE-1");
+        assertNull("No pre-existing type value", testValue);
+        delegator.create("TestingType", "testingTypeId", "TEST-CACHE-1", "description", "Testing Type #Cache-1");
+        testValue = delegator.findOne("TestingType", true, "testingTypeId", "TEST-CACHE-1");
+        assertEquals("Retrieved from cache value has the correct description", "Testing Type #Cache-1", testValue.getString("description"));
         // Test immutable
         try {
-            testValue.put("description", "New Testing Type #3");
+            testValue.put("description", "New Testing Type #Cache-1");
             fail("Modified an immutable GenericValue");
         } catch (IllegalStateException e) {
         }
@@ -144,21 +160,22 @@ public class EntityTestSuite extends Ent
         }
         // Test entity value update operation updates the cache
         testValue = (GenericValue) testValue.clone();
-        testValue.put("description", "New Testing Type #3");
+        testValue.put("description", "New Testing Type #Cache-1");
         testValue.store();
-        testValue = delegator.findOne("TestingType", true, "testingTypeId", "TEST-3");
-        assertEquals("Retrieved from cache value has the correct description", "New Testing Type #3", testValue.getString("description"));
+        testValue = delegator.findOne("TestingType", true, "testingTypeId", "TEST-CACHE-1");
+        assertEquals("Retrieved from cache value has the correct description", "New Testing Type #Cache-1", testValue.getString("description"));
         // Test entity value remove operation updates the cache
         testValue = (GenericValue) testValue.clone();
         testValue.remove();
-        testValue = delegator.findOne("TestingType", true, "testingTypeId", "TEST-3");
+        testValue = delegator.findOne("TestingType", true, "testingTypeId", "TEST-CACHE-1");
         assertEquals("Retrieved from cache value is null", null, testValue);
         // Test entity condition cache
-        EntityCondition testCondition = EntityCondition.makeCondition("description", EntityOperator.EQUALS, "Testing Type #2");
+        delegator.create("TestingType", "testingTypeId", "TEST-CACHE-2", "description", "Testing Type #Cache-2");
+        EntityCondition testCondition = EntityCondition.makeCondition("description", EntityOperator.EQUALS, "Testing Type #Cache-2");
         List<GenericValue> testList = delegator.findList("TestingType", testCondition, null, null, null, true);
         assertEquals("Delegator findList returned one value", 1, testList.size());
         testValue = testList.get(0);
-        assertEquals("Retrieved from cache value has the correct description", "Testing Type #2", testValue.getString("description"));
+        assertEquals("Retrieved from cache value has the correct description", "Testing Type #Cache-2", testValue.getString("description"));
         // Test immutable
         try {
             testValue.put("description", "New Testing Type #2");
@@ -172,12 +189,12 @@ public class EntityTestSuite extends Ent
         }
         // Test entity value create operation updates the cache
         testValue = (GenericValue) testValue.clone();
-        testValue.put("testingTypeId", "TEST-9");
+        testValue.put("testingTypeId", "TEST-CACHE-3");
         testValue.create();
         testList = delegator.findList("TestingType", testCondition, null, null, null, true);
         assertEquals("Delegator findList returned two values", 2, testList.size());
         // Test entity value update operation updates the cache
-        testValue.put("description", "New Testing Type #2");
+        testValue.put("description", "New Testing Type #Cache-3");
         testValue.store();
         testList = delegator.findList("TestingType", testCondition, null, null, null, true);
         assertEquals("Delegator findList returned one value", 1, testList.size());
@@ -188,19 +205,21 @@ public class EntityTestSuite extends Ent
         testList = delegator.findList("TestingType", testCondition, null, null, null, true);
         assertEquals("Delegator findList returned empty list", 0, testList.size());
         // Test view entities in the pk cache - updating an entity should clear pk caches for all view entities containing that entity.
-        testValue = delegator.create("TestingSubtype", "testingTypeId", "TEST-9", "subtypeDescription", "Testing Subtype #9");
+        testValue = delegator.findOne("TestingSubtype", true, "testingTypeId", "TEST-CACHE-3");
+        assertNull("No pre-existing TestingSubtype", testValue);
+        testValue = delegator.create("TestingSubtype", "testingTypeId", "TEST-CACHE-3", "subtypeDescription", "Testing Subtype #Cache-3");
         assertNotNull("TestingSubtype created", testValue);
         // Confirm member entity appears in the view
-        testValue = delegator.findOne("TestingViewPks", true, "testingTypeId", "TEST-9");
-        assertEquals("View retrieved from cache has the correct member description", "Testing Subtype #9", testValue.getString("subtypeDescription"));
-        testValue = delegator.findOne("TestingSubtype", true, "testingTypeId", "TEST-9");
+        testValue = delegator.findOne("TestingViewPks", true, "testingTypeId", "TEST-CACHE-3");
+        assertEquals("View retrieved from cache has the correct member description", "Testing Subtype #Cache-3", testValue.getString("subtypeDescription"));
+        testValue = delegator.findOne("TestingSubtype", true, "testingTypeId", "TEST-CACHE-3");
         // Modify member entity
         testValue = (GenericValue) testValue.clone();
-        testValue.put("subtypeDescription", "New Testing Subtype #9");
+        testValue.put("subtypeDescription", "New Testing Subtype #Cache-3");
         testValue.store();
         // Check if cached view contains the modification
-        testValue = delegator.findOne("TestingViewPks", true, "testingTypeId", "TEST-9");
-        assertEquals("View retrieved from cache has the correct member description", "New Testing Subtype #9", testValue.getString("subtypeDescription"));
+        testValue = delegator.findOne("TestingViewPks", true, "testingTypeId", "TEST-CACHE-3");
+        assertEquals("View retrieved from cache has the correct member description", "New Testing Subtype #Cache-3", testValue.getString("subtypeDescription"));
     }
 
     /*
@@ -282,6 +301,10 @@ public class EntityTestSuite extends Ent
      * More tests of storing data with .storeAll.  Also prepares data for testing view-entities (see below.)
      */
     public void testAddMembersToTree() throws Exception {
+        delegator.removeByCondition("TestingType", EntityCondition.makeCondition("testingTypeId", EntityOperator.LIKE, "TEST-TREE-%"));
+        GenericValue testValue = delegator.findOne("TestingType", true, "testingTypeId", "TEST-TREE-1");
+        assertNull("No pre-existing type value", testValue);
+        delegator.create("TestingType", "testingTypeId", "TEST-TREE-1", "description", "Testing Type #Tree-1");
         // get the level1 nodes
         EntityCondition isLevel1 = EntityCondition.makeCondition("primaryParentNodeId", EntityOperator.NOT_EQUAL, GenericEntity.NULL_FIELD);
         List<GenericValue> nodeLevel1 = delegator.findList("TestingNode", isLevel1, null, null, null, false);
@@ -292,7 +315,7 @@ public class EntityTestSuite extends Ent
         for (GenericValue node: nodeLevel1) {
             GenericValue testing = delegator.makeValue("Testing",
                             "testingId", delegator.getNextSeqId("Testing"),
-                            "testingTypeId", "TEST-1"
+                            "testingTypeId", "TEST-TREE-1"
                    );
             testing.put("testingName", "leaf-#" + node.getString("testingNodeId"));
             testing.put("description", "level1 leaf");
@@ -315,32 +338,13 @@ public class EntityTestSuite extends Ent
         assertEquals("Created/Stored Nodes", newValues.size(), n);
     }
 
-    protected void createNodeMembers(String typeId, String typeDescription, String descriptionPrefix) throws GenericEntityException {
-        delegator.removeByCondition("TestingType", EntityCondition.makeCondition("testingTypeId", EntityOperator.EQUALS, typeId));
-        delegator.create("TestingType", "testingTypeId", typeId, "description", typeDescription);
-        int i = 0;
-        Timestamp now = UtilDateTime.nowTimestamp();
-        for (GenericValue node: delegator.findList("TestingNode", EntityCondition.makeCondition("description", EntityOperator.LIKE, descriptionPrefix + "%"), null, null, null, false)) {
-            if (i % 2 == 0) {
-                GenericValue testing = delegator.create("Testing", "testingId", descriptionPrefix + ":" + node.get("testingNodeId"), "testingTypeId", typeId, "description", node.get("description"));
-                GenericValue member = delegator.makeValue("TestingNodeMember",
-                    "testingNodeId", node.get("testingNodeId"),
-                    "testingId", testing.get("testingId")
-                );
-
-                member.put("fromDate", now);
-                member.put("thruDate", UtilDateTime.getNextDayStart(now));
-                member.create();
-            }
-            i++;
-        }
-    }
-
     /*
      * Tests findByCondition and tests searching on a view-entity
      */
     public void testCountViews() throws Exception {
-        EntityCondition isNodeWithMember = EntityCondition.makeCondition("testingId", EntityOperator.NOT_EQUAL, GenericEntity.NULL_FIELD);
+        flushAndRecreateTree("countviews");
+        createNodeMembersForEach("TEST-COUNT", "count-views-testing", "countviews");
+        EntityCondition isNodeWithMember = EntityCondition.makeCondition("description", EntityOperator.LIKE, "countviews%");
         List<GenericValue> nodeWithMembers = delegator.findList("TestingNodeAndMember", isNodeWithMember, null, null, null, false);
 
         for (GenericValue v: nodeWithMembers) {
@@ -353,7 +357,8 @@ public class EntityTestSuite extends Ent
                 Debug.logInfo(field.toString() + " = " + ((value == null) ? "[null]" : value), module);
             }
         }
-        long testingcount = delegator.findCountByCondition("Testing", null, null, null);
+        EntityCondition isMember = EntityCondition.makeCondition("testingTypeId", "TEST-COUNT");
+        long testingcount = delegator.findCountByCondition("Testing", isMember, null, null);
         assertEquals("Number of views should equal number of created entities in the test.", testingcount, nodeWithMembers.size());
     }
 
@@ -431,7 +436,7 @@ public class EntityTestSuite extends Ent
     /*
      * Tests foreign key integrity by trying to remove an entity which has foreign-key dependencies.  Should cause an exception.
      */
-    public void testForeignKeyRemove() {
+    public void testForeignKeyRemove() throws Exception {
         try {
             String helperName = delegator.getEntityHelper("TestingNode").getHelperName();
             DatasourceInfo datasourceInfo = EntityConfigUtil.getDatasourceInfo(helperName);
@@ -442,13 +447,20 @@ public class EntityTestSuite extends Ent
         } catch (GenericEntityException e) {
             Debug.logError(e, module);
         }
+        flushAndRecreateTree("fkr");
+        createNodeMembers("TEST-FKR", "foreign-key-remove-testing", "fkr");
         GenericEntityException caught = null;
+        int deleteNumber = 0;
+        EntityCondition isLevel1 = EntityCondition.makeCondition("primaryParentNodeId", EntityOperator.NOT_EQUAL, GenericEntity.NULL_FIELD);
         try {
-            EntityCondition isLevel1 = EntityCondition.makeCondition("description", EntityOperator.EQUALS, "node-level #1");
-            delegator.removeByCondition("TestingNode", isLevel1);
+            long nodeSize = delegator.findCountByCondition("TestingNode", isLevel1, null, null);
+            assertTrue("Deleted foreignKey failed because no element match condition", 0 < nodeSize);
+            deleteNumber = delegator.removeByCondition("TestingNode", isLevel1);
         } catch (GenericEntityException e) {
             caught = e;
+            deleteNumber = 0;
         }
+        assertEquals("Deleted TestingNode", 0, deleteNumber);
         assertNotNull("Foreign key referential integrity is not observed for remove (DELETE)", caught);
         Debug.logInfo(caught.toString(), module);
     }
@@ -485,7 +497,7 @@ public class EntityTestSuite extends Ent
      */
     public void testStoreByCondition() throws Exception {
         // change the description of all the level1 nodes
-        EntityCondition isLevel1 = EntityCondition.makeCondition("description", EntityOperator.EQUALS, "node-level #1");
+        EntityCondition isLevel1 = EntityCondition.makeCondition("primaryParentNodeId", EntityOperator.NOT_EQUAL, GenericEntity.NULL_FIELD);
         Map<String, String> fieldsToSet = UtilMisc.toMap("description", "node-level #1 (updated)");
         delegator.storeByCondition("TestingNode", fieldsToSet, isLevel1);
         List<GenericValue> updatedNodes = delegator.findByAnd("TestingNode", fieldsToSet);
@@ -795,4 +807,41 @@ public class EntityTestSuite extends Ent
         strBufTemp.append(iNum);
         return strBufTemp.toString();
     }
+
+    protected void createNodeMembers(String typeId, String typeDescription, String descriptionPrefix) throws GenericEntityException {
+        delegator.removeByCondition("TestingType", EntityCondition.makeCondition("testingTypeId", EntityOperator.EQUALS, typeId));
+        delegator.create("TestingType", "testingTypeId", typeId, "description", typeDescription);
+        int i = 0;
+        Timestamp now = UtilDateTime.nowTimestamp();
+        for (GenericValue node: delegator.findList("TestingNode", EntityCondition.makeCondition("description", EntityOperator.LIKE, descriptionPrefix + "%"), null, null, null, false)) {
+            if (i % 2 == 0) {
+                GenericValue testing = delegator.create("Testing", "testingId", descriptionPrefix + ":" + node.get("testingNodeId"), "testingTypeId", typeId, "description", node.get("description"));
+                GenericValue member = delegator.makeValue("TestingNodeMember",
+                        "testingNodeId", node.get("testingNodeId"),
+                        "testingId", testing.get("testingId")
+                        );
+                member.put("fromDate", now);
+                member.put("thruDate", UtilDateTime.getNextDayStart(now));
+                member.create();
+            }
+            i++;
+        }
+    }
+
+    protected void createNodeMembersForEach(String typeId, String typeDescription, String descriptionPrefix) throws GenericEntityException {
+        delegator.removeByCondition("TestingType", EntityCondition.makeCondition("testingTypeId", EntityOperator.EQUALS, typeId));
+        delegator.create("TestingType", "testingTypeId", typeId, "description", typeDescription);
+        Timestamp now = UtilDateTime.nowTimestamp();
+        for (GenericValue node: delegator.findList("TestingNode", EntityCondition.makeCondition("description", EntityOperator.LIKE, descriptionPrefix + "%"), null, null, null, false)) {
+            GenericValue testing = delegator.create("Testing", "testingId", descriptionPrefix + ":" + node.get("testingNodeId"), "testingTypeId", typeId, "description", node.get("description"));
+            GenericValue member = delegator.makeValue("TestingNodeMember",
+                    "testingNodeId", node.get("testingNodeId"),
+                    "testingId", testing.get("testingId")
+                    );
+
+            member.put("fromDate", now);
+            member.put("thruDate", UtilDateTime.getNextDayStart(now));
+            member.create();
+        }
+    }
 }

Modified: ofbiz/branches/release12.04/framework/sql/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/framework/sql/build.xml?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/framework/sql/build.xml (original)
+++ ofbiz/branches/release12.04/framework/sql/build.xml Sun Nov 16 13:48:45 2014
@@ -61,7 +61,7 @@ under the License.
     </target>
 
     <target name="classes" depends="prepare,gen-src">
-        <javac16/>
+        <javac17/>
     </target>
 
     <target name="jar" depends="classes">

Modified: ofbiz/branches/release12.04/framework/start/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/framework/start/build.xml?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/framework/start/build.xml (original)
+++ ofbiz/branches/release12.04/framework/start/build.xml Sun Nov 16 13:48:45 2014
@@ -34,7 +34,7 @@ under the License.
 
     <target name="classes" depends="prepare">
         <!-- compile start -->
-        <javac16 destdir="${build.dir}/classes" srcdir="${src.dir}"/>
+        <javac17 destdir="${build.dir}/classes" srcdir="${src.dir}"/>
     </target>
 
     <target name="jar" depends="classes">

Modified: ofbiz/branches/release12.04/macros.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/macros.xml?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/macros.xml (original)
+++ ofbiz/branches/release12.04/macros.xml Sun Nov 16 13:48:45 2014
@@ -23,12 +23,12 @@ under the License.
  </condition>
  <fail unless="antatleast171" message="Please upgrade ant to at least 1.7.1"/>
 
- <condition property="javaatleast16">
+ <condition property="javaatleast17">
   <not>
-   <matches pattern="^1\.[0-5]($|\..*)" string="${ant.java.version}"/>
+   <matches pattern="^1\.[0-6]($|\..*)" string="${ant.java.version}"/>
   </not>
  </condition>
- <fail unless="javaatleast16" message="Please upgrade java to at least 1.6"/>
+ <fail unless="javaatleast17" message="Please upgrade java to at least 1.7"/>
 
  <dirname property="ofbiz.home.dir" file="${ant.file.Ant - Macros}"/>
  <macrodef name="iterate">
@@ -77,8 +77,8 @@ under the License.
   </javac>
  </presetdef>
 
- <presetdef name="javac16">
-  <default-javac compiler="javac1.6" target="1.6" source="1.6" encoding="UTF-8" sourcepathref="src-path" includeantruntime="false">
+ <presetdef name="javac17">
+  <default-javac compiler="javac1.7" target="1.7" source="1.7" encoding="UTF-8" sourcepathref="src-path" includeantruntime="false">
    <compilerarg value="-Xlint:-path"/>
    <!--
    Please leave this line here.  It makes it easier to enable/disable it.
@@ -122,7 +122,7 @@ under the License.
         <exclude name="**/JpCacheIncludeTransform.java"/>             
         <exclude name="**/shark/"/>
       </fileset>
-      <link href="http://java.sun.com/javase/6/docs/api/" offline="true" packagelistLoc="${ofbiz.home.dir}/tools/api-java16"/>
+      <link href="https://docs.oracle.com/javase/7/docs/api/" offline="true" packagelistLoc="${ofbiz.home.dir}/tools/api-java17"/>
     </javadoc>
  </presetdef>
 

Modified: ofbiz/branches/release12.04/specialpurpose/shark/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/specialpurpose/shark/build.xml?rev=1639986&r1=1639985&r2=1639986&view=diff
==============================================================================
--- ofbiz/branches/release12.04/specialpurpose/shark/build.xml (original)
+++ ofbiz/branches/release12.04/specialpurpose/shark/build.xml Sun Nov 16 13:48:45 2014
@@ -53,9 +53,9 @@ under the License.
     <!-- ================================================================== -->
 
     <target name="classes" depends="prepare">
-        <javac16>
+        <javac17>
             <src path="${src.dir}"/>
-        </javac16>
+        </javac17>
     </target>
 
     <!-- ================================================================== -->