Author: stliu
Date: 2010-09-16 07:00:16 -0400 (Thu, 16 Sep 2010)
New Revision: 20650
Modified:
core/trunk/parent/pom.xml
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/any/PropertyMap.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/AId.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/ChildPk.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvMagazin.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvMagazinPk.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvProgram.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvProgramIdClass.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/keymanytoone/Key.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/collectionelement/Boy.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/collectionelement/Matrix.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/a/Dependent.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/b/Dependent.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/b/ExclusiveDependent.java
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/indexcoll/Atmosphere.java
Log:
HHH-5572 clean up Sybase job failures
Modified: core/trunk/parent/pom.xml
===================================================================
--- core/trunk/parent/pom.xml 2010-09-16 06:39:05 UTC (rev 20649)
+++ core/trunk/parent/pom.xml 2010-09-16 11:00:16 UTC (rev 20650)
@@ -916,7 +916,7 @@
<properties>
<db.dialect>org.hibernate.dialect.SybaseASE15Dialect</db.dialect>
<jdbc.driver>com.sybase.jdbc3.jdbc.SybDriver</jdbc.driver>
-
<jdbc.url>jdbc:sybase:Tds:vmg07.mw.lab.eng.bos.redhat.com:5000/hibbrtru?DYNAMIC_PREPARE=true</jdbc.url>
+
<jdbc.url>jdbc:sybase:Tds:vmg07.mw.lab.eng.bos.redhat.com:5000/hibbrtru?SQLINITSTRING=set
quoted_identifier on</jdbc.url>
<jdbc.user>hibbrtru</jdbc.user>
<jdbc.pass>hibbrtru</jdbc.pass>
<jdbc.isolation/>
@@ -935,7 +935,7 @@
<properties>
<db.dialect>org.hibernate.dialect.SybaseASE15Dialect</db.dialect>
<jdbc.driver>com.sybase.jdbc3.jdbc.SybDriver</jdbc.driver>
-
<jdbc.url>jdbc:sybase:Tds:vmg09.mw.lab.eng.bos.redhat.com:5000/hibbrtru?DYNAMIC_PREPARE=true</jdbc.url>
+
<jdbc.url>jdbc:sybase:Tds:vmg09.mw.lab.eng.bos.redhat.com:5000/hibbrtru?SQLINITSTRING=set
quoted_identifier on</jdbc.url>
<jdbc.user>hibbrtru</jdbc.user>
<jdbc.pass>hibbrtru</jdbc.pass>
<jdbc.isolation/>
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/any/PropertyMap.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/any/PropertyMap.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/any/PropertyMap.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -61,7 +61,7 @@
name = "map_properties",
joinColumns = @JoinColumn( name = "map_id" ),
inverseJoinColumns = @JoinColumn( name = "property_id" ) )
- @MapKey( columns = { @Column( name = "map_key" ) } ) //keep for legacy test
+ @MapKey( columns = { @Column( name = "map_key", nullable = false ) } )
//keep for legacy test
public Map<String, Property> getProperties() {
return properties;
}
Modified: core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/AId.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/AId.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/AId.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -14,11 +14,11 @@
public class AId implements Serializable {
@OneToOne
- @JoinColumn( name = "bid" )
+ @JoinColumn( name = "bid", nullable = false )
private B b;
@OneToOne
- @JoinColumn( name = "cid" )
+ @JoinColumn( name = "cid", nullable = false )
private C c;
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/ChildPk.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/ChildPk.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/ChildPk.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -17,8 +17,8 @@
public int nthChild;
@ManyToOne()
@JoinColumns({
- @JoinColumn(name = "parentLastName", referencedColumnName =
"p_lname"),
- @JoinColumn(name = "parentFirstName", referencedColumnName =
"firstName")
+ @JoinColumn(name = "parentLastName", referencedColumnName =
"p_lname", nullable = false),
+ @JoinColumn(name = "parentFirstName", referencedColumnName =
"firstName", nullable = false)
})
public Parent parent;
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvMagazin.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvMagazin.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvMagazin.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -3,6 +3,7 @@
import java.util.Date;
import javax.persistence.AssociationOverride;
+import javax.persistence.AssociationOverrides;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
import javax.persistence.JoinColumn;
@@ -13,7 +14,9 @@
* @author Emmanuel Bernard
*/
@Entity
-@AssociationOverride(name = "id.channel", joinColumns = @JoinColumn(name =
"chan_id"))
+@AssociationOverrides({
+@AssociationOverride(name = "id.channel", joinColumns = @JoinColumn(name =
"chan_id", nullable = false)),
+@AssociationOverride(name = "id.presenter", joinColumns = @JoinColumn(name =
"presenter_name", nullable = false))})
public class TvMagazin {
@EmbeddedId
public TvMagazinPk id;
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvMagazinPk.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvMagazinPk.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvMagazinPk.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -2,7 +2,9 @@
package org.hibernate.test.annotations.cid;
import java.io.Serializable;
+
import javax.persistence.Embeddable;
+import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
/**
@@ -11,8 +13,10 @@
@Embeddable
public class TvMagazinPk implements Serializable {
@ManyToOne
+ @JoinColumn(nullable=false)
public Channel channel;
@ManyToOne
+ @JoinColumn(nullable=false)
public Presenter presenter;
}
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvProgram.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvProgram.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvProgram.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -2,9 +2,13 @@
package org.hibernate.test.annotations.cid;
import java.util.Date;
+
+import javax.persistence.AssociationOverride;
+import javax.persistence.AssociationOverrides;
import javax.persistence.Column;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
+import javax.persistence.JoinColumn;
import javax.persistence.PrimaryKeyJoinColumn;
import javax.persistence.SecondaryTable;
import javax.persistence.Temporal;
@@ -18,6 +22,9 @@
@PrimaryKeyJoinColumn( name = "CHANNEL_ID" ),
@PrimaryKeyJoinColumn( name = "PRESENTER_NAME" )
} )
+@AssociationOverrides({
+@AssociationOverride(name = "id.channel", joinColumns = @JoinColumn(name =
"chan_id", nullable = false)),
+@AssociationOverride(name = "id.presenter", joinColumns = @JoinColumn(name =
"presenter_name", nullable = false))})
public class TvProgram {
@EmbeddedId
public TvMagazinPk id;
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvProgramIdClass.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvProgramIdClass.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/TvProgramIdClass.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -6,6 +6,7 @@
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.IdClass;
+import javax.persistence.JoinColumn;
import javax.persistence.PrimaryKeyJoinColumn;
import javax.persistence.SecondaryTable;
import javax.persistence.Temporal;
@@ -20,8 +21,10 @@
@IdClass( TvMagazinPk.class )
public class TvProgramIdClass {
@Id
+ @JoinColumn(nullable=false)
public Channel channel;
@Id
+ @JoinColumn(nullable=false)
public Presenter presenter;
@Temporal( TemporalType.TIME )
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/keymanytoone/Key.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/keymanytoone/Key.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/cid/keymanytoone/Key.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -26,6 +26,7 @@
import java.io.Serializable;
import javax.persistence.Entity;
import javax.persistence.Id;
+import javax.persistence.Table;
/**
* TODO : javadoc
@@ -33,6 +34,7 @@
* @author Steve Ebersole
*/
@Entity
+@Table(name="`key`")
public class Key implements Serializable {
@Id
private String id;
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/collectionelement/Boy.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/collectionelement/Boy.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/collectionelement/Boy.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -17,6 +17,7 @@
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
+import javax.persistence.MapKeyColumn;
import javax.persistence.OrderColumn;
import javax.persistence.Table;
@@ -102,6 +103,7 @@
}
@ElementCollection
+ @MapKeyColumn(nullable=false)
public Map<String, Integer> getScorePerPreferredName() {
return scorePerPreferredName;
}
@@ -113,6 +115,7 @@
@ElementCollection
@CollectionTable(name = "ScorePerNickName", joinColumns = @JoinColumn(name =
"BoyId"))
@Column(name = "score", nullable = false)
+ @MapKeyColumn(nullable=false)
public Map<String, Integer> getScorePerNickName() {
return scorePerNickName;
}
@@ -158,6 +161,7 @@
@ElementCollection
@Enumerated(EnumType.STRING)
+ @MapKeyColumn(nullable=false)
public Map<String, FavoriteFood> getFavoriteFood() {
return foods;
}
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/collectionelement/Matrix.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/collectionelement/Matrix.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/collectionelement/Matrix.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -8,6 +8,7 @@
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
+import javax.persistence.MapKeyColumn;
import org.hibernate.annotations.MapKeyType;
import org.hibernate.annotations.Sort;
@@ -27,6 +28,7 @@
@ElementCollection
@Sort(type = SortType.NATURAL)
@Type(type = "float")
+ @MapKeyColumn(nullable = false)
private SortedMap<Integer, Float> mvalues = new TreeMap<Integer, Float>();
public Integer getId() {
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/a/Dependent.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/a/Dependent.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/a/Dependent.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -4,6 +4,7 @@
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.IdClass;
+import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import org.hibernate.annotations.Cascade;
@@ -39,6 +40,7 @@
@Id
@ManyToOne( cascade = CascadeType.PERSIST )
@Cascade( org.hibernate.annotations.CascadeType.SAVE_UPDATE )
+ @JoinColumn(nullable=false)
public Employee getEmp() {
return emp;
}
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/b/Dependent.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/b/Dependent.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/b/Dependent.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -17,6 +17,7 @@
//@JoinColumn(name="FK") // id attribute mapped by join column default
@MapsId("empPK") // maps empPK attribute of embedded id
@ManyToOne
+ @JoinColumn(nullable=false)
Employee emp;
}
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/b/ExclusiveDependent.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/b/ExclusiveDependent.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/derivedidentities/e1/b/ExclusiveDependent.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -14,7 +14,7 @@
@EmbeddedId
DependentId id;
- @JoinColumn(name = "FK")
+ @JoinColumn(name = "FK", nullable = false)
// id attribute mapped by join column default
@MapsId("empPK")
// maps empPK attribute of embedded id
Modified:
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/indexcoll/Atmosphere.java
===================================================================
---
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/indexcoll/Atmosphere.java 2010-09-16
06:39:05 UTC (rev 20649)
+++
core/trunk/testsuite/src/test/java/org/hibernate/test/annotations/indexcoll/Atmosphere.java 2010-09-16
11:00:16 UTC (rev 20650)
@@ -44,10 +44,12 @@
@MapKeyTemporal(TemporalType.DATE)
@ElementCollection
+ @MapKeyColumn(nullable=false)
public Map<Date, String> colorPerDate = new HashMap<Date,String>();
@ElementCollection
@MapKeyEnumerated(EnumType.STRING)
+ @MapKeyColumn(nullable=false)
public Map<Level, String> colorPerLevel = new HashMap<Level,String>();
@ManyToMany(cascade = CascadeType.ALL)
@@ -71,6 +73,7 @@
@ManyToMany(cascade = CascadeType.ALL)
@MapKey
@JoinTable(name="Atm_Gas_DefLeg")
+ @MapKeyColumn(nullable=false)
public Map<String, Gas> gasesDefLeg = new HashMap<String, Gas>();
@ManyToMany(cascade = CascadeType.ALL)