Getting Flex Data Services running on OS X/Intel
I'm by no means a J2EE or FDS expert, but I hacked away for a bit tonight and got FDS up and running on my Intel MBP.
Here's a step-by-step guide for what I did. If you're up to snuff with J2EE deployments, it's likely to seem elementary...this is a guide for CF developers who don't care to know much of anything about systems administration.
1. Use the JRun admin console to create a new server named "flex." Don't bother trying to start it once it's done.
2. Open finder, and go to /Applications/JRun4/servers . Ctrl-click "flex" and do a Get Info. In "Ownership & Permissions," expand the details. Unlock if necessary, and change the owner to your user. Give the admin group read & write access. Then, do "Apply to enclosed items" (this is important! My first time through, I did each dir individually, going through the stack of errors in Terminal!
3. Try to do the following at the command line:
Some console messages should go by, but you should only get warning, info, and user types, with the last line reading:
Ok, hit CTRL-C to shut it down.
4. Now, we need to deploy Flex Data Services. This means we need to get our grubby unsupported-deployment-seeking paws on flex.war. While we're at it, we'll get the samples and the flex-admin bits going, too.
5. Find a Windows machine (or start Parallels), and download the Flex Data Services 2 installer. Run it, and choose a J2EE install to existing J2EE server. Install to c:fds2 (the default).
6. Go into c:fds2 and grab flex.war, flex-admin.war, and samples.war. Copy them to /Applications/JRun4/servers/flex/.
7. Under /Applications/JRun4/servers/flex, create three directories: "flex", "flex-admin", and "samples".
8. Copy each .war into its respective dir.
9. In terminal, go into each directory and extract the war, such as:
10. Copy commons-logging.properties file from the samples/WEB-INF/flex/jars/ to /samples/WEB-INF/classes - I'm not too sure how/why this resolves the commons-logging conflict, but I read it on David Fekke's blog, and it works.
11. Start the Flex server with the following command:
You'll see a lot more stuff go by this time.
11. Go to your JRun administrator console. Look at the "flex" server's HTTP Port setting (mine is 8301). Browse to http://localhost:[that number], such as http://localhost:8301. You should get a "Welcome to JRun 4!" message. Yeeha.
12. Going to http://localhost:8301/flex will give you a nice message about this being a template application. Whee.
13. Ok, http://localhost:8301/flex-admin will give you the runtime monitoring/management console.
14. And, last, http://localhost:8301/samples will let you drill down into the Notes sample to see a sample of FDS in action, pushing data happily between client instances!
1 comments - Posted by Joe Rinehart at 10:42 PM - Categories: Flex | Flex and ColdFusion