Jakarta EE NoSQL is a framework and collection of tools that make integration between Java applications and NoSQL quick and easy—for developers as well as vendors. The API is easy to implement, so NoSQL vendors can quickly implement, test, and become compliant by themselves. And with its low learning curve and just a minimal set of artifacts, Java developers can start coding without having to worry about the complexity of specific NoSQL databases instead of their core aspects (such as graph or document properties). Built with functional programming in mind, it leverages all the features of Java 8 and above.
This session covers how the API is structured, how it relates to the multiple NoSQL database types, and how you can get started and involved in this open source technology and help the first new Jakarta EE specification evolve.
2. About the Speaker
Werner Keil
Consultant – Coach
Open Source Evangelist
Software Architect
Apache, Eclipse Committer,
Agile Alliance Member
Expert Group member in many JSRs
Spec Lead – JSR354, JSR385
Jakarta EE Specification Committee Member
Twitter @wernerkeil
[www.linkedin.com/in/catmedia]
16. The Jakarta NoSQL Solution
DIANA
ARTEMIS
JNoSQL
DAO
Mapping
Communication
Column Documents Key Graph
Data Tier
01
02
03
04
Mapping API
Communication API
No lock-in
Divide and Conquer
27. Diversity
@Entity("god")
public class God {
@Column
private String name;
@UDT("weapon")
@Column
private Weapon weapon;
}
interface GodRepository extends
CassandraRepository<God, String> {
@CQL("select * from God where name = ?")
List<God> findByName(String name);
}
28. We have Query by Text
List<Movie> movies = documentTemplate.query("select * from Movie
where year > 2012");
List<Person> people = columnTemplate.query("select * from Person
where age = 25");
Optional<God> god = keyValueTemplate.query("get 'Diana'");
List<City> cities = graphTemplate.query("g.V().hasLabel('City')");
29. We have Query by Text
PreparedStatement preparedStatement = template.prepare("select * from
Person where name = @name");
preparedStatement.bind("name", "Ada");
List<Person> adas = preparedStatement.getResultList();
//to graph just keep using gremlin
PreparedStatement prepare =
graphTemplate().prepare("g.V().hasLabel(param)");
prepare.bind("param", "Person");
List<Person> people = preparedStatement.getResultList();
30. We have Query by Text
interface PersonRepository extends Repository<Person, Long> {
@Query("select * from Person")
Optional<Person> findByQuery();
@Query("select * from Person where id = @id")
Optional<Person> findByQuery(@Param("id") String id);
}
33. References
Communication API
Support to Async operations
APIs
Mapping API
Bean Validation
Events
Repository
Template
Query by text
Prepared Statement
https://github.com/eclipse-ee4j/nosql
http://jnosql.org/
https://dev.eclipse.org/mailman/listinfo/jnosql-dev
https://gitter.im/JNOSQL/developers
https://wiki.eclipse.org/JNoSQL