| Summary: | Need access to HTTP session from EGL-generated services and libraries | ||
|---|---|---|---|
| Product: | z_Archived | Reporter: | Will Smythe <smythew> |
| Component: | EDT | Assignee: | Project Inbox <edt.javagen-inbox> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | enhancement | ||
| Priority: | P3 | CC: | jqian, jspadea, jvincens, mheitz, svihovec, tww |
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | |||
|
Description
Will Smythe
I talked with Joe about this, and he told me the following: 1) Issue from ClearBlade - This support does not exist in RBD, and would involve a non-trivial change to make it work. A second work item should be opened and marked 'future' for this issue. Also, a workaround was provided for this issue in RBD, which should still be relevant in EDT .7. 2) Set and Get HTTP Session variables - The list of features provided for EDT .7 does not include JEELib, which is where this functionality would be located, so no investigation has been done yet for porting this library to EDT. While on the surface the changes to add this functionality seem trivial, there is a lot of code that would need to be ported, reviewed, and tested. Also, Justin would need to review the design to confirm that the solution would work on the IDE Test Server as well. Due to the fact that Joe will be unavailable after tomorrow, and based on the original assumption that JEELib will not be part of EDT .7, I believe we will need to defer this feature until after .7. If you do not agree with this assessment, please provide a specific example of an application that must work in the .7 time frame and will not work without this feature. This can wait until after .7, but needs to be high on the list for 0.8. We definitely need to solve #1 soon -- the current behavior is not consistent with the way session normally works. A single client instance (i.e. RUI app running in a browser) calling EGL-generated services running in the same web app should share a common session. 080 has the ability to access the HttpSession, but there is a problem with the EVServer talking to the jetty server. HttpSession is an ExternalType so you have access to all the HttpSession functionality. The 1 problem in 080 is with the test server when using a dedicated or workspace bound service. The server issues a set-cookie which does not propagate through the EVServer. I recently resolved this the set-cookie issue so 081 will support HttpSession from development through to deployment. For 080 I had planned to write a blog about accessing and maintaining the session, but because of the jetty server issue this will have to wait until 081. org.eclipse.edt/ibmi/org.eclipse.edt.jtopen.samples contains a code example for accessing the HttpSession. See the SessionConnectionsLib.getSessionId to see how to obtain the session. org.eclipse.edt/ibmi/org.eclipse.edt.ibmi.examples contains sample code for extracting the set-cookie and putting it on the HttpRest variable. See the CookieSession library, it extracts the the set-cookie and puts it in the request headers. |