This content has been marked as final. Show 8 replies
Can you please post the reason why you would want that?
Many sites handle this by generating a transaction key on the intial web service contact and then forcing the client to echo the transaction key back for every web service method called. You could then store your CF variables in a database using the transaction key as the way to store/retrieve them. Easiest way would be to serialize a CF structure using <cfwddx>. Given, you wouldn't be using your typical coldfusion session variables (which I don't think you could use anyway via webservice as there is no way to id the session) - but it should work about the same. You would just need to schedule a task to go through and remove old data on a regular basis, as the "session" data would eventually fill your DB.
Too bad there is not a single example of transactional web service that ships with ColdFusion 7... Thanks.
How do you expose web service for complex business log using bunch of web service functions (without transactions)? You really can't with or can you?
You can try partial transactions.
Altho you need alot of logic in handling the return values.
Insuractive gave you a rather good solution.
Use UUID's to communicate between the webservices to handle the data that was parsed before.
Insuractive's described method works well with CF. We use a login() method (accepts username and password, creates session, sets session.isLoggedIn flag) to return a jsessionid to the webservice consumer.
The consumer then passes the jsessionid back to CF on each subsequent request: CF checks the jsessionid for validity on each request.
CF uses createObject("java", "coldfusion.runtime.SessionTracker").getSession("YOUR_CFAPPLICATION_NAME_" & jsessionid) to grab the WS consumer's session data from the JVM.
Can I pass session variables form asp to coldfusion? We are exploring using external authentication from a company that uses asp. Can logging in successfully from asp externally then pass session variables to the member area of our site, especially with different levels of users?
Could you send me full example of client.cfm and server.cfc code, please? Thanks so much. Dariusz.