ByteArrayOutputStream outBuffer = new ByteArrayOutputStream();
MessageBody amfMessage = new MessageBody(targetURI, responseURI, new com.thoughtworks.xstream.XStream().fromXML(contenido));
requestMessage.addBody(amfMessage);
MessageSerializer amfMessageSerializer = new AmfMessageSerializer();
amfMessageSerializer.initialize(dsContext, outBuffer, trace);
amfMessageSerializer.writeMessage(requestMessage);
return outBuffer.toByteArray();
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();