Not able to debug with Flex Builder 3 - apache-flex

I use Flex for a short time, use a bit pushed to my client for a solution-oriented monitoring.
Background:
Platform:
Windows XP
Eclipse 3.4 Ganymede
Flex Builder 3.0.2 Licenced
JDK 1.6_20
Firefox 3.6
Flash Player 9 (Debug version)
Server: OSGI (Eclipse equinox) an
instance of jetty service allows HTTP
requests
Requirements:
Make debugger in ActionScript by putting "BreakPoint" to assess the contents of variables.
Problem:
The code does not stop at breakpoint, worse, if a breakpoint is enabled, the module flex does not start.
Actions:
Reinstall all the dev environment (Eclipse, Flex Builder, Flash Player): KO
Removing repo maven modules and complete rebuilds: KO
Restarting Windows: °) KO
Logs:
this is what the log contains just after launching the platform (modules) in debug mode.
java.lang.NullPointerException
Has com.adobe.flexbuilder.debug.breakpoints.FlexLineBreakpoint.findSourceFiles (FlexLineBreakpoint.java: 388)
Has com.adobe.flexbuilder.debug.breakpoints.FlexLineBreakpoint.instantiate (FlexLineBreakpoint.java: 442)
Has com.adobe.flexbuilder.debug.model.FlexDebugTarget.breakpointAdded (FlexDebugTarget.java: 981)
Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ FdbThread.installDeferredBreakpoints (FlexDebugTarget.java: 631)
Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ FdbThread.advanceStateMachine (FlexDebugTarget.java: 662)
Has com.adobe.flexbuilder.debug.model.FlexDebugTarget FdbThread.access $ $ 6 (FlexDebugTarget.java: 636)
Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ 1.run (FlexDebugTarget.java: 738)
Has org.eclipse.core.runtime.SafeRunner.run (SafeRunner.java: 37)
Has org.eclipse.core.runtime.Platform.run (Platform.java: 880)
Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ FdbThread.eventLoop (FlexDebugTarget.java: 718)
Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ FdbThread.run (FlexDebugTarget.java: 779)
at java.lang.Thread.run (Thread.java: 619)

The cause described in the comment by the author of this question (user361222) is correct.
I have 2 additional tips:
after you change the container swf to debug version, you should clear IE caches. I meet problem after I change container swf to debug version, I still cannot debug, but after I clear browser cache, it works.
You don't have to use "nemo440" to see it the swf is debug version. You can right click the flash GUI of your container swf(should before the child swf loading), if the debug menu in the context menu is enabled, the swf is debug version.
If before the child swf load the "debug" menu is disable, but after the child swf load the debug menu is enable, then you must have the issue.

You could try updating your debug player to see if that has an affect.
http://www.adobe.com/support/flashplayer/downloads.html
Where does that log come from? Is it an eclipse log? Or something you see on the server? Is Eclipse crashing?
When you use the 'term' Module are you referring to Flex Modules ( http://livedocs.adobe.com/flex/3/langref/mx/modules/Module.html ) or are you using the term more generically?
If using Modules; have you tried to test the module separate from the rest of the application? Create an application that is the Module instead of using the ModuleLoader. Does that have an affect?
Which version of the Flex SDK are you using? Can you upgrade to 3.5 or 4.0 ?

A work around is to do following :
Export preferences and exit Eclipse
Delete .metadata folder
Launch Eclipse and recreate the workspace
Import preferences.
It works all the time.

Be sure to use the 32bits version of Firefox...
Got the same issue and i resolved it by installing win32 version of Firefox...

Related

CEF / CEFSharp Compiling Issue

Environment: Windows 10, WinForm (.Net 4.7.2) x64 only, CefSharp 71.0.2.0
We need support for playing MP4 in our product (we have a license) and we are attempting to recompile CEF with proprietary codecs enabled.
We're using the instructions from:
https://bitbucket.org/chromiumembedded/cef/wiki/MasterBuildQuickStart.md#markdown-header-windows-setup
Our create.bat file looks like:
set CEF_USE_GN=1
set GN_DEFINES=is_win_fastlink=true proprietary_codecs=true ffmpeg_branding=Chrome
set GN_ARGUMENTS=--ide=vs2015 --sln=cef --filters=//cef/*
call cef_create_projects.bat
Our update.bat file looks like
set CEF_USE_GN=1
set GN_DEFINES=is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome
set GN_ARGUMENTS=--ide=vs2015 --sln=cef --filters=//cef/*
python ..\automate\automate-git.py --download-dir=C:\code\chromium_git --depot-tools-dir=C:\code\depot_tools --no-distrib --no-build --branch=3578
We are trying to specifically target build 3578 to match the build that comes with CEFSharp. We also enabled proprietary codec using the flag: proprietary_codecs=true
After about 2 hours and no errors the build completes successfully. When we run our page using cefclient.exe from the output build everything works as expected, the video plays correctly.
We copy the following files from the output build folder to our .Net application replacing the files packaged with CEFSharp:
cef.pak
cef_100_percent.pak
cef_200_percent.pak
cef_extensions.pak
chrome_elf.dll
d3dcompiler_47.dll
devtools_resources.pak
icudtl.dat
libcef.dll
libEGL.dll
libGLESv2.dll
natives_blob.bin
snapshot_blob.bin
v8_context_snapshot.bin
\locales\*.*
\swiftshader\libEGL.dll
\swiftshader\libGLESv2.dll
When running our app, the app terminates immediately and this is written to the debug.log file:
[0326/094610.429:FATAL:cookie_manager_impl.cc(620)] Check failed: false. context not valid
Backtrace:
cef_string_utf16_to_upper [0x00007FFD2B53E1E5+1713061]
cef_string_utf16_to_upper [0x00007FFD2B53D44D+1709581]
cef_string_utf16_to_upper [0x00007FFD2B5765D5+1943445]
cef_zip_reader_create [0x00007FFD2B3107B8+159661640]
cef_cookie_manager_get_global_manager [0x00007FFD219B0436+54]
CefCookieManager::GetGlobalManager [0x00007FFD7322879E+94]
(No symbol) [0x00007FFD4E1C07DE]
[0326/094721.035:FATAL:cookie_manager_impl.cc(620)] Check failed: false. context not valid
I was able to see that 71.0.2.0 uses CEF 3.3578.1870.gc974488 / Chromium 71.0.3578.98 from:
https://github.com/cefsharp/CefSharp/commit/7d24861e7af79fc4721eb498bb8417b5aa6cad97
When we run cefclient.exe from our build and navigate to chrome://about it displays:
CEF 3.3578.1870.gc974488
Chromium 71.0.3578.98
Which matches the CEFSharp release notes page.
Any suggestions would be greatly appreciated!

Namespace 3.6 in the application descriptor file should be equal or higher than the minimum version 13.0 required by the Flex SDK

I am new to Flash Builder and setup the 4.7 environment according to these instructions: http://www.adobe.com/devnet/air/articles/ane-android-devices.html
The end of the tutorial involves "Export Release Build" of ANESampleTest (a Flex project) and I am getting this error:
"Namespace 3.6 in the application descriptor file should be equal or higher than the minimum version 13.0 required by the Flex SDK"
I do not have a good understanding of Flash/Flex/Air/etc, but following the tutorial to the letter to install Flash Builder, updating the SDK to 3.6, and the partial 'overlay' steps. How do I resolve this error message?
The fix: Change the namespace on the second line of /src/ANESampleTest-app.xml
FROM: <application xmlns="http://ns.adobe.com/air/application/3.6">
TO: <application xmlns="http://ns.adobe.com/air/application/13.0">
A brief and incomplete background:
The file /src/ANESampleTest-app.xml is the ‘application descriptor file’. When using the project files downloaded with the tutorial (that contained the 3.6 reference), the builder did not find this compatible with the configuration on my computer (a trial version I installed today - 5/3/2014 - and patched according to the tutorial). I never did figure out how to lookup valid namespaces and am still confused about how all the sdk’s relate to each other. I stumbled upon this solution by creating a fresh new project and found that the namespace specified by the new project wizard was “13.0” on this line of this file.

Configuration files are ignored after migrating to Servicemix 5

We use a .cfg file in ./etc directory to configure our bundle in ServiceMix. Everything worked fine in SMX 4.5.3, but when migrating to the 5th version the file is not picked up. When the bundle encounters a property the following exception is thrown:
java.lang.IllegalArgumentException: Property with key [xslt.dir] not found in properties from text: {{xslt.dir}}, StackTrace: org.apache.camel.RuntimeCamelException: java.lang.IllegalArgumentException: Property with key [xslt.dir] not found in properties from text: {{xslt.dir}}
However, if I put the properties in default-properties section in my blueprint configuration, it works.
Also, the console command config:list actually shows the properties for the bundle in spite of the exception:
Pid: misrouter
BundleLocation: mvn:ru.mig/mis-router/1.0-SNAPSHOT
Properties:
service.pid = misrouter
felix.fileinstall.filename = file:/home/petr/programs/5.0.0-apache-servicemix/etc/misrouter.cfg
xslt.dir = /home/petr/programs/5.0.0-apache-servicemix/xslt
So was something changed in SMX 5 configuration mechanism or is there a bug in it?
What version of the JDK/JRE are you using? When I was trying this out a few minutes ago to answer your question, I also had some problems using the 1.7.0_15 version I had installed and upgrading to the latest 1.7.0_51 fixed those for me.
Actually it's related to Camel vm component, a bug was created for SMX

Liferay 6 on Glassfish 3.1 - issue using liferay-ui tags in portlet jsp files

We are seeing this issue on our current Glassfish 3.1 cluster setup. Below are details of issue
- We are running Glassfish version 3.1
We are running liferay 6.0.6
The liferay war is deployed on the Glassfish cluster and working fine on both the nodes.
The same liferay war works fine one Tomcat server as well.
When we deploy our custom portlets on Glassfish cluster it starts working immediately after deployment. (before doing a restart of glassfish cluster)
Once we do a restart of the cluster nodes the same portlet application stops working and Complains and give attached error.
My research till now shows that the java.lang.NoClassDefFoundError: com/liferay/portal/util/PropsValues is part of portal-impl.jar file which is part of liferay portal and should be made available to our portlet. Somehow after the restart the jar files are loaded in a different manner and the same jar file is not available to portlet.
We have also tried the Glassfish 3.1 Bundled liferay 6.1 setup and see the same issue on it as well.
As suggested by liferay forums we have placed the portal-service.jar and portlet.jar in [glassfish home]/lib directory.
when we do a lsof -p pid on the glassfish node instance process it shows the required jar file is open by this process. Not sure why is this not available to our application.
I would appreciate any help or pointers to resolve/investigate this issue.
java.lang.NoClassDefFoundError: com/liferay/portal/util/PropsValues
at org.apache.jsp.html.taglib.ui.search_005fiterator.page_jsp._jspService(page_jsp.java from :500)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:111)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:403)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:492)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:378)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1539)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:343)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:217)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72) at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:113)
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:68)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:256)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:217) at org.apache.catalina.core.ApplicationDispatcher.doInvoke(ApplicationDispatcher.java:785)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:649)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:604)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:534) at com.liferay.taglib.util.IncludeTag.include(IncludeTag.java:323)
at com.liferay.taglib.util.IncludeTag._doInclude(IncludeTag.java:418)
at com.liferay.taglib.util.IncludeTag.doEndTag(IncludeTag.java:92)
This is a related thread on liferay forum by me but I have not really got any response on it from anyone. [Same issue posted on liferay Forum]
i have also tried placing portal-impl.jar in my portlet/WEB-INF/lib dir (which is not recommended way) and I failed since it requires me to bring all other dependent jars in it too.
I am now running out of options and thinking about implementing the pagination feature using some other third party library instead of using liferay tags.
Here is the specific tag which is giving us error
<liferay-ui:search-iterator />
List of jars in my portlet WEB-INF/lib folder
SiebelClientWS-0.0.1-SNAPSHOT.jar
spring-asm-3.0.5.RELEASE.jar
XmlSchema-1.4.7.jar
spring-aspects-3.0.5.RELEASE.jar
aspectjrt-1.6.11.jar
spring-beans-3.0.5.RELEASE.jar
aspectjweaver-1.6.11.jar
spring-context-3.0.5.RELEASE.jar
axiom-api-1.2.11.jar
spring-context-support-3.0.5.RELEASE.jar
axiom-impl-1.2.11.jar
spring-core-3.0.5.RELEASE.jar
axis2-1.5.4.jar
spring-expression-3.0.5.RELEASE.jar
axis2-kernel-1.5.4.jar
spring-jdbc-3.0.5.RELEASE.jar
axis2-transport-http-1.5.4.jar
spring-tx-3.0.5.RELEASE.jar
axis2-transport-local-1.5.4.jar
spring-web-3.0.5.RELEASE.jar
c3p0-0.9.1.2.jar
spring-webmvc-3.0.5.RELEASE.jar
commons-codec-1.4.jar
spring-webmvc-portlet-3.0.5.RELEASE.jar
commons-httpclient-3.1.jar
util-bridges.jar
commons-logging.jar
util-java.jar
flexjson-2.1.jar
util-taglib.jar
httpcore-4.0.jar
woden-api-1.0M9.jar
httpcore-nio-4.0-beta1.jar
woden-impl-commons-1.0M9.jar
log4j.jar
woden-impl-dom-1.0M9.jar
neethi-2.0.2.jar
wsdl4j-1.6.2.jar
spring-aop-3.0.5.RELEASE.jar
wss4j-1.6.2.jar
I changed
/html/taglib/ui/search_paginator/page.jsp
/html/taglib/ui/search_iterator/page.jsp
/html/taglib/ui/page_iterator/start.jsp
and removed the calls to PropsValues and replaced them with calls to the com.liferay.portal.kernel.util.PropsUtil and PropsKeys instead and that go the rid of the error for me.
I made an improvement request
http://issues.liferay.com/browse/LPS-30660
com/liferay/portal/util/PropsValues is part of portal-impl.jar file which is part of liferay portal and should be made available to our portlet.
That is not true, portal-impl.jar is not available to your portlets and it is not meant to. You MUST NOT put it in your WEB-INF/lib. That jar is only available, and should be that way, to Liferay (liferay application).
Can you show contents (list of jars) of your (deployed) portlets WEB-INF/lib?

Error when converting a site from Flex 3 to Flex 4

I'm moving a Flex 3 site to Flex 4, but when I run the application, it attempts to download a .swz file from Adobe, and gives the following error:
*** Security Sandbox Violation ***
Connection to http://fpdownload.adobe.com/pub/swz/tlf/1.1.0.604/textLayout_1.1.0.604.swz halted - not permitted from http://localhost/Fl/CityGIS/main.swf
Error #2048: Security sandbox violation: http://localhost/Fl/CityGIS/main.swf cannot load data from http://fpdownload.adobe.com/pub/swz/tlf/1.1.0.604/textLayout_1.1.0.604.swz.
Failed to load RSL http://fpdownload.adobe.com/pub/swz/tlf/1.1.0.604/textLayout_1.1.0.604.swz
Failing over to RSL textLayout_1.1.0.604.swz
Following this is an attempt to download the same file from localhost.
Is there a way to configure the SDK to get these files, or an issue with the configuration of my application?
I found I only had this problem when I using: -use-network=false, and I was attempting to run the html locally and the .swf was accessing locally files (outside the flex security free folders).
My workaround is to update sdks//frameworks/flex-config.xml (in the Flash Builder directory), and swap the order runtime shared paths: for example:
<runtime-shared-library-path>
<path-element>libs/textLayout.swc</path-element>
<rsl-url>http://fpdownload.adobe.com/pub/swz/tlf/1.1.0.604/textLayout_1.1.0.604.swz</rsl-url>
<policy-file-url>http://fpdownload.adobe.com/pub/swz/crossdomain.xml</policy-file-url>
<rsl-url>textLayout_1.1.0.604.swz</rsl-url>
<policy-file-url></policy-file-url>
</runtime-shared-library-path>
TO:
<runtime-shared-library-path>
<path-element>libs/textLayout.swc</path-element>
<rsl-url>textLayout_1.1.0.604.swz</rsl-url>
<policy-file-url></policy-file-url>
<rsl-url>http://fpdownload.adobe.com/pub/swz/tlf/1.1.0.604/textLayout_1.1.0.604.swz</rsl-url>
<policy-file-url>http://fpdownload.adobe.com/pub/swz/crossdomain.xml</policy-file-url>
</runtime-shared-library-path>
You'll have to do this for the other 5 or so entries.
Adobe should really look at this, and fix the problem.
Hope this helps.
Cheers
Parmy
I think the problem is that the location it is using for the textLayout swc
http://fpdownload.adobe.com/pub/swz/tlf/1.1.0.604/textLayout_1.1.0.604.swz
redirects to
/pub/swz/flex/4.1.0.15186/textLayout_1.1.0.601.swf
and the cross domains policy is not happy about that.
I think this points to an issue with the version of the sdk that you are using. You can go into sdks/<FRAMEWORK_VERSION>/frameworks/flex-config.xml (in the Flash Builder directory) and see exactly how the runtime shared library path is configured for textLayout.swc. This is what I have for flex_sdk_4.1.0.15186:
<!-- TextLayout SWC -->
<runtime-shared-library-path>
<path-element>libs/textLayout.swc</path-element>
<rsl-url>textLayout_1.1.0.601.swf</rsl-url>
<policy-file-url></policy-file-url>
<rsl-url>http://fpdownload.adobe.com/pub/swz/flex/4.1.0.15186/textLayout_1.1.0.601.swf</rsl-url>
<policy-file-url>http://fpdownload.adobe.com/pub/swz/crossdomain.xml</policy-file-url>
</runtime-shared-library-path>
I suggest try switching to the latest 4.1 sdk and recompiling.
Hmmmm - generally this is because the site you are accessing does not contain a crossdomain.xml file. However I can download it from here.
Try adding this to your compiler options: -use-network=false
Then clean and force build your app.
If that doesn't work, and just grasping for straws, but have you tried to manually download it and place it in your project lib space?
Also, are you sure you are updated to Flex 4.1?
I just checked my local KB (evernote) and mentioned that FireFox sometimes has an issue with caching, and that restarting FF solved it once for me.

Resources