Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/variables/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Variables MULE中流量的动态变量。。?_Variables_Dynamic_Mule_Flow_Choice - Fatal编程技术网

Variables MULE中流量的动态变量。。?

Variables MULE中流量的动态变量。。?,variables,dynamic,mule,flow,choice,Variables,Dynamic,Mule,Flow,Choice,我在MULE中有一个包含HTTP入站和组件类的流,如下所示: <flow name="MetaService"> <http:inbound-endpoint address="http://localhost:8000/jcore/meta/user" transformer-refs="HttpParams" responseTransformer-refs="JavaObjectToJson"> </http:inbound-endpoin

我在MULE中有一个包含HTTP入站和组件类的流,如下所示:

<flow name="MetaService">
    <http:inbound-endpoint address="http://localhost:8000/jcore/meta/user"  
transformer-refs="HttpParams" responseTransformer-refs="JavaObjectToJson">
    </http:inbound-endpoint>
    <component class = "com.jcore.Meta" />
</flow>

现在,如果我必须接受另一个URL的请求,比如“localhost:8000/jcore/meta/user2”,我必须创建另一个流

在MULE中是否有类似“localhost:8000/jcore/meta/{variable}”这样的选项,其中我可以读取该变量并根据该变量调用相应的组件类…..

  • 考虑创建JAX-RS带注释的资源,这样所有这些基于URL的调度都将自动为您完成
  • 否则,只需将元服务绑定到“http://localhost:8000/jcore/meta,然后选择一个路由器,查看实际请求路径(“/jcore/meta/user”或“/jcore/meta/user2”),并相应地发送到正确的目的地