如何在我的java fie中添加跨源资源共享

时间:2017-05-30 06:54:40

标签: java restful-authentication

我写的这不正确

HttpClient httpClient = HttpClientBuilder.create().header("Access-Control-Allow-Origin", "*")
                .header("Access-Control-Allow-Methods", "GET, POST, DELETE, PUT")
                .allow("OPTIONS").build();

1 个答案:

答案 0 :(得分:1)

您可以为CORS原始过滤器编写组件类

serial.to_bytes(sequence)