How to put web service consumer configuration in properties file in Mulesoft? - web-services

I want to put the parameters of web service consumer in a properties file. I know how to use properties file in mule. ${myWSDLlocation} in the configuration dialogue box does not do anything. I looked into this link, but could not solve it.
Any help will be appreciated. Thanks.

Got the solution.. This is what I did:
Dragged and dropped ws-consumer in flow
Configured it using the UI
Added properties file and defined key-value pairs in it - the usual way
Then edited the <ws:consumer-config> tag using ${keyNameHere}

First be sure you have property placeholders defined. Below is the syntax where a config.properties file has been defined to be used and it is placed in src/main/resources directory of your project.
Now in you properties file you can define the stuffs like below
implementation.url=http://abc-cdc.com
This URL can be accessed from web service consumer application using below.
ws:consumer-config doc:name="Web Service Consumer" name="Web_Service_Consumer" connectorConfig="HTTPS_Request_Configuration" wsdlLocation="ServiceWSDL/Manager.wsdl" serviceAddress="![p['implementation.url']]" port="ManagerSOAPPort" service="ManagerService"
In above example I am using only serviceAddress from config.properties file. Please let me know how it goes.

Related

Where does business logic go in Django API

I am very new to Django. I am able to set up a basic endpoint thanks to all the tutorials but what many of them miss is Where does one put the business logic of the app? Does it just go in a random file? Do I need to connect it somehow?
File structure that I have now
I think that I should create a file in apps, then add file with any name inside that folder

Graphs in Lucee

I see an error using CFCHART with Lucee. Same code works in CF. But in Lucee it try to refer to a file graph.cfm in a folder lucee.
mytestserver.com/lucee/graph.cfm?img=026f01d7b8c85b891a9c35c102623747&type=png
Do I need to create any mapping? Should this mapping be in Lucee admin or in IIS?
The short answer is: No, you don't need to add any additional mapping in IIS, nor in Lucee or Tomcat.
I've seen this question here for too long, so I'm placing an answer here to shed some light into Lucee's graph.cfm.
Some tags in CFML need to create additional image files to later embbed them as an inline HTML element into the reendered output altogether. Examples for such file creation are <cfimage type="captcha" ...> or like you have already noted in your issue, <cfchart>.
For such functionality Lucee needs to create these files temporarily somewhere and also make them publicly available. To achive this for cfimage/cfchart, Lucee creates the files in the web context folder of your webroot (which typically is located at path-to-your-webroot\WEB-INF\lucee\temp\graph ) and embbed them inline with a link to graph.cfm. The template graph.cfm just reads the temporary file from that folder, and delivers it in realtime to your application.
If you want to take a look into Lucees original graph.cfm, we can take a peek thanks to OpenSource:
source of Lucees graph.cfm at github
In order to make the files and the template graph.cfm temporarily publicly available, which by the way sits behind the WEB-INF folder ( which is also hidden/blocked by default in Tomcat for securtiy reasons), Lucee MUST have a virtual mapping. But you don't need to set it up, because these are already set up by default. You can see this in the image below taken from the "Mapping"-section of Lucee Administrator:
Because graph.cfm is a .cfm file, IIS will redirect the request directly through the implemented CFML connector ( probably Boncode Connector ) per AJP to Tomcat. Thus you don't need to set any mapping in IIS neither.
Because you have not submitted any additonal error information, such as http error codes or stack traces, I don't have any clue of what might be the cause of your error. It may also be some incompability issue which might be addressed if you submit it to the Lucee core team.
Another possibility is that many installation guides advise you to lock down the "/lucee/" path with IIS URL Rewrite Module, because this is also the path where the Lucee Administrator sits behind. If so, you can change the setting in IIS Rewrite Rule and adapt the rule in such a manner, that it would not block the graph.cfm.
It's also important to note that many of these cftags are implemented as Lucee extensions (.lex files). These are not necessarily pre-shipped or pre-installed in Lucee, but you may install it within Lucee Administrator or get them from Lucees Download site and upload it through your Lucee Administrator in the "Extension" section.
I've just encountered this too. Issue being though the the default mapping still don't navigate to "graph.cfm" so we've added an IIS virtual mapping instead.

bpmn explorer # wso2

I need to customize the Search module of the BPMN Explorer integrated in wso2.
More exactly I want to be able to search using one of the task variables as search parameters.
I have looked in the git repository and came across https://github.com/wso2/carbon-business-process/blob/c6e60e57ab0de5d8de59041647f5cb9b7834d9c7/components/bpmn/org.wso2.carbon.bpmn.ui/src/main/resources/web/bpmn/instance_list_view.jsp
However this script is not in my BPS release (latest available downloaded already).
Could anyone please provide some pointers at least to how I could go about customizing the search function for bpmn explorer ?
Thanks!
Edit:
I managed to modify the gui (searchView.jag file )of the search function, but cannot add functionality for those new fields
You can do the necessary modifications (customize the seach function) to searchModel.jag file for the fields you added in searchView.jag. Please find it (searchModel.jag) under <BPS_HOME>/repository/deployment/server/jaggeryapps/bpmn-explorer/model directory.
If you look at the bpmn-explorer folder you can see three sub-folders namely controller, model and template. Here controller folder includes set of .jag files which are used to check the request is secure or not, hold the session and build basic structure of the rendering pages. .jag files in model folder are used to implement the business logic say as an example invoke activiti rest api to get the process variables, process information, etc. The .jag files in the template folder are used to render the UI elements with appropriate results. Hope this resolves your issue.

Can't get access to configuration.php Joomla 2.5

Got a site to make some changes. Unfortunately I can't get an access to www/root/configuration.php . Suppose the file was blocked by another user who had admin rights. Am I right?
I'm not clear exactly what you mean by 'can't get access' to the configuration file. Maybe it's permission related or maybe the site was customised and the configuration file is in a non-standard location.
Either way there are a couple of options you could try.
I presume you have access to the backend of the site and so you could make most changes from there via Site > Global Configuration.
You can also view almost all the details of the config file from Site > Sytem Information > Configuration File
If neither of these suggestions solved your problem, maybe you could instal a file management component like http://extensions.joomla.org/extension/extplorer and acces the config file that way.
Good luck!

changing the default URL i.e. http://localhost:8080/axis2/services/ in Webservices using axis

I tried an web service example from the below mention link
http://www.tidytutorials.com/2009/02/web-services-example-using-axis-2-and.html
In the example when we generate the client code using wsdl2java the url used is as mention in title i.e. http://localhost:8080/axis2/services/ Is there any way by which i can use custom name insted of axis2/services for ex. ponds/accounts
I tried with packages, keeping the aar file in newly created folder in services directory but not working
Try this
in the axis2.xml you'll see
<parameter name="contextRoot">axis2</parameter>
Its usually commented out and I suspect axis just uses axis2 by default. but try changing it and see if that fixes it
I don't think you're using eclipse but if you are it has an easier way of changing the context root through Project Properties -> Web Project Settings