最好的Java支持的服务器

最好的Java支持的服务器

本文介绍了最好的Java支持的服务器/客户端协议?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在编写一个应用于基于消息的客户端/服务器应用程序。



库应该提供的功能:




  • 客户端和服务器端功能

  • / li>
  • 支持多线程

  • 负载平衡器/防火墙


我对 HTTPCore ,但底线是一个必须实现客户端和服务器,只有传输层将被覆盖。 RMI不是由于网络相关要求的选择。



任何想法都非常感激。



hr>
详细



我的想法是实现一个处理客户端通信的客户端/服务器包装)并将传入的请求写入JMS队列:

 #1 User  - >包装(检查用户/密码) - > JMS  - > 服务器
#2用户轮询轮询JMS的Wrapper

单独的进程将处理请求并可以通过包装器对客户端进行回复。我想使用JMS,因为:




  • 它处理持久性很好

  • 负载平衡 -

  • JMSTimeToLive也很方便。



不幸的是,我没有看到一个方法来使用JMS自己的,因为客户端应该只能访问他们的消息,并且在JMS端的不同用户的设置也听起来不可行。

某些要求(或至少是对应用程序的模糊想法),才能真正建议您。


I'm in the process of writing a client/server application which should work message based. I would like re-use as much as possible instead of writing another implementation and curious what others are using.

Features the library should offer:

  • client and server side functionality
  • should work message based
  • support multi-threading
  • should work behind load balancer / firewalls

I did several tests with HTTPCore, but the bottom line is that one has to implement both client and server, only the transport layer would be covered. RMI is not an option either due to the network related requirements.

Any ideas are highly appreciated.


Details

My idea is to implement a client/server wrapper which handles the client communication (including user/password validation) and writes incoming requests to a JMS queue:

#1  User --> Wrapper (Check for user/password) --> JMS --> "Server"
#2  User polls Wrapper which polls JMS

Separate processes will handle the requests and can reply via wrapper to the clients. I'd like to use JMS because:

  • it handles persistence quite well
  • load balancing - it's easy to handle peaks by adding additional servers as consumer
  • JMSTimeToLive comes in handy too

Unfortunately I don't see a way to use JMS on it's own, because clients should only have access to their messages and the setup of different users on JMS side doesn't sound feasible either.

解决方案

Well, HTTP is probably the best supported in terms of client and server code implementing it - but it may well be completely inappropriate based on your requirements. We'll need to actually see some requirements (or at least a vague idea of what the application is like) before we can really advise you properly.

这篇关于最好的Java支持的服务器/客户端协议?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-25 21:23