Tomcat shutdowing when remote object is calling secondtime from flex to blazeds
Hi All,
I am new to flex and started working on that.now i called one remote object from flex through blazeds.its working fine but when i call second time tomcat is shutdowing .again if i start tomcat it is working fine.
what is the problem does any one helps?
sudheer
Thanks for the tip Joe.
It's not quite what I was looking for, but it gave me some ideas.
The blog post describes how to create your own server to handle the file stream. With BlazeDS & Java EE app server there's no need to implement the low level stuff.
One option would be to read the data on Flex side in chunks and make a request to send each chunk at a time, but I don't know whether this helps at all. Might just slow down the network.
Another option is to write a custom adapter for BlazeDS endpoint, but I don't know enough details on this to say is it possible or not.
Third option is to use regular servlet code and Apache Commons FileUpload module.
Still interested hearing opinions from people working with BlazeDS.
Similar Messages
-
Hi,
I want to set deadlock priority of a stored proc to low so that when ever any one calls it from entity or command object it should use same priority.
some body sugested to put
set deadlockprioirty low
go
exec yourSP()
but in this case i have to change my bussiness layer.
is there any other way from database which do the task?
yours sincerley.You can modify your stored procedures and add the code line
set deadlock_priority low
at the very beginning of the SP.
Olaf Helper
[ Blog] [ Xing] [ MVP] -
Calling webservice from Flex?
Hi,
I get the error when I call webservice from Flex.Can you tell
me why this happen?
Thanks
Mark
[RPC Fault faultString="Security error accessing url"
faultCode="Channel.Security.Error" faultDetail="Destination:
DefaultHTTP"]
at mx.rpc::AbstractInvoker/
http://www.adobe.com/2006/flex/mx/internal::faultHandler()
at mx.rpc::Responder/fault()
at mx.rpc::AsyncRequest/fault()
at DirectHTTPMessageResponder/securityErrorHandler()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/redirectEvent()I think this means that the source of the web service does
not have a crossdomain.xml file on it allowing access from your
site. Try adding one to the root of the server and see if that
fixes the problem.
hth,
matt horn
flex docs -
Exception when remotely executing Export-CsArchivingData cmdlet from C# managed code
Hi,
Hopefully this is the right forum.
The issue is specifically about remotely executing Export-CsArchivingData cmdlet from C# managed code.
I use RunspacePool to connect to remote Lync server as described here:
http://msdn.microsoft.com/en-us/library/ee706598(v=vs.85).aspx
I can connect to remote Lync server and execute many Lync cmdlets (e.g. Get-CsUser, Get-CsSite, Get-CsPool, etc) and get the results just fine.
However, when it tries to execute Export-CsArchivingData cmdlet remotely, it throws the following exception:
System.AggregateException: One or more errors occurred. ---> System.Management.Automation.RemoteException: The term 'Export-CsArchivingData' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the
name, or if a path was included, verify that the path is correct and try again.
at System.Management.Automation.Runspaces.AsyncResult.EndInvoke()
at System.Management.Automation.PowerShell.EndInvoke(IAsyncResult asyncResult)
Additional info:
1. I created a custom RBAC role and added Export-CsArchivingData to it. Then, assign this new role to the account that runs the application.
2. Using regular powershell (not Lync powershell) from the machine (that I run my app from) with Lync admin tool installed and ran with the account that has the custom RBAC role assigned, I can connect to remote Lync server and execute Export-CsArchivingData
just fine.
3. Execute the app using the same above account (that has custom RBAC role) on two machines (one with Lync admin tool installed, one without) and connect to remote Lync server.
Same behavior on both machine, I got the above the exception when executing Export-CsArchivingData and no problem when executing other Lync cmdlets mentioned above.
Yes, even from a machine without Lync admin tool installed, I can execute other Lync cmdlets mentioned above.
At this point, I am not sure why I get the above exception when Export-CsArchivingData is executed from my app while I can connect to remote Lync server and call Export-CsArchivingData just fine via regular Powershell, both on the same machine.
Note: I do not call Import-Module Lync in C# managed code since it is not necessary so far for executing other Lync cmdlets remotely.
Any idea on what to look for?
Thanks in advance.I would recommend you call Import-Module Lync first, the command is not recognized.
Lisa Zheng
TechNet Community Support -
Hi,
I know how to call a HTTPService in actionscript as follow. I was wondering how to call HTTPService in Flex (not from actionscript).
post_submit_tn_service.send();
<mx:HTTPService id="myservice"
</mx:HTTPService>Hi,
Here is my problem.
Let's assume I have two mxml files.
The mxml file2 contains HTTPService which is called in a ViewStack from file1.
When ViewStack is set to file2 for the second time (to update datagride), createComplete in file2 is not being called. So, no HTTPService is called when ViewStack is set to file2 for the second time.
<!-- file1 -->
<mx:ViewStack id="vsMyStack" x="0" y="0" width="100%" height="100%" >
<mx:Canvas id="file1" label="Login" width="100%" height="100%">
</mx:Canvas>
<mx:TabNavigator id="viewstack1" width="100%" height="100%">
<views:file2 width="100%" height="100%"/>
<views:file3 width="100%" height="100%"/>
</mx:TabNavigator>
</mx:ViewStack>
<!-- file2 ->
<mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml" creationComplete="init();">
private function init():void
post_service.send();
<mx:HTTPService id="post_service"
url="http://localhost/prod-ar/webservices/get_day_of_year.php"
method="POST"
</mx:HTTPService>
</mx:VBox> -
Calling Javascript from Flex through FAB
What's the standard way of calling JavaScript functions from
Flex through the FA Bridge?
i.e. is there a new way other than navigateToURL or
ExternalInterface.call()
Most of the examples I've seen are scripting Flex from
JavaScript, not the other way around.
Thanks.Hello,
You need to register the JavaScript function as a callback to
a Flex action. You can do this from javascript in a function that
gets called when the flash movie has finished loading. Then, when
the Flex event is triggered it will execute the JavaScript
function.
Hope this helps,
Cristian -
Serialize remote objects: where to go from here?
Hi everybody.
I have a client that connects to a server through RMI, gets some objects that represent records in the remote database.
Now I want to "persist" those objects locally.
I'm evaluating among differents approaches to this problem.
thanks in advance
AgostinoThe records fetched from the server represent tasks that will be executed on the clients in order to manage archiviation on clients in a centralized manner.
The tasks will run for some time, and I can't assume that the network will stay available all that time, so they must be 'disconnected'.
Furthermore, tasks have to "survive" a client restart, without firing a connection in order to "remember" assigned tasks each time a client is restarted.
thanks in advance
Agostino -
How to store Connection object and call it from other programs.
Hi,
I am trying to connect to the database, store the connection object and use this connection object from other standalone java programs.
Can any one tell me how to do this? I've tried in the following way:
In the following program I am connecting to the database and saving the connection object in a variable.
public class GetKT2Connection {
public static void main(String[] args) {
String url = "jdbc:odbc:SQLDsn;
String dbUser = "sa";
String dbPwd = "sa";
Connection kt2conn = Connection connection = java.sql.DriverManager.getConnection(url, dbUser, dbPwd);
if(kt2conn == null) {
System.out.println("Database Connection Failure!");
else {
System.out.println("Connected to Database...");
GetKTConnectionObj.storeKT2ConnectionObj(kt2conn);
} Here is the program to save connection object in a variable.
public class GetKTConnectionObj {
static Connection kt2Connection = null;
public static void storeKT2ConnectionObj(Connection conn) {
kt2Connection = conn;
public static Connection getKT2ConnectionObj() {
try {
return kt2Connection;
catch(Exception e){
System.out.println(e);
return null;
}Now from the following code I am trying to get the connection object that is stored. But this is throwing NullPointerException.
public class Metrics_Migration {
public static void main(String args[]) {
try {
java.sql.Connection connection_1 = GetKTConnectionObj.getKT6ConnectionObj();
catch(Exception e){
}kt2Connection is null. You need to store it first, to make it not null. Otherwise it will stay null forever. And why on earth are you trying to do this THIS way?
If you are running the two applications separately, it wont work either. -
Not able to call Java from flex using RemoteObject
hi,
I am badly stuck in compiling my flex app to connect to Java code on the server side using LCDS remoteObject component.
My swf file wouldn't trigger a method on the Java class, below is the snippet of all relevant codes, i just don't know what to do.
Please help on what am i missing or what i am doing wrong in this.
------> 1. here is the ant target that uses mxmlc compiler option
<target name="flex-compile" depends="copy-all">
<mxmlc
file="${uisrc}/OnlineServicesPortal.mxml"
output="${prjdeploydir}/OnlineServicesPortal.swf"
actionscript-file-encoding="UTF-8"
keep-generated-actionscript="true"
incremental="true"
as3="true">
<load-config filename="${FLEX_HOME}/frameworks/flex-config.xml"/>
<source-path path-element="${FLEX_HOME}/frameworks"/>
<library-path dir="${FLEX_HOME}/frameworks" append="true">
<include name="libs" />
</library-path>
<compiler.source-path path-element="${FLEX_HOME}/frameworks"/>
<compiler.include-libraries dir="${FLEX_HOME}/frameworks" append="true">
<include name="libs/datavisualization.swc" />
<include name="libs/fds.swc" />
<include name="libs/player/10/playerfds.swc" />
<include name="locale/en_US/datavisualization_rb.swc" />
<include name="locale/en_US/fds_rb.swc" />
</compiler.include-libraries>
<!--compiler.services filename="${src}/flex/services-config.xml"/-->
<!--context-root context-path="portal"/-->
<default-size width="500" height="600" />
</mxmlc>
</target>
---------2. services-config.xml file
<channel-definition id="my-amf" class="mx.messaging.channels.AMFChannel">
<endpoint url="http://{server.name}:{server.port}/{context.root}/messagebroker/amf" class="flex.messaging.endpoints.AMFEndpoint"/>
<properties>
<polling-enabled>false</polling-enabled>
</properties>
</channel-definition>
<channel-definition id="my-http" class="mx.messaging.channels.HTTPChannel">
<endpoint url="http://{server.name}:{server.port}/{context.root}/messagebroker/http" class="flex.messaging.endpoints.HTTPEndpoint"/>
</channel-definition>
----------3. remoting-config.xml file
<service id="remoting-service"
class="flex.messaging.services.RemotingService">
<adapters>
<adapter-definition id="java-object" class="flex.messaging.services.remoting.adapters.JavaAdapter" default="true"/>
</adapters>
<default-channels>
<channel ref="my-amf"/>
<channel ref="my-http"/>
</default-channels>
<destination id="portal">
<properties>
<source>com.mssb.portal.impl.PortalService</source> <!---this class file is valid & exists-->
</properties>
</destination>
</service>
-----------4. mxml file
<mx:RemoteObject id="myRO" destination="portal" result="createFieldsResultHandler();" fault="createFieldsFaultHandler();">
</mx:RemoteObject>
myRO.persistServiceDefinition(serviceDef) //called from action script function invoked upon a click of a button.actually , I have laready given print stataement for the data in the context property file that you can see in the output. Today I am also able to call the bpel process using the same java program from my DOS command promt(cmd). Don't understand why the problem is occuring in unix.
please help. -
Calling Activex from Flex -- Downloading activex on client machine.
Hi,
I am buling a webapplication(RIA) in flex and hosting it in IIS. I need to call an activex from this web application. Also when I try to access the application from client machine , I should be able to download the activex on client through application.
Please provide any possible help.what oleg2 is writins is oke but I think
it is easier to write you one wrap around this sql-call, because then you have to parse some parameters and do other additional stuff
PROCEDURE "P_EXECUTE_WORKFLOW"("P_WORKSPACE" IN VARCHAR2, "P_LOCATION_NAME" IN VARCHAR2, "P_WORKFLOW_NAME" IN VARCHAR2, "P_CUSTOM_PARAMS" IN VARCHAR2 DEFAULT '","', "P_SYSTEM_PARAMS" IN VARCHAR2 DEFAULT '","') ; -
Call JSFL from Flex Air application
Hi,
I have a Flex Air application that converts old style flash
text var txt files into XML. As part of the process it creates a
jsfl file that when run will automate through older FLAs and
upgrade them with changes required.
My question is this. Using the command
fl.runScript(locationOfJSFLscript) in flash, it will automatically
call the script and execute it. How do I do the same in Flex? i.e.
I have a button in the application. I press it and it sends the
call to run the script.
Thank youOf course you may have some unstated reason for doing this in Air, but if not...
Google photoshop droplet....
Bob -
How to call SKYPE from Flex application ?
The basic idea is this. I've got Flex application, to simplify the problem, let's say it's phonebook.
Data in this phone book is pulled from SQL server and telephone numers are changing daily.
I'm choosing a person, and I have button - CALL CONTACT ...
How to link this button to his current telephone number to call this number via SKYPE ?
There is such a way if you have HTML site - http://www.skype.com/intl/en-gb/business/features/calling/buttons/
Have you any idea how to make such button in Flash / Flex ??navigateToURL() ? http://livedocs.adobe.com/flex/3/langref/flash/net/package.html#navigateToURL%28%29
However, it looks like the Skype HTML has some form of JavaScript involved. If it's doing something special you may be Out of luck. -
Two remote objects calls on the same php class
Hi to all,
I've encountered a strange issue while developing with remote objects.
I've a mxml component with an init() method inside which is called by a menu.
When the init() method is called it makes 7 remote object calls which are bound to some components' dataprovider.
Among this calls I've got 2 remote object which refer to the same remote class. This because I have to call the class twice and the bind the result to two different combobox. Below you find the code:
<mx:RemoteObject id="myFile" source="myRemoteClass" destination="amfphp" showBusyCursor="true" makeObjectsBindable="true" fault="traceFault(event)"/>
<mx:RemoteObject id="myXls" source="myRemoteClass" destination="amfphp" showBusyCursor="true" makeObjectsBindable="true" fault="traceFault(event)"/>
in the init function I make this calls:
myFile.listDir("dir_1")
myXls.listDir("dir_2")
then in the mxml code I bound the result of myFile to combobox1 and the result of myXls on combobox2.
The problem arise when I call the myXls' listDir method. When I call it I receive the following error:
code:
Client.Error.DeliveryInDoubt
Message:
Channel disconnected
Detail:
Channel disconnected before an acknowledgement was received
The strange thing is that not only the myXls object returns this error, but also all the other 6 remote object return the same error above.
I'm not sure, but I guess that the error could be caused by the two remote object which call the same php remote class. If I comment one of the two calls everything works fine.
Do you have any suggestion about?
Thanks!!
Bye
LukeHi Jan.
1) We have the 2 VO, each with 3 rows to fill in data. What I mean is that when i just fill in all the fields for the first row of the first VO, and the value of one of these fields is bigger than 50, then after the exception is thrown and the message is displayed, the fields for the first VO are duplicated and shown in the second VO as if the user had inserted them.
2) We tried yesterday the validateEntity and a Method and Atributte Validator approaches after reading that white paper with the same results.
The validation is correctly done using any of the those methods.
I will try to reproduce this issue with the HR schema.
Thanks in advance once again. -
Premature Garbage Collection of Remote Objects
I have a problem with distributed garbage collection and RMI. In CSPoker we try to support RMI for client-server communication. The client looks up the server through the registry, calls the login method and receives back a Remote Object reference called ServerContext. The client can register Remote even listener Objects with the server.
In both directions we occasionally see:
java.rmi.NoSuchObjectException: no such object in table
The behaviour is completely unpredictable. Some developers never see it, others see it all the time. Even on the same machine, sometimes it failes immediately
and sometimes it fails after a while. One person running the Sun JRE 6 on Windows has this poblem most frequently.
Can this be a bug or do we misinterpret something? The way we see it, as long as the client leases the Remote Object it shouldn't be GCed. All tests are run on localhost so no network partition can occur.
The problem would probably be solved if we hold static references to all Remote Objects in the local JVM. This is not an option because we want the Objects to be GCed once the lease expires.
Here are 2 debugging outputs of server runs with RMI logging enabled:
http://cspoker.pastebin.com/f27a7d6fc
As you can see, the lease requests are coming through but a NoSuchObjectException is thrown and the Object is finalized.
http://cspoker.pastebin.com/f732797d2Thanks for the quick reply.
For instance:
11:56:02,427 DEBUG (org.cspoker.common.api.shared.context.ForwardingRemoteServerContext.java:72) [finalize] - Garbage collecting old context: org.cspoker.server.rmi.export.ExportingServerContext@15a8767
07.11.2008 11:56:02 sun.rmi.server.UnicastServerRef logCall
FEINER: RMI TCP Connection(2)-10.0.4.106: [10.0.4.106: sun.rmi.transport.DGCImpl[0:0:0, 2]: java.rmi.dgc.Lease dirty(java.rmi.server.ObjID[], long, java.rmi.dgc.Lease)]
07.11.2008 11:56:03 sun.rmi.transport.Transport serviceCall
FEIN: RMI TCP Connection(2)-10.0.4.106: [10.0.4.106] exception:
java.rmi.NoSuchObjectException: no such object in table
at sun.rmi.transport.Transport.serviceCall(Transport.java:129)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:466)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:707)
at java.lang.Thread.run(Thread.java:595)The context Object is exported and returned to the client here :
return (ExternalRemoteServerContext) UnicastRemoteObject.exportObject(context, 0);Then [the object|http://code.google.com/p/cspoker/source/browse/trunk/server/rmi/src/main/java/org/cspoker/server/rmi/export/ExportingServerContext.java?r=1023] that was just exported is GCed.
11:56:02,427 DEBUG (org.cspoker.common.api.shared.context.ForwardingRemoteServerContext.java:72) [finalize] - Garbage collecting old context: org.cspoker.server.rmi.export.ExportingServerContext@15a8767Then a lease request comes in:
FEINER: RMI TCP Connection(2)-10.0.4.106: [10.0.4.106: sun.rmi.transport.DGCImpl[0:0:0, 2]: java.rmi.dgc.Lease dirty(java.rmi.server.ObjID[], long, java.rmi.dgc.Lease)]Then the client calls a method on the remote object and the NoSuchObjectException is thrown.
The behaviour is non-deterministic in any case but yes, on the Linux JVM I'm not seeing the problem, somebody on Windows gets it all the time. -
Getting ie error when calling event from code.
Hi all!
I've got an application (running on 6.40 sp8, ep6 sp2) that is pretty basic by all means. Since I want to implement some way to tell the user when he/she has made an error or just to inform him/her about something, I decided to use the ConfirmationDialog.
I've created an action called onActionShowErrorMessage in my view. This action is tied to my controller and an event defined in the controller.
Hence, when I want to show the ConfirmationDialog to show the user an error message, I call the controller method and in the method I fire the event that my view method is looking for.
So far so good..
When I call my controller method from a button action in the view everything works nicely, but when I try to call it from the wdInit method it fails?! I do get the ConfirmationDialog up but I also get an IE error window telling me that IE is trying to open a page it cannot find. I have no idea why it tries to open any page at all, since there is no navigation defined for this action.
Anyone got an idea? I couldn't find any good stuff in the system logs either
Best regards,
AndreasHello Sam!
Thanks for your answer! I would like to use something more of a pop thing, since i want to make sure the user sees it. The MessageManager does not work as good as it used to anymore, since it puts all messages in the bottom of the page. This page needs to be scrolled in order to see the error message..
Anyone got an idea of a workaround? I'm reading a propsfile, and in case I'm not able to read it I want to display this to the user.
B.R
Andreas
Maybe you are looking for
-
Subtitle support needed for apple tv
i am hearing impaired and was frustrated to download a movie and found no support for subtitles. Please apple fix this problem.
-
MDX Query: Equivalent of SQL's "IN" clause
Hi, In SQL, we have an option of viewing data of multiple members by specifying IN as follows: SELECT column1 from TABLE WHERE column2 in ('value1','value2'); Is there any equivalent of that in MDX? Let's say my outline is like this: --Products (Stan
-
What setting do I use to Network Mac 10.4.6 to PC Windows XP with Router
I am trying to hook up a Mac G4 with OS 10.4.6 and a PC with Windows XP through a Linksys Network Everywhere DSL Router. The router would see the PC but not the Mac. Could not connect to the internet with the PC through the router. Both computers con
-
Cap 4 quiz published in cap 5 not working
Our site runs quizzes made from cap 4 fine but when I make a change to a cap 4 quiz using cap 5 and republish, the quiz will no longer work. Where do I start looking for a fix?
-
Does FCP support the new iFrame format?
I know the update was just released for iMovie, and I was thinking of nabbing one of these new Sanyo cams. Sometimes I use FCP for editing though.