Is there any way to automatically deploy to a server after I build a flex app, and then debug using the remote url ?
This is totally possible in FlashBuilder, but I am highly hoping that it can be done in FD as well.
You can script any action you want in a batch file and then go to Project->Properties->Build->Post-build-command and enter your batch file execution line.
To jump to a debug URL after compiling, just go into Project->Properties->Output, select "Open document" and type your URL.
If you deploy a debug version of your SWF, you can start FlashDevelop debugger for remote debugging (see Debug menu) and then navigate to the online page where your SWF resides.
Related
I have a batch file that executes:
start cmd /k dotnet run -p projectName
For two separate projects and then launches a shortcut link to the angular project in browser. The only (semi) problem is that the shortcut launches before the dotnet run commands have finished and so the browser believes the site cannot be reached until the dotnet run commands are complete.
I'm trying to not launch the shortcut link until both projects have finished executing the dotnet run command so the "This site can't be reached" dialog never shows up. I don't personally mind it, but it's rather confusing to anyone thinking the application should just open without the need for a reload.
EDIT:
The projects I'm running are a .NET Core Web API & .NET Core (Angular) Web App. The angular app get's compiled and served via dotnet run, but both projects need to remain running in order to listen to their specific ports. And the shortcut link executed at the end of the batch file is just to open the browser at localhost:AngularPort#. I understand a desktop app would have probably been the way to go from the start but for v2, the plan is to host in azure and allow customers to access the site as well instead of just being an internal app.
I found a solution on npm with a package called 'wait-on' which in my case will wait until an http(s) request on that url returns a response with a status code in the 200 range before completing. There's a whole other assortment of use-cases with this package but I only needed it for that.
Here's a link to the package if anyone else runs into this problem:
https://www.npmjs.com/package/wait-on
Edit:
Honestly this was only a problem because the laptop I needed to put the application on didn't have the best CPU stats, so it got hung up trying to serve a local api and angular application simultaneously.
here is my question :
When I build my swf by FlashBuilder, my debugger is active (access via context menu), and I got my logs in the flashlogs.txt.
BUT when I build my swf with maven (flexmojos-maven-plugin), even if I put <debug>true</debug> in the configuration, I hadn't any logs and can't active the debug in the flash application.
Any idea why ?
Informations :
I need to be able to access the debugger and have the trace in the flashlogs.txt without compiling and launching via FlashBuilder.
=> It's for some tester who don't have to access to the sources, just launching the application and testing it
Once you built your swf with Maven, you need to deploy it on your web server.
Example: c:\java\tomcat\webapps\myapp (depending of your back-end)
Then in Flash Builder, in the Flex Build Path configuration for your project, you have to set the output folder to the target folder where you have your web server pick up the SWF you are building.
Set the Output folder URL to point to the context that launches the SWF and you should be good to go.
Example: http://localhost:8080/myapp
And of course be sure to compile with debug mode ;)
I created a Flex app in a Windows XP environment using Flex Builder 3.
From the menubar, I selected "Project->Export Build Release" and moved the files from /bin-release onto my local server (WAMP).
I have a PHP file that connects to a db and delivers some data via XML
Everything works right on my computer. Then I tried to move the app to a mac.
I installed MAMP with the default settings (localhost:8888)
I can connect to the PHP file and get the XML by hitting the appropriate URL on # http://localhost:8888/...
Likewise, I can connect to the html template and the swf executes, but it doesn't seem to be getting the data back, and I don't get any debug info popping up.
Any ideas? Are there security settings enabled by default in Mac OS that would not allow a flex app to request data from a remote resource (i.e. http://localhost:8888/ in this case)?
what is the error that you get?
1. try to catch the FaultEvent
2. do you install any of flash debugger?
The trouble was with the MAMP installation. I reinstalled it, and the app worked.
I develop Flex-Java applications which is running under Apache Tomcat. I use Flex Builder plug-in for Eclipse as my IDE. My application consists of several libraries and modules. I manage all of them as a small maven (flex-mojos) projects.
Does anybody can share some ideas how to setup robust debuging enviroment?
I use Maven & Flexmojos from the command line and the Flash builder 4 plugin inside of Eclipse. In my project I also have a Java/BlazeDS backend I like to debug at the same time as the Flex client on occasion.
Here's what I do:
1) I used cargo to startup an instance of my Java backend that DOES NOT have the SWF or HTML wrapper in it.
2) I've created a "Web Application" debug launch configuration where the launch URL just points to a file (e.g. "/path/to/my/flash-builder/bin/myapp-wrapper.html").
3) When I launch this debug configuration from within Eclipse the Flex debugger Just Works. As soon as a stop point it opened the Flex Debugger perspective automatically opens.
By launching a debug configuration directly from Eclipse I don't have to rebuild and redeploy a WAR file after each change made to the Flex app. In fact, after I shut down the Flex client I just leave the Java server running and reconnect with the next debugging launch.
In order debug the Java side, I start the application server with the JVM debugger command line arguments and launch a Remote Java Debugger debug launch configuration. Eclipse has no problem running both debuggers at the same time.
The only problem with this setup happens when I need to run the Flex web app from an http:// URL (for example to get flashvars to retrieve URL query parameters). In this case it is a long round-trip to get maven to created the WAR and deploy it, then to launch the debugger...after every Flex client source edit. I posted a question on how to make that case better (http://stackoverflow.com/questions/4426053/quickly-debug-flex-java-web-application-from-eclipse).
This is an area of interest to me so let me know what you are looking for and I can probably help more.
I have sit up remote debugging on a Window 2003 server accessed through the Internet. I have VS 2008 SP1 installed on my XP dev box.
I launched the site on the remote server and attached to all the w3wp.exe processes on the remote server. I noticed that the .dll did not load the symbols file. When I try to load the corresponding .pdb file from my local machine, it says file does not match. I have "Require source files to exactly match the original version" unchecked. The assembly on the remote server is the same as the one on my dev box. The site and .dll was copied from dev boc to remote server and code hasn't changed since. So I know .dll and .pdb files should match or at least I need to force the matching.
Questions:
How do I get the .pdb file to load? I know breakpoints won't trigger unless symbols file is loaded. I noticed that the .pdb file does not exist in the "Temporary ASP.NET Files" folder on the remote server. The .dll does.
What's the proper sequence to start debugging remotely inside VS? (Remote set up is done and I can see remote processes).
In VS, I have start page as the url of the remote site. I start without debugging and then attach to w3wp.exe(s) on the remote. Is this all?
Are you running a Web Site or a Web Application (is it a compiled project, that you deploy the DLL for, or a collection of aspx and aspx.cs files that you deploy)?
If it's a Web Application, did you deploy a release build, or a debug build? You won't be able to hit breakpoints when "debugging" a release build, as the code is fairly heavily optimised.
Have you got "debug=true" set in the web.config compilation section? If not, again, debugging is going to be difficult.
Finally, the steps I use when remote debugging are:
Deploy latest debug build of files
Request page on remote server to start/restart application
Ensure that the VS Remote Debugging Monitor is up and running on the remote server
In VS, go to Tools (or Debug) | Attach to Process..., ensure that the remote server is selected in the Qualifier, and select w3wp.exe for the correct app-pool, etc.
Request page that will fire break point.
Debug!
If the breakpoints are hollow (thin red circles rather than filled disks), I'll often check the Stack window in VS to see what has and hasn't been loaded.