Title: Deployment calls Describe the issue: When deploying kjar to business central on WLS by the following REST request fails with error 415(Unsupported Media Type) even though this is works against business central on EAP. curl -v -H 'Accept: application/json' -u bpmsAdmin -X POST 'ldapj:7001/business-central/rest/deployment/com.sample:bpmstest:1.1:process:ksession-process/deploy' Beacuse: - header must be Content-Type as it the defines what type of data is coming in with the request, Accept is for what client can accept as response - WLS seems to be more strict to the content which in general is options The following REST request works for WLS then. curl -v -H 'Content-Type: application/xml' -u bpmsAdmin --data "<deployment-descriptor/>" -X POST 'ldapj:7001/business-central/rest/deployment/com.sample:bpmstest:1.1:process:ksession-process/deploy' i.e. -H 'Content-Type: application/xml' is specified instead of Accept header --data "<deployment-descriptor/>" is specified as empty deployment structure which does not affect deployment structure in kjar (if any). Suggestions for improvement: Please clearly document about this requirement for REST API command of 'deploy' against WLS. Additional information:
Previous problem description is not good. Let me recap here. Describe the issue: Deploying kjar to business central on WLS by the following REST request fails with error 415 (Unsupported Media Type) even though same command works against business central on EAP. curl -v -H 'Accept: application/json' -u bpmsAdmin -X POST 'ldapj:7001/business-central/rest/deployment/com.sample:bpmstest:1.1:process:ksession-process/deploy' Error in WLS server log. ####<Nov 4, 2015 6:28:11 PM JST> <Error> <com.sun.jersey.spi.container.ContainerRequest> <xxx.redhat.com> <AdminServer> <[ACTIVE] ExecuteThread: '6' for queue: 'weblogic.kernel.Default (self-tuning)'> <bpmsAdmin> <> <> <1446629291589> <BEA-000000> <A message body reader for Java class org.kie.services.client.serialization.jaxb.impl.deploy.JaxbDeploymentDescriptor, and Java type class org.kie.services.client.serialization.jaxb.impl.deploy.JaxbDeploymentDescriptor, and MIME media type application/octet-stream was not found. The registered message body readers compatible with the MIME media type are: application/octet-stream -> com.sun.jersey.core.impl.provider.entity.ByteArrayProvider com.sun.jersey.core.impl.provider.entity.FileProvider com.sun.jersey.core.impl.provider.entity.InputStreamProvider com.sun.jersey.core.impl.provider.entity.DataSourceProvider com.sun.jersey.core.impl.provider.entity.RenderedImageProvider */* -> com.sun.jersey.core.impl.provider.entity.FormProvider com.sun.jersey.core.impl.provider.entity.MimeMultipartProvider com.sun.jersey.core.impl.provider.entity.StringProvider com.sun.jersey.core.impl.provider.entity.ByteArrayProvider com.sun.jersey.core.impl.provider.entity.FileProvider com.sun.jersey.core.impl.provider.entity.InputStreamProvider com.sun.jersey.core.impl.provider.entity.DataSourceProvider com.sun.jersey.core.impl.provider.entity.XMLJAXBElementProvider$General com.sun.jersey.core.impl.provider.entity.ReaderProvider com.sun.jersey.core.impl.provider.entity.DocumentProvider com.sun.jersey.core.impl.provider.entity.SourceProvider$StreamSourceReader com.sun.jersey.core.impl.provider.entity.SourceProvider$SAXSourceReader com.sun.jersey.core.impl.provider.entity.SourceProvider$DOMSourceReader com.sun.jersey.json.impl.provider.entity.JSONJAXBElementProvider$General com.sun.jersey.json.impl.provider.entity.JSONArrayProvider$General com.sun.jersey.json.impl.provider.entity.JSONObjectProvider$General com.sun.jersey.core.impl.provider.entity.XMLRootElementProvider$General com.sun.jersey.core.impl.provider.entity.XMLListElementProvider$General com.sun.jersey.core.impl.provider.entity.XMLRootObjectProvider$General com.sun.jersey.core.impl.provider.entity.EntityHolderReader com.sun.jersey.json.impl.provider.entity.JSONRootElementProvider$General com.sun.jersey.json.impl.provider.entity.JSONListElementProvider$General com.sun.jersey.json.impl.provider.entity.JacksonProviderProxy > This is because: - header must be Content-Type as it the defines what type of data is coming in with the request, Accept is for what client can accept as response. - WLS seems to be more strict to the content which in general is options Therefore, the following REST request works for both WLS and EAP. curl -v -H 'Content-Type: application/xml' -u bpmsAdmin --data "<deployment-descriptor/>" -X POST 'ldapj:7001/business-central/rest/deployment/com.sample:bpmstest:1.1:process:ksession-process/deploy' i.e. -H 'Content-Type: application/xml' ================================== =>This specified instead of Accept header(-H "Accept:...). Specifying both should not be an problem --data "<deployment-descriptor/>" ================================= =>This specified as empty deployment structure which does not affect deployment descriptor in kjar (if any). Suggestions for improvement: Please clearly document about this mandatory requirement of REST API command to 'deploy' kjar against WLS.