(테스트 환경)
tomcat 6.0.32
Spring 3.0.6 다운로드 : http://www.springsource.org/download
Spring BlazeDS Integration 1.5.0 다운로드 : http://www.springsource.org/download
BlazeDS 다운로드 : https://www.adobe.com/cfusion/entitlement/index.cfm?e=lc_blazeds
머드초보님의 글이 잘 되어 있어서 링크를 추가합니다.
따라하시면 쉽게 될 듯합니다. http://mudchobo.tistory.com/371
주의0.
eclipse helios 이상 버젼에서는 프로젝트 생성이 안됩니다.
반드시 그 이하 버전(galileo가 가장 잘 맞는 듯)을 사용하시기 바랍니다. (중요!!!!)
주의1.
Spring version이 변경되어서 바꿔줘야 할 것이 있습니다.
Spring class의 package가 변경되었습니다.
<applicationContext.xml>
...
<bean id="mySpringManagedMessageBroker"
class="org.springframework.flex.core.MessageBrokerFactoryBean" />
<!-- Maps request paths at /messagebroker to the BlazeDS MessageBroker -->
<bean class="org.springframework.web.servlet.handler.SimpleUrlHandlerMapping"
p:mappings="/*=mySpringManagedMessageBroker" />
<!-- Dispatches requests mapped to a MessageBroker -->
<bean class="org.springframework.flex.servlet.MessageBrokerHandlerAdapter"/>
<bean id="helloService" class="service.HelloService" />
<bean id="hello"
class="org.springframework.flex.remoting.RemotingDestinationExporter"
p:messageBroker-ref="mySpringManagedMessageBroker"
p:service-ref="helloService"/>
...
주의2.
Context root가 WebContent로 되어 있는 부분을 프로젝트 이름으로 고쳐줘야 합니다.
안그러면 http://localhost:8080/WebContent/messagebroker/amf
이런 메세지를 자주 보게 됩니다.
주의3.
잘되던 설정 파일(xml)이 cvc-complex-type.2.3 어쩌고 error가 발생하는 경우가 있습니다.
그럴 경우는 파일을 notepad나 다른 곳에 복사한 후에 저장하고(혹시 모르는 형식 제거)
원래 설정 파일을 깨끗이 지우고 다시 복사하시면 됩니다.
눈에 보이지 않는 이상한 문자가 들어가서 발생하는 경우가 많습니다.
오랫만에 플렉스를 하려니, 기억이 하나도... 생각이 안난다는...