Quantcast
Channel: Adobe Community : Popular Discussions - Configuration and Getting Started
Viewing all 19542 articles
Browse latest View live

Getting started with Flex Builder, BlazeDS and Eclipse

$
0
0
Hi,
I'm a java developer looking at RIA for the first time. I'm really excited about BlazeDS and object remoting, but I can't get a working dev environment together. I'm assuming I should use Flex Builder for the client code, Eclipse Europa for the java webapp code, and deploy from both IDEs into the BlazeDS-equipped turnkey-Tomcat. I haven't found a tutorial explaining how to deploy a new webapp with this setup.
The turnkey-Tomcat sample app works fine. Trouble starts when I try to create  a new project in Flex Builder. I don't understand the 'debug' deployment that Flex Builder does. Why are there 2 versions of my app, the regular and the debug versions? What is exactly the project structure that I'm supposed to have in Tomcat?
The specific error I encounter when trying to deploy a new Flex project is this:

[MessagingError message='Destination 'productService' either does not exist or the destination has no channels defined (and the application does not define any default channels.)']

I do have a default channel configured for my environment in services-config:


           
       


And I do have a valid destination configured in remoting-config (I'm mostly interested in object remoting):

   
       
   

   
   
       
            test.ProductService
       

       
             
       

   


Here's the client code:


     
          
     

What am I doing wrong? Where can I get help on these specific topics? Also, does anyone have an Ant build file that would automate this sort of deployment?

Thanks!

services-config.xml, flash-config.xml, {context.root} and @ContextRoot()

$
0
0
Is there any doc (might be blog post, presentation or anything other) that describe how services-config.xml, flash-config.xml, mxml and web-tier compiler, {server.name}, {server.port}, {context.root} tokens, ServerConfig, RemoteObject and @ContextRoot() attributes relates to each other.

I am trying to figure out general definition flow for all of them but without any success at the movement. Flex docs lacks for this.

What in fact I want to do is to be able at Flex side for some of the URLRequest's specify url of the form:

http://{server.name}:{server.port}/{context.root}/upload_servlet

while my application are accessible by

http://{server.name}:{server.port}/{context.root}/flex/main.mxml

and are compiled by web-tier compiler.

Den

Setting Root folder when configuring J2EE Server

$
0
0
Hi,

I'd like to know if it's possible to point the root folder to a remote server, i.e I'd like my Flex app to point to remote location.

Thanks

BlazeDS install on AIX with Websphere

$
0
0

Hello,

 

 

I'm trying to figure out the best way to deploy a flex application that has several HTTPSERVICE calls into a production environment.  I obviously can't deploy the application with the URL's hardcoded.  It looks like I need to deploy BlazeDS to allow me to use a Destination object and get the URL's out of the complied application.

 

Question - It is not apparent to me if I can install Blaze on a AIX server that is running Websphere.  Will it work?

 

 

Thanks,

 

John

 

ps - if there is a easier way to accomplish my main objective - I'd love a push in the right direction. Thanks!

Deployment Isssue with Jboss and Blazeds

$
0
0

Hi,

 

I was trying to deploy Blazeds over Jboss 4.0.5.GA , for that i copied blazeds.war, ds-console.war and samples.war to Jboss deploy folder and restarted my jboss server.

when i'm trying to access samples application by using url http://localhost:8180/samples it is throwing

The requested resource (/ds-console/) is not available.    exception

 

at Jboss console i'm geeting below error with all the three wars i deployed earlier

 

status: Deployment FAILED reason: flex/messaging/MessageBrokerServlet (Unsupported major.minor version 49.0)
state: FAILED
watch: file:/C:/SabaWeb/JBoss_Tomcat/server/default/deploy/blazeds.war
altDD: null
lastDeployed: 1256250757909
lastModified: 1256250757878

 

I think that is because of i'm not using jdk 1.5 or jboss 5 insted i'm using jdk 1.4 because of some dependency for my existing application

 

Please let me know which version of blazeds should i use for the above configuration (jboss 4.05 with jdk 1.4) or blazeds is not supported for jdk 1.4 at all

the version i tried was blazeds-turnkey-3.2.0.3978

 

Thanks,

Anuj

msgBroker.routeMessageToService(msg,null) problem

$
0
0

hi

i'm developping a mobile app with flex which uses the data push service provided by BlazeDS. the problem is that i'm using java  to push data , everything works fine excepts the part when i send my message over the channel in then line

msgBroker.routeMessageToService(msg,null);

which causes a java null pointer exception as follows

java.lang.NullPointerException

 

please can anyone help me i'm desperate

BlazeDS deployment issue on Weblogic : Unable to create a parser to load messaging configuration

$
0
0

Hi there,

 

I am migrating a project from JBoss to Weblogic server.

The Java project uses BlazeDS in order to communicate with Flex front end.

It works fin on JBoss. However I have been struggling for a few days with the following exception.

 

flex.messaging.LocalizedException: Unable to create a parser to load messaging configuration.

 

The whole stack trace :

 

 

flex.messaging.LocalizedException: Unable to create a parser to load messaging configuration.

     at flex.messaging.config.FlexConfigurationManager.getMessagingConfiguration(FlexConfiguratio nManager.java:73)

     at flex.messaging.MessageBrokerServlet.init(MessageBrokerServlet.java:109)

     at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.jav a:299)

     at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.jav a:250)

     at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)

     at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)

     at weblogic.servlet.provider.WlsSubjectHandle.run(WlsSubjectHandle.java:57)

     at weblogic.servlet.internal.StubSecurityHelper.initServletInstance(StubSecurityHelper.java: 94)

     at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:82)

     at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java: 74)

     at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:60)

     at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:34)

     at weblogic.servlet.internal.ServletStubImpl.initStubLifecycleHelper(ServletStubImpl.java:62 4)

     at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:565)

     at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1 874)

     at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext .java:1848)

     at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java :1738)

     at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:2740)

     at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1704)

     at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:781)

     at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:213)

     at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:208)

     at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:35)

     at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:70)

     at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:212)

     at weblogic.application.internal.ExtensibleModuleWrapper.start(ExtensibleModuleWrapper.java: 111)

     at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java :124)

     at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:213)

     at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:208)

     at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:35)

     at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:70)

     at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:24)

     at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729)

     at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:35)

     at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258)

     at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java :48)

     at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java :165)

     at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.ja va:79)

     at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOpera tion.java:582)

     at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(Act ivateOperation.java:148)

     at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOpera tion.java:114)

     at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperati on.java:335)

     at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(Deployment Manager.java:844)

     at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(Deployment Manager.java:1253)

     at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.ja va:440)

     at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServic eDispatcher.java:163)

     at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommi tCallback(DeploymentReceiverCallbackDeliverer.java:195)

     at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$ 100(DeploymentReceiverCallbackDeliverer.java:13)

     at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(D eploymentReceiverCallbackDeliverer.java:68)

     at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.jav a:545)

     at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256)

     at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)

 

More details related to my configuration:

 

Java 1.7.0_21

blazeds-4.0.0.14931

weblogic 12c (12.1.1)

 

I would greatly appreciate if anyone could give me some little hints...

Thanks in advance!

Blazeds my-amf only executes http not https

$
0
0

Can I change the endpoint url for mx.messaging.channels.AMFChannel to point to https and not http


Tomcat Manager Portal in BlazeDS Turnkey Server

$
0
0

Hi all,

 

Im pretty new to blazeds, and liking what i have experienced thus far. Could anyone please tell me how to access the Tomcat Manager Portal within the BlazeDS Turnkey Server Installation.

 

Like in know it runs on port 8400 by default. So running it then opening http://localhost:8400 gets me the blazeds turnkey home page with links to the sample apps.

 

However I want to get to the Tomcat Portal to change file access permissions etc. And if i wanted to deploy apps from there etc.

 

Is this possible?

 

Please advise!

 

Kind Regards

 

Willem

Please specify a valid 'services.configuration.file'

$
0
0
Hi,

I have setup a maven project that builds the web application war. I used the (empty) blazeds application from the turnkey distribution as template. I am quite sure that my final war is built properly. Trying to run the webapp with the maven jetty plugin throws an exception.

MessageBrokerServlet failed to initialize due to runtime exception: flex.messaging.config.ConfigurationException: Please specify a valid 'services.configuration.file' in web.xml. You specified '/WEB-INF/flex/services-config.xml'. This is not a valid file system path reachable via the app server and is also not a path to a resource in your J2EE application archive.

The services-config.xml is located in the /WEB-INF/flex directory as well as the other xml files. The blazeds libs are also there. I also tried using the mvn jetty:run-exploded goal without success:

2008-09-23 13:41:09.602::WARN: failed MessageBrokerServlet
java.lang.NoClassDefFoundError: org/apache/commons/httpclient/UsernamePasswordCredentials

I would be grateful if anybody has a hint.

Cheers

Sebastian

Using BlazeDS with Netbeans and Glassfish

$
0
0
Hi,

is it possible to integrate the BlazeDS features into an exsiting JavaEE project? Now I have some projects deployed as EAR files with WAR modules and EJB modules. I would like to add connectivity to the Flex based frontend by adding BlazeDS. My aim is it to integrate the BlazeDS libraries into my existing project to deploy anything as a single deployment package to the server.

Is that possible or do I have to use the tomcat server.

Regards,
oliver

BlazeDS and scalability (i.e., concurrent users)

$
0
0
BlazeDS relies on the Servlet API...so, it means about a few hundred concurrent users, maximum -- which isn't very encouraging. This is because, in BlazeDS, one user equals one, or maybe two/three threads...

Has anyone else considered this and/or thought of a work around? I presume BlazeDS cannot load balance, etc, so having a proxy like Apache point to different servers isn't an option.

Anyone have any suggestions?

Thanks,
Cormac

Flex adding extra tag to SOAP Request (call a WebService that takes an XML, returns an XML)

$
0
0
Hi All,<br /><br />i I was able to call the SOAP Service.<br />But <br />b Flex is adding an extra tag at the start of the XML payload<br />(I mean, <br />b it is adding the parameter name twice). <br />Hence the service is unable to parse and returns a nil result.<br /><br />I tried with a sample service that takes an XML Document and returns the same XML Document. <br />b I recorded the request and the response thru BlaseDS.<br /><br />b Code:<br /><br />[BlazeDS][DEBUG] -- Header in request: accept : text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8<br />[BlazeDS][DEBUG] -- Header in request: accept-language : en-us,en;q=0.5<br />[BlazeDS][DEBUG] -- Header in request: accept-charset : ISO-8859-1,utf-8;q=0.7,*;q=0.7<br />[BlazeDS][DEBUG] -- Header in request: keep-alive : 300<br />[BlazeDS][DEBUG] -- Header in request: referer : http://localhost:8400/blazeds/testdrive-httpservice/CallSOAPService.swf<br />[BlazeDS][DEBUG] -- Header in request: content-type : application/xml<br /><br />b I passed this XML<br /><br />b Code:<br /><br /><contact><br />      <name>Bhaskar</name><br />      <phone>9999999999</phone><br /></contact><br /><br />b The POST Request was this:<br /><br />b Code:<br /><br />[BlazeDS][DEBUG] -- Begin POST request --<br />[BlazeDS][DEBUG] <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/X<br />MLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><SOAP-ENV:Body><tns0:returnInputXML PayloadElement xmlns:tns0="http<br />://oracle.apps.scm.tools.services.soap/types/"><br />b <tns0:payload><br /><tns0:payload>&lt;contact&gt;<br />&lt;name&gt;Bhaskar&lt;/name&gt;<br />&lt;phone&gt;9999999999&lt;/phone&gt;<br />&lt;/contact&gt;</tns0:payload><br />b </tns0:payload><br /></tns0:returnInputXMLPayloadElement></SOAP-ENV:Body></SOAP-ENV:Envelope><br />[BlazeDS][DEBUG] -- End POST request --<br /><br />b Code:<br /><br />[BlazeDS][DEBUG] -- Cookie in response: domain = 'localhost', path = '/ServicesTest-SoapXMLService-context-root', client name = 'F<br />LEX_-1204607085_405742582_JSESSIONID', endpoint name = 'JSESSIONID', value = '0ab05f6b22b8c336f6805218432d80f5bfb171afa693<br />[BlazeDS][DEBUG] -- Cookie in response: domain = 'localhost', path = '/', client name = 'JSESSIONID', endpoint name = 'JSESSIONID'<br />, value = '0EFA46CCC301BD440D5E4F9B0D6B85EF<br />[BlazeDS][DEBUG] -- Header in response: Date : Thu, 02 Apr 2009 05:19:12 GMT<br />[BlazeDS][DEBUG] -- Header in response: Server : Oracle Containers for J2EE<br />[BlazeDS][DEBUG] -- Header in response: Keep-Alive : timeout=15, max=100<br />[BlazeDS][DEBUG] -- Header in response: Content-Type : text/xml; charset=utf-8<br />[BlazeDS][DEBUG] -- Header in response: SOAPAction : ""<br />[BlazeDS][DEBUG] HTTP request: Flex Message (flex.messaging.messages.SOAPMessage)<br />    method = POST<br />    url = http://localhost:8888/ServicesTest-SoapXMLService-context-root/MyWebService1SoapHttpPort< br />    headers = {DSId=1737EE6A-360A-8A41-9C54-DB7625FA5406, DSEndpoint=my-http}<br />    clientId = 1737EFC2-730E-D8FF-CD78-F322D401948D<br />    destination = HTTPDestination3<br />    messageId = DD19BC61-78DF-F0D6-E517-654427421E23<br />    timestamp = 1238649546578<br />    timeToLive = 0<br />    body = <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSche<br />ma" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><SOAP-ENV:Body><tns0:returnInputXML PayloadElement xmlns:tns0="http://ora<br />cle.apps.scm.tools.services.soap/types/"><tns0:payload><tns0:payload>&lt;contact&gt;<br />&lt;name&gt;Bhaskar&lt;/name&gt;<br />&lt;phone&gt;9999999999&lt;/phone&gt;<br />&lt;/contact&gt;</tns0:payload></tns0:payload></tns0:returnInputXMLPayloadElement></SOA P-ENV:Body></SOAP-ENV:Envelope><br />    hdr(DSId) = 1737EE6A-360A-8A41-9C54-DB7625FA5406<br />    hdr(DSEndpoint) = my-http<br /><br />b The RESPONSE was this:<br /><br />b Code:<br /><br />  response:<br /><?xml version="1.0" encoding="UTF-8"?><br /><env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http:/<br />/www.w3.org/2001/XMLSchema-instance" xmlns:ns0="http://oracle.apps.scm.tools.services.soap/types/"><br /><env:Body

Access local EJB3 on Glassfish

$
0
0

I'm using Eclipse and have a combined Java/Flex project using WTP that uses BlazeDS and is deployed to a Glassfish server (v2ur2).  I was able to configure everything correctly to access simple routines with the remote access, but now I would like to access an EJB3 using the local interface.  I have another project in Eclipse that is an EJB Module and the Java/Flex project specifies that as a dependency. I can access an EJB from that project using a remote interface, but am having trouble figuring out how to access one with a local interface.

 

I saw another thread on the forum that referenced the EJB3 Factory available through the Adobe exchange so I downloaded that and added it to my project.  I defined the factory in services-config.xml and added a new destination in remoting-config.xml, but when I try to access the EJB, it gives me an "error accessing local resource..."

 

Is there something else I need to do?  Any pointers as to what might be going wrong?  I'm assuming that specifying the Java EE Module dependency for the EJB module should pull it in and make the local interface accessible.  Is that right?  If not, what else do I need to do?  I'm fairly new to all of this and still don't completely understand how everything in the Java/Flex project is being deployed.

 

Any help would be greatly appreciated!  Thanks!

 

Renee

blazeds MessageBroker servlet starts twice on JBoss

$
0
0

Hello,

 

We have a flex/java app, that has been running fine on JBoss 4.0.4GA with Flex 3.0 and blazeds 3.0 and we are trying to move it to JBoss 5.1.0.GA with Flex 3.3. and BlazeDS 3.0.  For some reason, the BlazeDS on this application is started twice, which throws an error for MessageServlet.

 

The Log with services-config set to Debug:

 

...

11:17:53,511 INFO  [STDOUT] [Flex] 11:17:53.511 [INFO] [Configuration] BlazeDS - Community Edition: 3.2.0.3978
11:17:53,511 INFO  [STDOUT] [Flex] 11:17:53.511 [INFO] [Configuration] BlazeDS - Community Edition: 3.2.0.3978
11:17:53,512 INFO  [STDOUT] [Flex] 11:17:53.512 [INFO] [Endpoint.HTTP] No port specified in channel URL:  https://jboss.******.com/*****/messagebroker/httpsecure
11:17:53,512 INFO  [STDOUT] [Flex] 11:17:53.512 [INFO] [Endpoint.HTTP] No port specified in channel URL:  https://jboss.*****.com/*****/messagebroker/httpsecure
11:17:53,512 INFO  [STDOUT] [Flex] 11:17:53.512 [INFO] [Configuration] Endpoint my-secure-http created with security: None
at URL: https://jboss.*****.com/*****/messagebroker/httpsecure
11:17:53,512 INFO  [STDOUT] [Flex] 11:17:53.512 [INFO] [Configuration] Endpoint my-secure-http created with security: None
at URL: https://jboss.******.com/******/messagebroker/httpsecure
11:17:53,512 INFO  [STDOUT] [Flex] 11:17:53.512 [INFO] [Endpoint.AMF] No port specified in channel URL:  https://jboss.*****.com/*****/messagebroker/amfsecure
11:17:53,512 INFO  [STDOUT] [Flex] 11:17:53.512 [INFO] [Endpoint.AMF] No port specified in channel URL:  https://jboss.******.com/******/messagebroker/amfsecure
11:17:53,513 INFO  [STDOUT] [Flex] 11:17:53.513 [INFO] [Configuration] Endpoint my-secure-amf created with security: None
at URL: https://jboss.*****.com/******/messagebroker/amfsecure
11:17:53,513 INFO  [STDOUT] [Flex] 11:17:53.513 [INFO] [Configuration] Endpoint my-secure-amf created with security: None
at URL: https://jboss.*****.com/******/messagebroker/amfsecure
11:17:53,526 INFO  [STDOUT] [Flex] 11:17:53.526 [DEBUG] [Configuration] MessageBroker id: __default__ classLoader is: the MessageBroker's class loader (classLoader hashCode: 1592538363 (parent null)
11:17:53,527 INFO  [STDOUT] [Flex] 11:17:53.527 [DEBUG] [Configuration] MessageBroker id: __default__ classLoader is: the MessageBroker's class loader (classLoader hashCode: 1592538363 (parent null)
11:17:53,533 INFO  [STDOUT] [Flex] 11:17:53.533 [ERROR] [Configuration] MessageBroker failed to start: flex.messaging.config.ConfigurationException: MessageBroker already defined from MessageBrokerServlet with init parameter messageBrokerId = '__default__'
        at flex.messaging.MessageBroker.registerMessageBroker(MessageBroker.java:1908)
        at flex.messaging.MessageBroker.start(MessageBroker.java:347)
        at flex.messaging.MessageBrokerServlet.init(MessageBrokerServlet.java:140)
        at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1048)

...

 

Here's the web.xml related to Blazeds:

 

    <!-- MessageBroker Servlet -->
    <servlet>
        <servlet-name>pmportalMessageBrokerServlet</servlet-name>
        <display-name>MessageBrokerServlet</display-name>
        <servlet-class>flex.messaging.MessageBrokerServlet</servlet-class>
        <init-param>
            <param-name>services.configuration.file</param-name>
            <param-value>/WEB-INF/flex/services-config.xml</param-value>
       </init-param>
        <load-on-startup>1</load-on-startup>
    </servlet>

 

    <servlet-mapping>
        <servlet-name>pmportalMessageBrokerServlet</servlet-name>
        <url-pattern>/messagebroker/*</url-pattern>
    </servlet-mapping>

 

If I comment out the MessageBrokerServlet from the web.xml - the server starts up without error.

 

I loaded the Blazeds.war in the same server, and it started with no problem. - no duplicate starts.

 

So, why, why, why is it doing this?  It is not starting any of the other servlets twice (i.e. quartz servlet starts only once).  MessageBroker seems to be doing something really funky.... what am I missing here?  Where am I going wrong?

 

Any and all comments are appreciated.

 

Thanks in advance,

--Andy


Integrating BlazeDS with a Simple Java Server

$
0
0

I have written Java server software that communicates with various browsers. Ajax is not involved. Tomcat is not involved. .NET is not involved. Apache is not involved. In fact, I have never used any of that software and have no idea what it is. I simply wrote standalone Java server software, and it works just fine as a server. My server software communicates with a browser using HTML and JavaScript. Now, a new programmer has been added to the project. He wants to use Flex on the client side by integrating Flex into the browser. I know that I will have to add something to my Java server software to allow the Flex to communicate with my Java server software. My compiled Java server software is completely contained in a file called "server.jar". To start the server, I simply execute "java server.jar" in a command shell.

 

The problem for me is that all the BlazeDS installation and configuration documents assume that one is using Tomcat or ColdFusion or some other software. I have no knowledge of Tomcat or ColdFusion, so the installation and configuration documents are useless to me. I have my own director/folder structure, so my application does not fit the installation and configuration documentation that is generally available for BlazeDS.

 

Here is what I have done to add BlazeDS to my server software.

 

I have added (by including their names in a manifest file) the five jar files flex-messaging-core.jar, flex-messaging-common.jar, flex-messaging-opt.jar, flex-messaging-proxy.jar, and flex-messaging-remoting.jar to the file server.jar. Thus when server.jar starts up by the command "java server.jar", the compiled classes in the five "flex-messaging-xxxx.jar" files will also be loaded, along with server.jar

 

My directory/folder structure is

 

Inetpub

  wwwroot

    magnolia

       server.jar

       flex-messaging-core.jar

       flex-messaging-common.jar

       flex-messaging-opt.jar

       flex-messaging-proxy.jar

       flex-messaging-remoting.jar

 

Is this all I need to do? Do I need a configuration file or files? I am looking to use only the bare minimum that will allow client-side Flex software to make remote procedure calls to my server software.

 

Any help I can get would be appreciated. Please keep it simple. I know this must be simple, but I don't have the recipe.

Class Not Found Exception when saving in Backend?

$
0
0

Hello all,

 

we are using JBOSS, Hibernate, Flex 3 and BlazeDS.

I have added a class ProjectDocument and it is configured identically to an existing class PartDocument.

I can successfully load the class in front  end, but the save of the class leads to the following exception.

 

The jar is successfully compiled, and includes both PartDocument.class and ProjectDocument.class.

 

Does anyone know why BlazeDS cannot find the class?

 

regards and thanks

David

 

15:28:49,062 INFO  [STDOUT] [BlazeDS]Cannot create class of type 'ProjectDocumen
t'.
flex.messaging.MessageException: Cannot create class of type 'ProjectDocument'.
Type 'ProjectDocument' not found.
        at flex.messaging.util.ClassUtil.createClass(ClassUtil.java:66)
        at flex.messaging.io.AbstractProxy.getClassFromClassName(AbstractProxy.j
ava:103)
        at flex.messaging.io.amf.Amf3Input.readScriptObject(Amf3Input.java:430)
        at flex.messaging.io.amf.Amf3Input.readObjectValue(Amf3Input.java:153)
        at flex.messaging.io.amf.Amf3Input.readObject(Amf3Input.java:132)
        at flex.messaging.io.amf.Amf3Input.readArray(Amf3Input.java:371)
        at flex.messaging.io.amf.Amf3Input.readObjectValue(Amf3Input.java:157)
        at flex.messaging.io.amf.Amf3Input.readObject(Amf3Input.java:132)
        at flex.messaging.io.amf.Amf3Input.readScriptObject(Amf3Input.java:473)
        at flex.messaging.io.amf.Amf3Input.readObjectValue(Amf3Input.java:153)
        at flex.messaging.io.amf.Amf3Input.readObject(Amf3Input.java:132)
        at flex.messaging.io.amf.Amf0Input.readObjectValue(Amf0Input.java:135)
        at flex.messaging.io.amf.Amf0Input.readArrayValue(Amf0Input.java:326)
        at flex.messaging.io.amf.Amf0Input.readObjectValue(Amf0Input.java:139)
        at flex.messaging.io.amf.Amf0Input.readObject(Amf0Input.java:95)
        at flex.messaging.io.amf.AmfMessageDeserializer.readObject(AmfMessageDes
erializer.java:226)
        at flex.messaging.io.amf.AmfMessageDeserializer.readBody(AmfMessageDeser
ializer.java:205)
        at flex.messaging.io.amf.AmfMessageDeserializer.readMessage(AmfMessageDe
serializer.java:125)
        at flex.messaging.endpoints.amf.SerializationFilter.invoke(Serialization
Filter.java:114)
        at flex.messaging.endpoints.BaseHTTPEndpoint.service(BaseHTTPEndpoint.ja
va:278)
        at flex.messaging.MessageBrokerServlet.service(MessageBrokerServlet.java
:322)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

BlazeDS and Flex Client Deployed on Different Servers

$
0
0

Hi, I setup a BlazeDS AMF endpoint on a different server from the server where my Flex app is deployed. I get the following error from my Flex app when trying to use this endpoint:

 

   faultCode: Client.Error.MessageSend
   faultDetail: Channel.Security.Error error Error #2048 url: 'http://cafrfd1y5css50.itsdo.abc.com:7000/sfaflexservice/amf'
   faultString: Send failed
   rootCause:
       [ChannelFaultEvent
        faultCode="Channel.Security.Error"
        faultString="error"
        faultDetail="Error #2048 url: 'http://cafrfd1y5css50.itsdo.abc.com:7000/sfaflexservice/amf'"
        channelId="my-amf"
        type="channelFault"
        bubbles=false
        cancelable=false
        eventPhase=2]


Btw, this setup works fine when my Flex app runs on AIR or as a Flex app (in a browser) from Flex Builder.


This looks like a crossdomain policy issue, so I setup a crossdomain.xml file on the BlazeDS server. When I point my browser to http://cafrfd1y5css50.itsdo.abc.com:7000/crossdomain.xml, I see the following:

 

    <?xml version="1.0" encoding="UTF-8" ?>
    <cross-domain-policy>
       <allow-access-from domain="*.abc.com" />
    </cross-domain-policy>


Looks good, but I get the same error...

 

So I monitored the interaction with Fiddler to see if the crossdomain.xml file is loaded. It is. When the service is activated, I see the following GET command in Fiddler:

 

     GET /crossdomain.xml HTTP/1.1
     Host: cafrfd1y5css50.itsdo.abc.com:7000

 

And the response contains the contents of the crossdomain.xml file, so I don't know what's going on.


My configuration is:

 

-- Browser: IE7 or FireFox v3.5 with Flash Player v10.
-- Flex app uses the 3.4 SDK and is deployed on a Tomcat v6 server.
-- BlazeDS server is WebLogic v9.

-- Endpoint definition from services-config.xml on the BlazeDS server is:

 

   <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"/>
   </channel-definition>


-- Endpoint in the Flex app is defined as follows:

 

   <channel alias="FlexBean">
      <channel_def>my-amf</channel_def>
      <endpoint>http://cafrfd1y5css50.itsdo.abc.com:7000/sfaflexservice/amf</endpoint>
      <destination>FlexService</destination>
   </channel>

 


Any ideas would be much appreciated...

thanks,
matt

What db does BlazeDS support?

$
0
0

Dear All,

 

i am new to flash builder & BlazeDS.

Does BlazeDS support Oracle DB, MS SQL, & MySQL?

 

thank you

shawn lim

java.sql.SQLException: The url cannot be null" faultCode="Server.Processing

$
0
0

Hi Everyone i am getting the following exception while envoking a java method from the flex using blazeds. Any help would be highly appreciated.

 

Fault faultString="com.Employee.Employeedetails.connection.DAOException : java.sql.SQLException: The url cannot be null" faultCode="Server.Processing" faultDetail="null"]

Viewing all 19542 articles
Browse latest View live