2
我在WSO2 ESB 5.0.0上创建了一个具有任何端点的Rest API。WSO2 ESB - 配置CORS
我的端点调用Java的做了一个API休息(在Tomcat运行8),就像这样:
<?xml version="1.0" encoding="UTF-8"?>
<endpoint xmlns="http://ws.apache.org/ns/synapse" name="RecuperarArmadilhaPorId">
<http statistics="enable"
method="GET"
uri-template="http://localhost:8080/impactorcamentosgpmpu/ns/rest/pga/armadilhas/detalhePorId/{uri.var.id}"/>
</endpoint>
我不使用Identity Server和我宁愿不就在这一瞬间使用。
当我打电话给我的网址WSO2(http://192.168.10.178:8280/mapaHomologacao/ns/rest/pga/localidadesPorRota/101)内的移动应用程序,我收到了CORS错误:
XMLHttpRequest cannot load
http://192.168.10.178:8280/mapaHomologacaorotas/completa/1/101. No 'Access-
Control-Allow-Origin' header is present on the requested resource. Origin
'http://localhost:8100' is therefore not allowed access.
我试图做 库下面的配置/ conf目录/ tomcat的/炭/ WEB-INF ,我按照这个网址 WSO2 API Manager CORS
但没有什么变化。
我该如何解决这个问题?
问候,
亚历山德罗