Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 8 years ago.
Improve this question
I've got a really simple question but I find nothing interesting on Google.
Is there a Java equivalent of SignalR (.NET) ?
SignalR is a .NET framework that implements Websockets with a fallback for old browsers.
Really thx to you.
It seems that Atmosphere can be this what you are looking for.
From github description:
The Atmosphere Framework contains client and server side components
for building Asynchronous Web Application.
I didn't tried it yet, but this says that it supports major JEE-Servers (JBoss, Tomcat, Glassfish, Jetty) and all major browsers and transports (WebSockets, SSE, Long-Polling etc).
UPDATE 6/4/2014:
There is another notable alternative for "Java equivalent of SignalR". As of version 4.0, Spring Framework comes with support for WebSockets and server-side support for the SockJS. It means that it supports also WebSocket-Fallback, used together with a browser side sockjs-client library.
As Spring Documentation says:
WebSocket is not supported in all browsers yet and may be precluded by restrictive network proxies. This is why Spring provides fallback options that emulate the WebSocket API as close as possible based on the SockJS protocol [...] On the browser side, applications can use the sockjs-client that emulates the W3C WebSocket API and communicates with the server to select the best transport option depending on the browser it’s running in.
Still I'm not aware if there is support for something like SignalR Hubs (which involves JavaScript-code generation)in the Java Framework as of today, but on the other side I think you can easily imitate a SignalR-like PersistentConnection with full fallback support for older browsers.
Furthermore, because of JSR 356 aka Java API for WebSocket, I think it is only a question of time when the so to say "mainstream" Java Web-frameworks will be shipped with out-of-the-box support for Websockets+Fallback, especially considering the fact that all main servlet conteiners (like Tomcat and Jetty) and JEE 7 Servers (Glassfish, Wildfly) have support for JSR 356 already.
There is a Play framework module SignalJ
Update: SignalJ looks dead, look Scala Web Sockets
Related
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 8 years ago.
Improve this question
We are trying to utilize ActiveMQ. The confusion of which protocol is better to utilize for having application usage with ActiveMQ.
AMQP is an application-level standard for Message Oriented Middleware (MOM). JMS is a standard API for Java for communicating with MOM.
Two different Java applications using JMS could be using different MOM and hence still be unable to communicate. ActiveMQ is a MOM system with a JMS library that allows Java programs to access it using JMS, but it can't necessarily communicate with another JMS Java program using, say, WebLogic MOM.
Different AMQP MOM systems can interoperate with each other (assuming that they are using the same version of AMQP) since AMQP is a standard along the same lines as, say SMTP. There is no reason that an AMQP MOM system could not also provide a JMS library for its Java clients. SwiftMQ, for example, provides a JMS API and uses AMQP 1.0.
ActiveMQ supports AMQP v1.0 protocol clients (see http://activemq.apache.org/amqp.html for configuration help). You can use the QPid project's JMS client or other non-JMS AQMP v1.0 clients, ActuveMQ does not currently provide it's own AMQP based JMS client.
If you are using Spring framework then you can also use Spring AMQP.
If requirement is basic and not much processing is required then you can use ActiveMQ.
It all depend on your Requirement and what type of processing you want to do with it..
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
We will be developing a server-side linux service using Java.
Does anybody have experience of a framework or an "application server" for this purpose?
Application server not in the common sense, this has nothing to do with web, http or the like. It's a server application listening on a socket, processing some stuff and then answer to it. It will be a custom protocol. So the usual suspects like Glassfish, Tomcat, Jetty, etc. aren't really what I need.
Edit: I'm looking for features like startup handling, automatic service recovery, and may be database connection
Any help is appreciated.
You could use Netty for developing your tcp/ip based client-server application. It has very good documentation and arguably better performance too. If you want you could also look into Apache MINA but IMHO they do not have great documentation. QuickServer is also there if you have time to do some R&D on it.
I think you are wrong - the listed usual suspects (well, Tomcat not) are in my opinion perfect fit. Shortly, what you need is an application server with Java EE 6 Full profile support - I would recommend GlassFish or WildFly, or WebLogic from commercial end. The reason is simple - JCA (Java Connector Architecture). It's a Java EE specification for connecting to 3rd party, or legacy, or custom developed systems. We have used it successfully for implementing communication via application specific socket based protocol, or even for Sun-RPC and Radius (from telco) protocols. There are several examples on the web, how to utilize it - with latest Java EE spec there are also few examples for socket communication finally available. But the specification itself (JCA 1.6) is very well written and after reading it you should be able to use it.
Because it is part of Java EE, the container will support all the pooling, startup, monitoring , ... Give it a try.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I am considering building a Java EE based set of services and licensing these services to my clients. While we will aim to make these services generic for any client, reality is that customizations and new services will be needed on a client specific basis.
Likely the stack will be a Java application deployed to the EC2 cloud, possibly leveraging a framework such as Spring.
What architecture would one prescribe to have a hosted application for my clients, but also enable them to build their own custom extensions. Does anyone have technical or business example of a company that has built a hosted SaaS service that is extensible on the platform side?
I haven't done this yet, but AFAIK you could use module systems such as OSGi also on the server side to write modular, extensible server side applications.
Atlassian does this. You basically pay to have even its own source code, as well as a Platform SDK, or even a Managed Instance (this one, however, seems not extensible)
Internally, most of them rely in an OSGi Container (I think its Felix), so it manages dependencies accordingly, as well as DI and Extension Points. Perhaps might be worth it to have a try
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
In particular, I'm trying to find a library that provides an elegant way to deal with the event-based nature of IRC, without producing spaghetti code (as a naive event-based implementation often becomes).
Netty is an event-driven IO framework you might want to look at.
irc-api, a well designed Java IRC API that offers some features other IRC APIs don't (like asynchronous commands). Main features are:
State(ful/less) API
Callbacks support / Asynchronous
Message Listeners - Message Filters
SSL implementation
DCC implementation
SLF4J/Maven integration
You might wanna give it a try!
I've already written such framework you mention in comment:
JawaBot 2.x is a pluggable standalone application with IRC and web UI which aims to put multiple functionalities under one bot, while still keeping the structure of the code sane. Mavenized.
Currently, there are few plugins:
Jira - resolves name, status and assignee from a Jira issue tracker. Configurable. Default config supports opensource repos: JBoss, Codehaus, Apache and others.
Logger - logs IRC events to a DB. Has a web UI.
Reservation - for reservation of resources over IRC. Has a web UI.
WhereIs - looks for nicks in all channels, supports wildcards.
Messenger - delivers messages to users which are offline when they connect ("answering machine").
PasteBin - let's user paste text through PM, saves it, and posts a link to a web UI to the channel.
AutoOp - gives op to users.
Social - reacts to "Hi!" etc. Kind of Hello World plugin.
If you're not into that, you may try PircBotX which tries to fix PircBot's wrong design.
List of other options is also here: Building an IRC bot in Java
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I've been doing some work with the JAX-RS reference implementation (Jersey).
I know of at least two other frameworks (Restlet & Apache CXF).
My question is: Has anyone done some comparison between those frameworks and if so, which framework would you recommend and why?
FWIW we're using Jersey as its packed full of features (e.g. WADL, implicit views, XML/JSON/Atom support) has a large and vibrant developer community behind it and has great spring integration.
If you use JBoss/SEAM you might find RESTeasy integrates a little better - but if you use Spring for Dependency Injection then Jersey seems the easiest, most popular, active and functional implementation.
Restlet has an extensive list of extensions for Spring, WADL, XML, JSON as well and many more, including an extension for JAX-RS API.
It is also the sole framework available in six consistent editions:
Java SE
Java EE
Google Web Toolkit
Google AppEngine
Android
OSGi environments
Its main benefits are:
fully symmetric client and server API when JAX-RS was designed for server-side processing
connectors for other protocols than HTTP (mapping to HTTP semantics) when JAX-RS is HTTP only
much broader feature scope including full URI routing control via the Restlet API (but can integrate with Servlet if needed)
full provision for NIO support
The JAX-RS API can be a good choice if you are restricted to JCP approved APIs (then don't use Spring or any extension of the JAX-RS projects like Jersey and RESTeasy!), but otherwise Restlet is the most mature framework (initially released in 2005) and will give you, in its 2.0 version, all the benefits of annotations combined with a powerful and extensible class-oriented framework.
For a longer list of features, please check this page.
Best regards,
Jerome Louvel
Restlet ~ Founder and Lead developer ~ http://www.restlet.org
My team and I use Restlet extensively, but not its JAX-RS features. I can tell you that I've been very impressed with the Restlet developers and community; they're very active, engaged, responsive, and committed to a stable, efficient, reliable, and effective framework. I'm sorry I can't directly address your primary interest but I thought you might find my experience with Restlet valuable.
My colleague mentions why we are using RESTeasy for our current project in RESTful web services in Java EE with RESTeasy (JAX-RS):
Its reference implementation, Jersey, was not chosen because we had trouble integrating it well with EJB3 and Seam 2.0.
We are using the RESTeasy implementation of JAX-RS, because we had no trouble integrating it with our EJBs and Seam. It also has sufficient documentation.
There is another implementation from Apache, but I haven’t tried it because it uses an older version of JAX-RS.
Finally there is yet another framework for RESTful web services for Java called Restlet but we did not favour it because at the time of this writing, it is using a custom architecture, even though proper JAX-RS support is in the works.
It seems like there are 4 decent JAX-RS implementations, so you are probably ok with any of them.
For what it's worth, I have found Jersey (1.0.2) really nice so far. My needs are quite modest, simple back-end service, take care of plumbing and so on. And that Jersey does quite nicely.
Found out that Apache Wink is very easy to work with, supports JAX-RS and has many features beyond the standard.
I would use no framework. Just the one that comes with your applications server. If you use specifics of one framwork you'll lose portability and you'll be in the hell of what if the vendor of the app server includes a different version of your favourite framework. I'll stick to jax-ws.