This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<beans xmlns="http://www.springframework.org/schema/beans" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xmlns:context="http://www.springframework.org/schema/context" | |
xmlns:p="http://www.springframework.org/schema/p" | |
xmlns:tx="http://www.springframework.org/schema/tx" | |
xmlns:aop="http://www.springframework.org/schema/aop" | |
xsi:schemaLocation="http://www.springframework.org/schema/beans | |
http://www.springframework.org/schema/beans/spring-beans-2.5.xsd | |
http://www.springframework.org/schema/context |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- on persistence.xml file --> | |
<persistence xmlns="http://java.sun.com/xml/ns/persistence" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd" | |
version="2.0"> | |
<persistence-unit name="pu" transaction-type="JTA"> | |
<provider>org.hibernate.ejb.HibernatePersistence</provider> | |
<jta-data-source>java:/DefaultDS</jta-data-source> | |
<properties> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Entity | |
public class A { | |
@Id @GeneratedValue(strategy=SEQUENCE) | |
public Integer getId() { return id; } | |
public void setId(Integer id) { this.id = id; } | |
private Integer id; | |
public String getName() { return name; } | |
private void setName(String name) { this.name = name; } | |
private String name; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Clones your existing repo and run the maven tests off this clone | |
# Tests are run on the the current branch at the time of cloning | |
# | |
# Note that you can work on the next bug while this is going on as | |
# tests are run off a cloned repo. | |
# | |
# $ build.sh | |
# runs 'maven clean install' | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
manu@emmanuel-mbp-15 core (master) $ gradle test | |
:buildSrc:compileJava UP-TO-DATE | |
:buildSrc:compileGroovy UP-TO-DATE | |
:buildSrc:processResources UP-TO-DATE | |
:buildSrc:classes UP-TO-DATE | |
:buildSrc:jar UP-TO-DATE | |
:buildSrc:assemble UP-TO-DATE | |
:buildSrc:compileTestJava UP-TO-DATE | |
:buildSrc:compileTestGroovy UP-TO-DATE | |
:buildSrc:processTestResources UP-TO-DATE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
doHibernateStuff() { | |
hSearchQuery = new HSQuery(); | |
hSearchQuery.getTimeoutManager().start(); | |
hSearchQuery. ... | |
... | |
hSearchQuery.getTimeoutManager().stop(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.jamesward; | |
import java.util.List; | |
import org.springframework.flex.remoting.RemotingDestination; | |
import org.springframework.stereotype.Repository; | |
import org.springframework.stereotype.Service; | |
import org.springframework.transaction.annotation.Transactional; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Tests in error: | |
testExternalJar(org.hibernate.ejb.test.packaging.PackagedEntityManagerTest) | |
testORMFileOnMainAndExplicitJars(org.hibernate.ejb.test.packaging.PackagedEntityManagerTest) | |
------------------------------------------------------------------------------- | |
Test set: org.hibernate.ejb.test.packaging.PackagedEntityManagerTest | |
------------------------------------------------------------------------------- | |
Tests run: 13, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 3.253 sec <<< FAILURE! | |
testExternalJar(org.hibernate.ejb.test.packaging.PackagedEntityManagerTest) Time elapsed: 0.327 sec <<< ERROR! | |
java.lang.IllegalArgumentException: Unknown entity: org.hibernate.ejb.test.pack.externaljar.Scooter |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FacetRequest rangeRequest = queryBuilder( Fruit.class ).facet() | |
.name( priceRange ) | |
.onField( indexFieldName ) | |
.range().below(1.0).excludeLimit() | |
.from( 1.0 ).to( 1.50 ).excludeLimit() | |
.from( 1.50 ).to( 3.00 ).excludeLimit() | |
.above(3) | |
.createFacet(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @author Emmanuel Bernard <[email protected]> | |
*/ | |
public class SearchService { | |
@Inject | |
FullTextEntityManager em; | |
private org.hibernate.search.FullTextQuery ftQuery; | |
private Map<FacetResult, OrFacetFilter> filtersByFacetResult = new HashMap<FacetResult, OrFacetFilter>(); |