Configurational settings for calling HTTP from ABAP
Hi,
I need to call HTTP from ABAP.
Other than ABAP code, what configurational settings (and functional settings, if any) I need to do for this scenario..
Please help...
Thanks,
Shivaa...
Moderator message - Duplicate post locked
Edited by: Rob Burbank on May 7, 2009 3:44 PM
Hi All,
I have a problem to pass a file.txt in a parameter of a web service.
Iam using CL_HTTP_CLIENT and I am passing the parameters (user, password and file):
clear wa_form.
wa_form-name = 'user'.
wa_form-value = '33333333333'.
append wa_form to it_form.
clear wa_form.
wa_form-name = 'password'.
wa_form-value = '11111111'.
append wa_form to it_form.
clear wa_form.
wa_form-name = 'file'.
wa_form-value = data. ---> "data" is a type string with the data of the file.txt.
append wa_form to it_form.
r_client->request->set_form_fields( fields = it_form ).
I have not problem with the user and password parameters.
Thank.
Similar Messages
-
Any program for calling bapi from ABAP step by step
any program for calling bapi from ABAP step by step
points will be rewarded,
thank you,
Jagrut BharatKumar ShuklaHi Jagrut,
BAPI stands for Business API(Application Program Interface).
A BAPI is remotely enabled function module ie it can be invoked from remote programs like standalone JAVA programs, web interface etc..
You can make your function module remotely enabled in attributes of Function module but
A BAPI are standard SAP function modules provided by SAP for remote access. Also they are part of Businees Objest Repository(BOR).
BAPI are RFC enabled function modules. the difference between RFc and BAPI are business objects. You create business objects and those are then registered in your BOR (Business Object Repository) which can be accessed outside the SAP system by using some other applications (Non-SAP) such as VB or JAVA. in this case u only specify the business object and its method from external system in BAPI there is no direct system call. while RFC are direct system call Some BAPIs provide basic functions and can be used for most SAP business object types. These BAPIs should be implemented the same for all business object types. Standardized BAPIs are easier to use and prevent users having to deal with a number of different BAPIs. Whenever possible, a standardized BAPI must be used in preference to an individual BAPI.
The following standardized BAPIs are provided:
Reading instances of SAP business objects
GetList ( ) With the BAPI GetList you can select a range of object key values, for example, company codes and material numbers.
The BAPI GetList() is a class method.
GetDetail() With the BAPI GetDetail() the details of an instance of a business object type are retrieved and returned to the calling program. The instance is identified via its key. The BAPI GetDetail() is an instance method. BAPIs that can create, change or delete instances of a business object type
The following BAPIs of the same object type have to be programmed so that they can be called several times within one transaction. For example, if, after sales order 1 has been created, a second sales order 2 is created in the same transaction, the second BAPI call must not affect the consistency of the sales order 2. After completing the transaction with a COMMIT WORK, both the orders are saved consistently in the database.
Create( ) and CreateFromData! ( )
The BAPIs Create() and CreateFromData() create an instance of an SAP business object type, for example, a purchase order. These BAPIs are class methods.
Change( )
The BAPI Change() changes an existing instance of an SAP business object type, for example, a purchase order. The BAPI Change () is an instance method.
Delete( ) and Undelete( ) The BAPI Delete() deletes an instance of an SAP business object type from the database or sets a deletion flag.
The BAPI Undelete() removes a deletion flag. These BAPIs are instance methods.
Cancel ( ) Unlike the BAPI Delete(), the BAPI Cancel() cancels an instance of a business object type. The instance to be cancelled remains in the database and an additional instance is created and this is the one that is actually canceled. The Cancel() BAPI is an instance method.
Add<subobject> ( ) and Remove<subobject> ( ) The BAPI Add<subobject> adds a subobject to an existing object inst! ance and the BAPI and Remove<subobject> removes a subobject from an object instance. These BAPIs are instance methods.
ex BAPI:
API_SALESORDER_CREATEFROMDAT1
BAPI_SALESORDER_CREATEFROMDAT2
You can get good help form the following links,
BAPI-step by step
http://www.sapgenie.com/abap/bapi/example.htm
list of all bapis
http://www.planetsap.com/LIST_ALL_BAPIs.htm
for BAPI's
http://www.sappoint.com/abap/bapiintro.pdf
http://www.sappoint.com/abap/bapiprg.pdf
http://www.sappoint.com/abap/bapiactx.pdf
http://www.sappoint.com/abap/bapilst.pdf
http://www.sappoint.com/abap/bapiexer.pdf
http://service.sap.com/ale
http://service.sap.com/bapi
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCMIDAPII/CABFAAPIINTRO.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/CABFABAPIREF/CABFABAPIPG.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCFESDE8/BCFESDE8.pdf
http://www.planetsap.com/Bapi_main_page.htm
http://www.topxml.com/sap/sap_idoc_xml.asp
http://www.sapdevelopment.co.uk/
http://www.sapdevelopment.co.uk/java/jco/bapi_jco.pdf
Also refer to the following links..
www.sappoint.com/abap/bapiintro.pdf
www.sap-img.com/bapi.htm
www.sap-img.com/abap/bapi-conventions.htm
www.planetsap.com/Bapi_main_page.htm
www.sapgenie.com/abap/bapi/index.htm
Checkout !!
http://searchsap.techtarget.com/originalContent/0,289142,sid21_gci948835,00.html
http://techrepublic.com.com/5100-6329-1051160.html#
http://www.sap-img.com/bapi.htm
http://www.sap-img.com/abap/bapi-conventions.htm
http://www.sappoint.com/abap/bapiintro.pdf
http://sap-img.com/bapi.htm
<b>EG::</b>
<b>Here is the step by step procedure for creating BAPIs.</b>
There are 5 different steps in BAPI.
- Create BAPI Structure
- Create BAPI Function Module or API Method.
- Create BAPI object
- Release BAPI Function Module.
- Release BAPI object.
Step1. Creating BAPI Structure:
- Go to <SE11>.
- Select Data Type & Enter a name.
- Click on Create.
- Note: Always BAPI should be in a development class with request number (Not Local Object).
- Select Structure & hit ENTER.
- Enter the fields from your database. Make sure that the first field is the Primary Key Field.
- Then SAVE & ACTIVATE.
Step 2. Creating BAPI module:
- Enter TR.CODE <SE37>.
- Before entering any thing, from the present screen that you are in, select the menu
Goto -> Function Groups -> Create Group.
Enter a name (Note: This name Must start with ZBAPI)
Let this screen be as it is and open another window and there, enter TR.CODE <SE80).
Click on the Third ICON that says Inactive Objects.
Select the group that you just created and click on Activate.
Notice that the group you created will disappear from the list of inactive objects.
- Go back to ><SE37> screen and enter a name and hit <ENTER>. Then enter the group name that you just created and activated.
NOTE: When you release a function module the respective group will be attached to that particular application. It cannot be used for any other application. NEVER include an already existing group that is attached to another module.
Now click on the first Tab that says [ATTRIBUTES] and select the radio button that says remote-enabled module since we will be accessing this from any external system.
Then click on the second tab that says [IMPORT].
Enter a PARAMETER NAME, TYPE and the structure you created in the first step. Also select the check box Pa. All remotely enabled functional modules MUST be Pa enabled, where Pa means Passed by Value and if you dont select Pa, then that means it will be passed by reference..
Then click on tab that says [EXPORT].
Enter the following as is in the first three fields
RETURN TYPE BAPIRETURN (These 3 field values are always same)
Here also select Pa meaning Pass by value.
Note: BAPIRETURN contains structure with message fields.
Then SAVE and ACTIVATE.
Step 3. Creating BAPI object:
- Enter Tr.Code <SWO1> (Note. It is letter O and not Zero).
- Enter a name and then click on create. Enter details.
NOTE: Make sure that that Object Type and Program name are SAME.
- Enter Application M, if you are using standard table Mara. If you are using your own database then select Z at the bottom.
- Then hit <ENTER>.
- Now we have to add Methods. High light METHODS and then select the following from the menu:
Goto Utilities -> API Methods -> Add Methods.
- Enter function Module name and hit <ENTER>.
- Select the second FORWARD ARROW button (>)to go to next step.
- Check if every thing looks ok and again click on FORWARD ARROW button (>).
- Then select YES and click on <SAVE>.
- Now on a different screen goto TR.CODE <SE37>. Enter Function Module name and select from the top menu Function Module -> Release -> Release.
- Goback to TR.CODE <SWO1>.
Here select the menu combination shown below in the same order.
- Edit -> Change Release Status -> Object Type Component -> To Implemented.
- Edit -> Change Release Status -> Object Type Component -> To Released.
- Edit -> Change Release Status -> Object Type -> To Implemented.
- Edit -> Change Release Status -> Object Type -> To Released.
- Then click on <SAVE>.
- Then click on Generate Button (4th button from left hand side looks like spinning wheel).
- Then Click on the button that says PROGRAM to see the source code.
To check if this is present in work flow goto TR.CODE <BAPI>.
Here it shows business object repository.
- First click on the middle button and then select ALL and hit ENTER.
- Goto tab [ALPHABETICAL] and look for the object that you created. This shows that the BAPI object has been created successfully
<b>Reward pts if found usefull :)</b>
regards
Sathish -
Hi ,
I want to call HTTP link from ABAP. On initial research , I found that I can do the task in 2 ways:---
1. by using class cl_http_client,
2. by using program RSHTTP20 .
Is it the correct information I got.
Out of the 2 methods, which method can I prefer and what are d pros and cons of the above methods?
Please help.
Thanks,
Shivaa...Hi All,
I have a problem to pass a file.txt in a parameter of a web service.
Iam using CL_HTTP_CLIENT and I am passing the parameters (user, password and file):
clear wa_form.
wa_form-name = 'user'.
wa_form-value = '33333333333'.
append wa_form to it_form.
clear wa_form.
wa_form-name = 'password'.
wa_form-value = '11111111'.
append wa_form to it_form.
clear wa_form.
wa_form-name = 'file'.
wa_form-value = data. ---> "data" is a type string with the data of the file.txt.
append wa_form to it_form.
r_client->request->set_form_fields( fields = it_form ).
I have not problem with the user and password parameters.
Thank. -
Calling webservices from ABAP via https/ssl with p12 certificates.
Hi all,
I have a problem with calling an external webservice via HTTPS.
I configured my system as indicate in the blog /people/jens.gleichmann/blog/2008/10/31/calling-webservices-from-abap-via-httpsssl-with-pfx-certificates but when I check the RFC connection the result is: ICM_HTTP_SSL_ERROR.
I check the ICM monitor and this is the result:
[Thr 11] Thu May 26 16:02:57 2011
[Thr 11] *** ERROR during SecudeSSL_SessionStart() from SSL_connect()==SSL_ERROR_SSL
[Thr 11] session uses PSE file "/usr/sap/SV5/DVEBMGS10/sec/SAPSSLHTTPS1.pse"
[Thr 11] SecudeSSL_SessionStart: SSL_connect() failed
secude_error 536875072 (0x20001040) = "received a fatal SSLv3 handshake failure alert message from the peer"
[Thr 11] >> Begin of Secude-SSL Errorstack >>
[Thr 11] WARNING in ssl3_read_bytes: (536875072/0x20001040) received a fatal SSLv3 handshake failure alert message from the peer
WARNING in ssl3_output_cert_chain: (12354/0x3042) No hierarchy certificate in FCPath
WARNING in reduce_FCPath_by_Issuer: (12354/0x3042) No hierarchy certificate in FCPath
[Thr 11] << End of Secude-SSL Errorstack
[Thr 11] SSL_get_state() returned 0x000021d0 "SSLv3 read finished A"
[Thr 11] Server's List of trusted CA DNames (from cert-request message):
[Thr 11] #1 " certificate 1
[Thr 11] #2 " certificate 2
[Thr 11] SSL NI-sock: local=ip peer=ip2
[Thr 11] <<- ERROR: SapSSLSessionStart(sssl_hdl=6000000000652010)==SSSLERR_SSL_CONNECT
[Thr 11] *** ERROR => IcmConnInitClientSSL: SapSSLSessionStart failed (-57): SSSLERR_SSL_CONNECT [icxxconn_mt.c 2012]
SAP_ABA 700 0012 SAPKA70012 Componenti validi per tutte le applicazioni
SAP_BASIS 700 0012 SAPKB70012 Componenti di base SAP
PI_BASIS 2005_1_700 0012 SAPKIPYJ7C PI_BASIS 2005_1_700
ST-PI 2008_1_700 0001 SAPKITLRD1 SAP Solution Tools Plug-In
SAP_BW 700 0013 SAPKW70013 SAP NetWeaver BI 7.0
SAP_AP 700 0010 SAPKNA7010 Piatt. d'applicazione SAP
CCM 200_700 0010 SAPK-27010INCCM CCM 200_700 : Add-On Supplement
SRM_PLUS 550 0010 SAPKIBK010 SRM_PLUS per mySAP SRM
SRM_SERVER 550 0010 SAPKIBKT10 SRM_SERVER
BI_CONT 703 0001 SAPKIBIIP1 Contenuto Business Intelligence
ST-A/PI 01L_BCO700 0000 - Servicetools for other App./Netweaver 04
What do you think about it?
Best regards,
Norberto.Don´t forget to set your proxy settings! Be sure that the application server could establish a connection to the external server.
From the BLog.
Thr 11 WARNING in ssl3_read_bytes: (536875072/0x20001040) received a fatal SSLv3 handshake failure alert message from the peer
From the Error.
Have you looked into the above details?
Thanks
SM -
Hi All,
We are trying to access the Create Deployment method stated below
http://msdn.microsoft.com/en-us/library/windowsazure/ee460813
We have uploaded the Package in the blob and browsing the configuration file. We have checked trying to upload manually the package and config file in Azure portal and its working
fine.
Below is the code we have written for creating deployment where "AzureEcoystemCloudService" is our cloud service name where we want to deploy our package. I have also highlighted the XML creation
part.
byte[] bytes =
new byte[fupldConfig.PostedFile.ContentLength + 1];
fupldConfig.PostedFile.InputStream.Read(bytes, 0, bytes.Length);
string a = Encoding.UTF8.GetString(bytes, 0, bytes.Length);
string base64ConfigurationFile = a.ToBase64();
X509Certificate2 certificate =
CertificateUtility.GetStoreCertificate(ConfigurationManager.AppSettings["thumbprint"].ToString());
HostedService.CreateNewDeployment(certificate,
ConfigurationManager.AppSettings["SubscriptionId"].ToString(),
"2012-03-01", "AzureEcoystemCloudService", Infosys.AzureEcosystem.Entities.Enums.DeploymentSlot.staging,
"AzureEcoystemDeployment",
"http://shubhendustorage.blob.core.windows.net/shubhendustorage/Infosys.AzureEcoystem.Web.cspkg",
"AzureEcoystemDeployment", base64ConfigurationFile,
true, false);
<summary>
/// </summary>
/// <param name="certificate"></param>
/// <param name="subscriptionId"></param>
/// <param name="version"></param>
/// <param name="serviceName"></param>
/// <param name="deploymentSlot"></param>
/// <param name="name"></param>
/// <param name="packageUrl"></param>
/// <param name="label"></param>
/// <param name="base64Configuration"></param>
/// <param name="startDeployment"></param>
/// <param name="treatWarningsAsError"></param>
public static
void CreateNewDeployment(X509Certificate2 certificate,
string subscriptionId,
string version, string serviceName, Infosys.AzureEcosystem.Entities.Enums.DeploymentSlot deploymentSlot,
string name, string packageUrl,
string label, string base64Configuration,
bool startDeployment, bool treatWarningsAsError)
Uri uri = new
Uri(String.Format(Constants.CreateDeploymentUrlTemplate, subscriptionId, serviceName, deploymentSlot.ToString()));
XNamespace wa = Constants.xmlNamespace;
XDocument requestBody =
new XDocument();
String base64ConfigurationFile = base64Configuration;
String base64Label = label.ToBase64();
XElement xName = new
XElement(wa + "Name", name);
XElement xPackageUrl =
new XElement(wa +
"PackageUrl", packageUrl);
XElement xLabel = new
XElement(wa + "Label", base64Label);
XElement xConfiguration =
new XElement(wa +
"Configuration", base64ConfigurationFile);
XElement xStartDeployment =
new XElement(wa +
"StartDeployment", startDeployment.ToString().ToLower());
XElement xTreatWarningsAsError =
new XElement(wa +
"TreatWarningsAsError", treatWarningsAsError.ToString().ToLower());
XElement createDeployment =
new XElement(wa +
"CreateDeployment");
createDeployment.Add(xName);
createDeployment.Add(xPackageUrl);
createDeployment.Add(xLabel);
createDeployment.Add(xConfiguration);
createDeployment.Add(xStartDeployment);
createDeployment.Add(xTreatWarningsAsError);
requestBody.Add(createDeployment);
requestBody.Declaration =
new XDeclaration("1.0",
"UTF-8", "no");
XDocument responseBody;
RestApiUtility.InvokeRequest(
uri, Infosys.AzureEcosystem.Entities.Enums.RequestMethod.POST.ToString(),
HttpStatusCode.Accepted, requestBody, certificate, version,
out responseBody);
<summary>
/// A helper function to invoke a Service Management REST API operation.
/// Throws an ApplicationException on unexpected status code results.
/// </summary>
/// <param name="uri">The URI of the operation to invoke using a web request.</param>
/// <param name="method">The method of the web request, GET, PUT, POST, or DELETE.</param>
/// <param name="expectedCode">The expected status code.</param>
/// <param name="requestBody">The XML body to send with the web request. Use null to send no request body.</param>
/// <param name="responseBody">The XML body returned by the request, if any.</param>
/// <returns>The requestId returned by the operation.</returns>
public static
string InvokeRequest(
Uri uri,
string method,
HttpStatusCode expectedCode,
XDocument requestBody,
X509Certificate2 certificate,
string version,
out XDocument responseBody)
responseBody =
null;
string requestId = String.Empty;
HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create(uri);
request.Method = method;
request.Headers.Add("x-ms-Version", version);
request.ClientCertificates.Add(certificate);
request.ContentType =
"application/xml";
if (requestBody != null)
using (Stream requestStream = request.GetRequestStream())
using (StreamWriter streamWriter =
new StreamWriter(
requestStream, System.Text.UTF8Encoding.UTF8))
requestBody.Save(streamWriter,
SaveOptions.DisableFormatting);
HttpWebResponse response;
HttpStatusCode statusCode =
HttpStatusCode.Unused;
try
response = (HttpWebResponse)request.GetResponse();
catch (WebException ex)
// GetResponse throws a WebException for 4XX and 5XX status codes
response = (HttpWebResponse)ex.Response;
try
statusCode = response.StatusCode;
if (response.ContentLength > 0)
using (XmlReader reader =
XmlReader.Create(response.GetResponseStream()))
responseBody =
XDocument.Load(reader);
if (response.Headers !=
null)
requestId = response.Headers["x-ms-request-id"];
finally
response.Close();
if (!statusCode.Equals(expectedCode))
throw new
ApplicationException(string.Format(
"Call to {0} returned an error:{1}Status Code: {2} ({3}):{1}{4}",
uri.ToString(),
Environment.NewLine,
(int)statusCode,
statusCode,
responseBody.ToString(SaveOptions.OmitDuplicateNamespaces)));
return requestId;
But every time we are getting the below error from the line
response = (HttpWebResponse)request.GetResponse();
<Error xmlns="http://schemas.microsoft.com/windowsazure" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<Code>BadRequest</Code>
<Message>The specified configuration settings for Settings are invalid. Verify that the service configuration file is a valid XML file, and that role instance counts are specified as positive integers.</Message>
</Error>
Any help is appreciated.
Thanks,
ShubhenduPlease find the request XML I have found it in debug mode
<CreateDeployment xmlns="http://schemas.microsoft.com/windowsazure">
<Name>742d0a5e-2a5d-4bd0-b4ac-dc9fa0d69610</Name>
<PackageUrl>http://shubhendustorage.blob.core.windows.net/shubhendustorage/WindowsAzure1.cspkg</PackageUrl>
<Label>QXp1cmVFY295c3RlbURlcGxveW1lbnQ=</Label>
<Configuration>77u/PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0NCiAgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKg0KDQogIFRoaXMgZmlsZSB3YXMgZ2VuZXJhdGVkIGJ5IGEgdG9vbCBmcm9tIHRoZSBwcm9qZWN0IGZpbGU6IFNlcnZpY2VDb25maWd1cmF0aW9uLkNsb3VkLmNzY2ZnDQoNCiAgQ2hhbmdlcyB0byB0aGlzIGZpbGUgbWF5IGNhdXNlIGluY29ycmVjdCBiZWhhdmlvciBhbmQgd2lsbCBiZSBsb3N0IGlmIHRoZSBmaWxlIGlzIHJlZ2VuZXJhdGVkLg0KDQogICoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioNCi0tPg0KPFNlcnZpY2VDb25maWd1cmF0aW9uIHNlcnZpY2VOYW1lPSJXaW5kb3dzQXp1cmUxIiB4bWxucz0iaHR0cDovL3NjaGVtYXMubWljcm9zb2Z0LmNvbS9TZXJ2aWNlSG9zdGluZy8yMDA4LzEwL1NlcnZpY2VDb25maWd1cmF0aW9uIiBvc0ZhbWlseT0iMSIgb3NWZXJzaW9uPSIqIiBzY2hlbWFWZXJzaW9uPSIyMDEyLTA1LjEuNyI+DQogIDxSb2xlIG5hbWU9IldlYlJvbGUxIj4NCiAgICA8SW5zdGFuY2VzIGNvdW50PSIyIiAvPg0KICAgIDxDb25maWd1cmF0aW9uU2V0dGluZ3M+DQogICAgICA8U2V0dGluZyBuYW1lPSJNaWNyb3NvZnQuV2luZG93c0F6dXJlLlBsdWdpbnMuRGlhZ25vc3RpY3MuQ29ubmVjdGlvblN0cmluZyIgdmFsdWU9IkRlZmF1bHRFbmRwb2ludHNQcm90b2NvbD1odHRwcztBY2NvdW50TmFtZT1zaHViaGVuZHVzdG9yYWdlO0FjY291bnRLZXk9WHIzZ3o2aUxFSkdMRHJBd1dTV3VIaUt3UklXbkFrYWo0MkFEcU5saGRKTTJwUnhnSzl4TWZEcTQ1ZHI3aDJXWUYvYUxObENnZ0FiZnhONWVBZ2lTWGc9PSIgLz4NCiAgICA8L0NvbmZpZ3VyYXRpb25TZXR0aW5ncz4NCiAgPC9Sb2xlPg0KPC9TZXJ2aWNlQ29uZmlndXJhdGlvbj4=</Configuration>
<StartDeployment>true</StartDeployment>
<TreatWarningsAsError>false</TreatWarningsAsError>
</CreateDeployment>
Shubhendu G -
How do I get the configuration settings for GPRS mms ect for EE
Hiya :)
My son-in-law got a new iphone4s as an upgrade from EE/orange on Tuesday 18th feb 2014
It was an upgrade for his sim only contract changed to a phone and sim
The first phone he had was a samsung galaxy s3 mini but he couldn't get used to it as had used his old iphone4 for over 4 years before it died
The samsung galaxy s3 mini was sent back and a nice shiny iphone4s was sent out instead and he got it on the date up top
The sim that came with the iPhone keeps saying invalid for some reason?
But the sim he got with the sg3 mini works but has no configuration settings for the iphone4s in it only for the sg3 mini
We have tried online looking for the settings for wap/GPRS/mms/edge ect to send via SMS but can't seem to find anywhere that works?
Can anybody help please?
His partner (my daughter) is expecting there 2nd baby and he wants these set up ASAP
He can recieve calls and make calls and do the same with SMS but no Internet/mms ectCheck out FEBE. <br />
https://addons.mozilla.org/en-US/firefox/addon/2109/ -
Hello,
I am tryint to update deployment and always have following error
"The specified configuration settings for Settings are invalid. Verify that the service configuration file is a valid XML file, and that role instance counts are specified as positive integers."
Have found similar
thread and
stack overflow - without any success. I am not chaning anyting. Just reading deployment configuration and tryint to update with the same settings. I use .net azure sdk wrappers to generate requests. Code looks like:
var deployment = client.Deployments.GetByName(location.DataCenter, location.Cluster);var result = client.Deployments.ChangeConfigurationByName(location.DataCenter, location.Cluster, new DeploymentChangeConfigurationParameters{ Configuration = deployment.Configuration});
Catched request response from fiddler:
POST https://management.core.windows.net/[subscription-id]/services/hostedservices/[service-name]/deployments/[deployment-name]/?comp=config HTTP/1.1
x-ms-version: 2013-11-01
User-Agent: Microsoft.WindowsAzure.Management.Compute.ComputeManagementClient/0.9.0.0
client-tracking-id: 2
Content-Type: application/xml
Host: management.core.windows.net
Content-Length: 544
Expect: 100-continue
Connection: Keep-Alive
<ChangeConfiguration xmlns="http://schemas.microsoft.com/windowsazure">
<Configuration>PFNlcnZpY2VDb25maWd1cmF0aW9uIHhtbG5zOnhzZD0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9YTUxTY2hlbWEiIHhtbG5zOnhzaT0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9YTUxTY2hlbWEtaW5zdGFuY2UiIHhtbG5zPSJodHRwOi8vc2NoZW1hcy5taWNyb3NvZnQuY29tL1NlcnZpY2VIb3N0aW5nLzIwMDgvMTAvU2VydmljZUNvbmZpZ3VyYXRpb24iPiAgPFJvbGUgbmFtZT0ieWF1aGVuLWNjaXMyIj4gICAgPEluc3RhbmNlcyBjb3VudD0iMSIgLz4gIDwvUm9sZT48L1NlcnZpY2VDb25maWd1cmF0aW9uPg==</Configuration>
<ExtendedProperties />
</ChangeConfiguration>
Response
HTTP/1.1 400 Bad Request
Cache-Control: no-cache
Content-Length: 351
Content-Type: application/xml; charset=utf-8
Server: 1.0.6198.51 (rd_rdfe_stable.140226-1543) Microsoft-HTTPAPI/2.0
x-ms-servedbyregion: ussouth
x-ms-request-id: dcb1c5aedb5872d4aaf90acfede2de0b
Date: Tue, 04 Mar 2014 13:38:10 GMT
<Error xmlns="http://schemas.microsoft.com/windowsazure" xmlns:i="http://www.w3.org/2001/XMLSchema-instance"><Code>BadRequest</Code><Message>The specified configuration settings for Settings are invalid. Verify
that the service configuration file is a valid XML file, and that role instance counts are specified as positive integers.</Message></Error>
the same data returned by operation status. Decoded base-64 encoded string looks like
<ServiceConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/ServiceHosting/2008/10/ServiceConfiguration">
<Role name="yauhen-ccis2">
<Instances count="1" />
</Role>
</ServiceConfiguration>
Have tried without new line symbols, without xmlns, updating by production. without any successHi,
The configuration file is a file with extension .cscfg. If you have Visual Studio, the file is automatically generated when you create the project, and automatically updated when you modify the project's properties.
>> Not sure were could I get content of this file from api?
It's needed to encode this file's content use base64, and put the result in the body of your request. (Please refer to
http://msdn.microsoft.com/en-us/library/windowsazure/ee758710.aspx for more information.)
>> <ChangeConfiguration xmlns="http://schemas.microsoft.com/windowsazure">
<Configuration>PFNlcnZpY2VDb25maWd1cmF0aW9uIHhtbG5zOnhzZD0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9YTUxTY2hlbWEiIHhtbG5zOnhzaT0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9YTUxTY2hlbWEtaW5zdGFuY2UiIHhtbG5zPSJodHRwOi8vc2NoZW1hcy5taWNyb3NvZnQuY29tL1NlcnZpY2VIb3N0aW5nLzIwMDgvMTAvU2VydmljZUNvbmZpZ3VyYXRpb24iPiAgPFJvbGUgbmFtZT0ieWF1aGVuLWNjaXMyIj4gICAgPEluc3RhbmNlcyBjb3VudD0iMSIgLz4gIDwvUm9sZT48L1NlcnZpY2VDb25maWd1cmF0aW9uPg==</Configuration>
However, may I know how you find the body for your request? (It seems you do a base64 decoding, you find it is a valid configuration file, but it doesn't have any configuration settings.) Actually, the settings defined in csdef needed to
be contained in the configuration file.
Best Regards,
Ming Xu
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey. -
Is it possible to call website from ABAP Program?
Hi Experts,
Is it possible to call website from ABAP Program?
It is very Urgent Help me.
Regards,
Ashok.Hi,
Check the following program:
REPORT ZURL NO STANDARD PAGE HEADING.
DATA: BEGIN OF URL_TABLE OCCURS 10,
L(25),
END OF URL_TABLE.
URL_TABLE-L = 'http://www.lycos.com'.APPEND URL_TABLE.
URL_TABLE-L = 'http://www.hotbot.com'.APPEND URL_TABLE.
URL_TABLE-L = 'http://www.sap.com'.APPEND URL_TABLE.
LOOP AT URL_TABLE.
SKIP. FORMAT INTENSIFIED OFF.
WRITE: / 'Single click on '.
FORMAT HOTSPOT ON.FORMAT INTENSIFIED ON.
WRITE: URL_TABLE. HIDE URL_TABLE.
FORMAT HOTSPOT OFF.FORMAT INTENSIFIED OFF.
WRITE: 'to go to', URL_TABLE.
ENDLOOP.
CLEAR URL_TABLE.
AT LINE-SELECTION.
IF NOT URL_TABLE IS INITIAL.
CALL FUNCTION 'WS_EXECUTE'
EXPORTING
program = 'C:\Program Files\Internet Explorer\IEXPLORE.EXE'
commandline = URL_TABLE
INFORM = ''
EXCEPTIONS
PROG_NOT_FOUND = 1.
IF SY-SUBRC <> 0.
WRITE:/ 'Cannot find program to open Internet'.
ENDIF.
ENDIF.
Regards,
Bhaskar -
Configuration Settings for Postal Adress Validation and Duplicate Check
Hi,
What are The Configuration settings for Postal adress validation and Duplicate Check for Accounts(BP'S) in CRM 7.0 version
Can some one send me the configuration settings for Postal Adress validation and Duplicate Check
Thanks & Regards
Kishor KumarHi kishore kumar,
For the Postal code Validation you need to install and configure the following
Outside of your SAP system:
1. Install Data Services and the Address Directories.
2. Install Data Services Component.
3. Install the RFC Server.
On your SAP system:
4. Install the BAdIs from the previous version of this product.
5. Install the BAdIs support package from this version.
6. Run the post-installation tasks required of a new installation of the BAdIs.
7. Activate the IC WebClient, if desired.
Thanks
Jayakrishnan Nair -
JCo connectivity is used to call RFCs from Java. can i call Java from abap?
thanks in advance.....
regards,
SundararamaprasadHi Sundar ,
This link will surely give u an idea about calling java fro ABAP using Jco.
http://www.thespot4sap.com/Articles/SAP_Netweaver_Java_Connector.asp
regards,
aravindh. -
Configuration Settings for Web Dynpro
Please tell me ICM and ICF configuration settings for Web Dynpro programs.
Can anybody tell me what is pre requirment for Web Dynpro.hi Shweta ,
pls refer the SAP online help :
http://help.sap.com/SAPHELP_NW04S/helpdata/EN/fa/a5554a1de4964e8459851782eddda3/frameset.htm
regards,
amit -
Configurational settings for data source in BI server
Hi Sdns,
Where can we make configurational settings for data source in BI server.
Advance thanks to replies.
karunGo to T-code RSA13.
Search you desired BI system.
Right click on it and Display Data Source Tree.
There you can see all your datasource with BI as source system.
You can do the same for other source systems.
Double click on the datasource to see the fields and configuration. -
Can anyone give me step by step for calling FM from one SAP to another SAP
can anyone give me step by step for calling FM from one SAP to another SAP
points will be rewarded,
thank you,
Regards,
Jagrut BharatKumar Shukla*& Report RFC_FOR_CUSTOMER_LIST
*& RFC to a Fn. module from another system which implements BAPI
REPORT rfc_for_customer_list.
DATA:
fl_status TYPE i.
DATA:
fs_message TYPE bapiret2.
DATA:
BEGIN OF fs_customers,
id TYPE s_customer,
name TYPE s_custname,
END OF fs_customers.
DATA:
t_customers LIKE
STANDARD TABLE
OF fs_customers.
CALL FUNCTION 'Z_BAPI_GET_CUSTOMER_LIST' DESTINATION 'R3N'
IMPORTING
return = fs_message
TABLES
customerlist = t_customers.
IF sy-subrc EQ 0.
fl_status = 1.
LOOP AT t_customers INTO fs_customers.
WRITE:
/10 fs_customers-id,
30 fs_customers-name.
AT LAST.
WRITE:
/,/5 'No of customers in R3N = ', sy-tabix.
ENDAT.
ENDLOOP.
ELSE.
MESSAGE 'RFC failed' TYPE 'S'.
EXIT.
ENDIF.
TOP-OF-PAGE EVENT *
TOP-OF-PAGE.
IF fl_status NE 0.
WRITE:
/12 'ID' COLOR 6,
32 'NAME' COLOR 6.
SKIP.
ENDIF.
This is one small example...
Regards,
Pavan -
Please tell me configuration settings for Availability check
HI gurus,
Please telllme configuration settings for Availability check
regards
DVSKPlease read the "Rules and Regulations" of the forum b4 posting any question. This topic was discussed in this forum quite frequently and had you taken efforts to search, you would have got it.
Please check this thread
[can any body explain the configuration settings of AVAILABILITY CHECK|can any body explain the configuration settings of AVAILABILITY CHECK with.]
thanks
G. Lakshmipathi -
What are the backend configuration required for photo upload from portal?
Hi all,
When i am trying to upload the photo from portal it is giving error
can not archive the photo
we are using portal 7 and ecc 6.0
I want to know
What are the backend configuration required for photo upload from portal
Can any but help me out
RajendraHi,
Are you using the standard iview. If that's the case you need to configure in the backend. Meaning you need to store the photo in the Org management(HR) which the HR functional guys will do. You just need to add the iview to your role.
Let me know if you require further informationn.
Award points if helpful.
Cheers,
sathya
Maybe you are looking for
-
Creation of item-R12.1.1-Error
Hi, In Release 12(Version 12.1.1.)when i try to create a new item, and applying a purchasing template to item i am not able to commit the item. especially while giving list price column that system wont accept the field. becoz of that i am not able t
-
Updating To Mac OS X 10.6
Hello I am trying to update a friends macbook air (OS X 10.5.8, 1.6 GHz intel Core 2 Dou, 2 GB DDR2 SDRAM) to 0S X 10.6.1. But it says Mac OS X 10.6 cannot be installed on this computer. I am wondering if I am missing something? Thanks in advance
-
Can i use whatsapp in my i pad mini wifi only? I couldnt find whatsapp from store.
Can i use whatsapp in my i pad mini wifi only? I couldnt find whatsapp from store. Please share your valuable information.
-
Tonight, I was unable to get either Expose to work or bring up my dashboard widgets with my usual mighty mouse buttons. I was able to manually switch between several windows by either clicking on the window or if hidden, click again on the dock icon.
-
Javafx streaming video in mobile
Hi guys. I have a problem here. Hope you could help. Here is the situation: Scene 1 contains a button that redirects to scene 2. Scene 2 contains the video. What happens is.. while still in scene 1, the video plays. The question How can I let the vid