Skip to content

Instantly share code, notes, and snippets.

Avatar
:octocat:
Focusing

Abhishek Gupta abhirockzz

:octocat:
Focusing
View GitHub Profile
@abhirockzz
abhirockzz / ProgrammaticSSEClient.java
Last active Jul 27, 2017
JAX-RS 2.1 SSE Client API support in Java EE 8
View ProgrammaticSSEClient.java
@Singleton
@Startup
public class ProgrammaticSSEClient {
Client sseClient;
WebTarget target;
@Resource
TimerService tsvc;
@abhirockzz
abhirockzz / StatefulEJBInWebSocket_2.txt
Created Feb 14, 2017
Stateful EJB In WebSocket (2/2)
View StatefulEJBInWebSocket_2.txt
@Stateful
public class ClientChatState {
...
@Remove
public void dispose(){
//this can just be a marker method
}
@PreDestroy
public void closeResources(){
//close connections, resources etc.
@mortezaadi
mortezaadi / persistence.xml
Last active Aug 28, 2020
persistence xml configurations for major databases and jpa providers
View persistence.xml
<?xml version="1.0" encoding="UTF-8"?>
<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_1_0.xsd"
version="1.0">
<!-- derby -->
You can’t perform that action at this time.