English 中文(简体)
• 如何从Java EE的申请中提供一张袖珍材料?
原标题:How to serve a socket from a Java EE application?
最佳回答

我现在谈一下:

http://yuml.me/7f82bd5c>rel=“nofollow noreferer”>alt text http://yuml.me/7f82bd5c

我使用单独的java申请,接受客户的警示,并将之转交应用服务器。

问题回答

你有权这样做,因为你可以宣布在 JavaE的每一件交易,必须从你想要连接的所有组成部分那里得到支持。 如果有的话,档案应存放在数据库中。 所有物品都应由集装箱控制,因为这是利用Java EE进行推广的唯一途径。

几种选择:

你们也不能查阅档案:

这是因为欧洲法院必须:

  • distributable (you don t know beforehand on what server/instance your EJB will be deployed
  • the container is to be able to manage "everything" so you must not spawn your own threads

考虑到这一点,你将不停在你的服务器上(最好的位置可能放在服务器上),但你应注意,当你的服务器停机时,如何关闭服务器。

我采用的办法与我在春天的MVC时的需要有些相似。 这样做可以帮助周围的人。

Start a Socket Port on server start up. I used @scheduler annotation whereas you can use listener based solution as well. You can also implement ApplicationContextAware listener and can access other application beans from it.

@Scheduled(fixedDelay = 1000 * 60 * 60 * 24 * 365) 
public void startListenerPort() { 
    ServerSocket socket = new ServerSocket(9999); 
    // do some stuff here 
}

Just make sure that you have allowed TCP traffic on the port that you have assigned to the Socket (Firewall Settings).

这样,你就可以在99999号港进行电话交换,因为你的服务器将继续在不同的港口正常运行。

虽然严格来说,这并非纯粹的技术性CP联系,但你可以取得您所需要的<条码>@ServerEndpoint的说明,以便从Java E7的光谱中建立一个网页。

虽然指定经营实体使用“吉卜赛人”系统,但它在<代码>时将发挥像双亲界面这样的作用。 OnMessage methods and a ByteBuffer (or byte[ ]).





相关问题
Spring Properties File

Hi have this j2ee web application developed using spring framework. I have a problem with rendering mnessages in nihongo characters from the properties file. I tried converting the file to ascii using ...

Logging a global ID in multiple components

I have a system which contains multiple applications connected together using JMS and Spring Integration. Messages get sent along a chain of applications. [App A] -> [App B] -> [App C] We set a ...

Java Library Size

If I m given two Java Libraries in Jar format, 1 having no bells and whistles, and the other having lots of them that will mostly go unused.... my question is: How will the larger, mostly unused ...

How to get the Array Class for a given Class in Java?

I have a Class variable that holds a certain type and I need to get a variable that holds the corresponding array class. The best I could come up with is this: Class arrayOfFooClass = java.lang....

SQLite , Derby vs file system

I m working on a Java desktop application that reads and writes from/to different files. I think a better solution would be to replace the file system by a SQLite database. How hard is it to migrate ...

热门标签