Package com.wowza.wms.transport.media
Class MediaTransportConfigurationAmazonS3
- Object
- 
- com.wowza.wms.transport.media.MediaTransportConfigurationBase
- 
- com.wowza.wms.transport.media.MediaTransportConfigurationAmazonS3
 
 
- 
- All Implemented Interfaces:
- IMediaTransportProviderConfiguration
 
 public class MediaTransportConfigurationAmazonS3 extends com.wowza.wms.transport.media.MediaTransportConfigurationBaseThis is a base configuration object for AmazonS3 for the MediaTransport System //Example use//Create a main transport object MediaTransport transport = new MediaTransport(); //Create an Amazon Transport Provider MediaTransportProviderAmazonS3 amazonTransport = new MediaTransportProviderAmazonS3(); //Create an Amazon Configuration Object MediaTransportConfigurationAmazonS3 amazonConfig = new MediaTransportConfigurationAmazonS3(); //Configure the Amazon object with the required parameters amazonConfig.setAttributeString(MediaTransportConfigurationAmazonS3.AMZ_CONFIG_BUCKET, "mybucketName"); amazonConfig.setAttributeString(MediaTransportConfigurationAmazonS3.AMZ_CONFIG_REGION, "bucketRegionName"); amazonConfig.setAttributeBoolean(MediaTransportConfigurationAmazonS3.AMZ_CONFIG_REGION_ENABLED, true); amazonConfig.setAttributeString(MediaTransportConfigurationAmazonS3.AMZ_CONFIG_ACCESSID, "myAmazonAccessKey"); amazonConfig.setAttributeString(MediaTransportConfigurationAmazonS3.AMZ_CONFIG_SECRETACCESSKEY, "myAmazonSecretKey"); //Add the configuration item to the provider amazonTransport.setTransportProviderConfiguration(amazonConfig); //Set the type of processing to occur, the default is ASYNC, set to SYNC //Async will use a thread pool to handle transports, SYNC will block and do them in the order //they are provided amazonTransport.setTransportProcessType(IMediaTransportProvider.TRANSPORT_PROVIDER_PROCESS_SYNC); //Initialize the provider amazonTransport.init(); //Add the transport provided to the media transport system transport.addTransportProvider(amazonTransport); //You can add multiple transport providers //To push a data block into the transport system the following example should be followed //Lets assume you have a byte array, say from loading a file into this array. byte[] fileBytes = getBytesFromFile(uploadFile); //Create a data object and set up various settings. MediaTransportDataObject transportDataObject = new MediaTransportDataObject(); transportDataObject.setPath("/"+filename); transportDataObject.setContentType("video/mp4"); transportDataObject.setData(fileBytes); transportDataObject.setCommand("PUT"); //Put the object into the transport system trasnport.addTransportDataObject(transportDataObject); // There are several listeners you can use to determine if the transport provider was added // and the return status of the object presented to the system.
- 
- 
Field Summary
 - 
Constructor SummaryConstructors Constructor Description MediaTransportConfigurationAmazonS3()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.HashMap<String,String>getTransportHeaderOutput(java.util.HashMap<String,byte[]> dynamictransportinformation, IMediaTransportObject transportObject)This should be called by the transport provider using this configuration item.voidinit()Initialise the provider configuration.- 
Methods inherited from class com.wowza.wms.transport.media.MediaTransportConfigurationBaseaddCustomHeader, getAttributeBoolean, getAttributeInt, getAttributeLong, getAttributeNames, getAttributeString, getAttributeString, getConfigurationName, getCustomHeaders, getDebug, getProperties, httpDateHeader, isReady, removeCustomHeader, setAttributeBoolean, setAttributeInt, setAttributeLong, setAttributeString, setConfigurationName, setDebug, setIsReady, setProperties
 
- 
 
- 
- 
- 
Field Detail- 
AMZ_OBJECT_HEADER_STORAGE_CLASSpublic static final String AMZ_OBJECT_HEADER_STORAGE_CLASS - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_ACCESS_LISTpublic static final String AMZ_OBJECT_HEADER_ACCESS_LIST - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_SECURITY_TOKENpublic static final String AMZ_OBJECT_HEADER_SECURITY_TOKEN - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_COPY_SOURCEpublic static final String AMZ_OBJECT_HEADER_COPY_SOURCE - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_META_DIRECTIVEpublic static final String AMZ_OBJECT_HEADER_META_DIRECTIVE - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_COPY_SOURCE_IF_MATCHpublic static final String AMZ_OBJECT_HEADER_COPY_SOURCE_IF_MATCH - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_COPY_SOURCE_IF_NONE_MATCHpublic static final String AMZ_OBJECT_HEADER_COPY_SOURCE_IF_NONE_MATCH - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_COPY_SOURCE_IF_UNMODIFIED_SINCEpublic static final String AMZ_OBJECT_HEADER_COPY_SOURCE_IF_UNMODIFIED_SINCE - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_COPY_SOURCE_IF_MODIFIED_SINCEpublic static final String AMZ_OBJECT_HEADER_COPY_SOURCE_IF_MODIFIED_SINCE - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_GRANT_READpublic static final String AMZ_OBJECT_HEADER_GRANT_READ - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_GRANT_WRITEpublic static final String AMZ_OBJECT_HEADER_GRANT_WRITE - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_GRANT_READ_ACPpublic static final String AMZ_OBJECT_HEADER_GRANT_READ_ACP - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_GRANT_WRITE_ACPpublic static final String AMZ_OBJECT_HEADER_GRANT_WRITE_ACP - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_GRANT_FULL_CONTROLpublic static final String AMZ_OBJECT_HEADER_GRANT_FULL_CONTROL - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_SERVER_ENCRYPTpublic static final String AMZ_OBJECT_HEADER_SERVER_ENCRYPT - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_SERVER_ENCRYPT_KEY_IDpublic static final String AMZ_OBJECT_HEADER_SERVER_ENCRYPT_KEY_ID - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_HEADER_SERVER_ENCRYPT_CONTEXTpublic static final String AMZ_OBJECT_HEADER_SERVER_ENCRYPT_CONTEXT - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_OPTION_BUCKETpublic static final String AMZ_OBJECT_OPTION_BUCKET - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_OPTION_REGIONpublic static final String AMZ_OBJECT_OPTION_REGION - See Also:
- Constant Field Values
 
 - 
AMZ_OBJECT_OPTION_REGION_ENABLEDpublic static final String AMZ_OBJECT_OPTION_REGION_ENABLED - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_FULLPATHpublic static final String AMZ_CONFIG_FULLPATH - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_BUCKETpublic static final String AMZ_CONFIG_BUCKET - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_REGIONpublic static final String AMZ_CONFIG_REGION - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_REGION_ENABLEDpublic static final String AMZ_CONFIG_REGION_ENABLED - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_SECRETACCESSKEYpublic static final String AMZ_CONFIG_SECRETACCESSKEY - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_ACCESSIDpublic static final String AMZ_CONFIG_ACCESSID - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_SERVICETYPEpublic static final String AMZ_CONFIG_SERVICETYPE - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_DOMAIN_SUFFIXpublic static final String AMZ_CONFIG_DOMAIN_SUFFIX - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_REQUEST_TYPEpublic static final String AMZ_CONFIG_REQUEST_TYPE - See Also:
- Constant Field Values
 
 - 
AMZ_CONFIG_PREFIXpublic static final String AMZ_CONFIG_PREFIX - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
initpublic void init() Description copied from interface:IMediaTransportProviderConfigurationInitialise the provider configuration. This should only be called when all appropriate attributes have been set.- Specified by:
- initin interface- IMediaTransportProviderConfiguration
- Overrides:
- initin class- com.wowza.wms.transport.media.MediaTransportConfigurationBase
 
 - 
getTransportHeaderOutputpublic java.util.HashMap<String,String> getTransportHeaderOutput(java.util.HashMap<String,byte[]> dynamictransportinformation, IMediaTransportObject transportObject)Description copied from interface:IMediaTransportProviderConfigurationThis should be called by the transport provider using this configuration item. You can pass in two objects, one is a HashMapand the other is a IMediaTransportObject The result should be a HashMap that the transport provider can then use to process the data block being transported. - Specified by:
- getTransportHeaderOutputin interface- IMediaTransportProviderConfiguration
- Overrides:
- getTransportHeaderOutputin class- com.wowza.wms.transport.media.MediaTransportConfigurationBase
- Returns:
- HashMap
 
 
- 
 
-