How to facilitate communication between php script on a server to a running Java application on another server?

后端 未结 2 1287
梦毁少年i
梦毁少年i 2021-01-23 03:28

How to establish a way for Java application to listen to data being sent by php ? Sockets or Http POST ?

Essentially, I have Java application running on another server w

2条回答
  •  攒了一身酷
    2021-01-23 04:02

    I suggest implementing a REST api. If you can't or don't want to, using sockets is the most secure way...

    If you are sending FROM php, I recommend using a RESTful API with authentication. Send JSON data, get JSON data back. It allows for better future expansion too.

提交回复
热议问题