On 4/3/2017 12:05 PM, olegkon wrote:
Hi,
We have a large legacy Flex4 web app (with Java8, Spring4, BlazeDS4,
Spring-BlazeDS integration),
which we want to start gradually converting to Angular2.
At this point we are trying to display Angular2 SPA as HTML5
in Flex Group via LinkButton or as a tab. Is it possible?
Has anyone ever tried that?
Do we have to use iFrame or can do without it?
I never tried it with a single page app, but there are plenty of
options / components to display HTML as if it were part of a Flex app.
It's been ages since I researched that, but I think most of them use an
iframe trick; and I recommend investigating the same approach.
What to do with session management?
Assuming you are talking about client side session state; I would
probably handle session management independently between the Flex app
and the Angular app. Send a URL variable or something similar to the
Angular app so it can load relevant session data from the server.
We would like to reuse Spring Security (need to add Spring Boot for that?)
This is where my knowledge breaks down as I have limited Java / Spring
experience.
I worked on a Single Page App [Angular 1] for a client who used Spring
to manage sessions server side. I never understood why a single page
app needed to maintain server side sessions, however it worked with
minimal issues.
If that is not possible, we can avoid using Java (as of now we have Angular2
app more like MEAN
without Mongo - calling DB Stored Procs via MSSQL client running on NodeJS),
so can try using security tokens (JWT).
If you have Java experience, and a lot of services already built for
the Flex app; my impulse is to wrap those services to return JSON
instead of AMF. That will probably save you lots of time compared to
switching to an entirely new platform.
Is that helpful?
--
Jeffry Houser
Technical Entrepreneur
http://www.jeffryhouser.com
203-379-0773