Skip to Content
Technical Articles

HANA Deployment for XS Advanced applications

In this blog, I am going to describe the process of HANA XSA application deployment in a Dev — > QA — > Prod system landscape at a very high level. Also, I will explain different options available for deployment of XSA objects.

With the XS advanced server, the development and deployment process has been changed a bit from XS classic, on tooling prospective now we got Web IDE for HANA, GitHub and XS Command line tools for the purpose of object development, Source control and deployment respectively. Basically XSA is an On-Premise offering of Cloud foundry run times and deployments process in general.

In this document, I am going to take an example of MTA project’s db module which creates HDI-container objects in the database and then deploy them in QA and Production systems. However, the deployment process is going to be same for Node module or html module deployments as well.

The below picture describes the very high level process of development and deployment, explained in 3 major steps.

1. Development:

In the above example scenario, Developer_1 created an MTA project in Web IDE for HANA, with a DB module which has hdbtable and Calculation views as the development artifacts, upon the build, HDI container is created in the database as run time objects.

In Web IDE for HANA, MTA project source code is checked into/Committed GitHub by Developer_1, if the other developer also making changes to the same project, he/she can pull that project code from GitHub and make the necessary changes and build it. Upon the completion of build of Developer_2, a different HDI container is created for Developer_2 in the database, it is independent of Developer_1 container objects, thereafter developer_2 can commit the code back to GitHub with the latest changes. So version control and dependencies are managed very effectively GitHub. All of this happening in Dev space of Web IDE.

2. MTA Archive Generation: 

When the DB module is ready for deployment, Select the Project header and build it, with that an MTA Archive file is generated at the top of the project, this file has an extension of .mtar and it can have multiple modules to deploy at one time.

Alternatively you can use MTAR builder(command line tool) to package the MTAR file based on yaml configuration.

Once the MTAR is file is generated, then export the MTAR file to personal directory folder.

3. Deployment : 

there are several options available for deployment purpose,

Option 1: XS Command tool can be used to deploy the MTA project into a Central space in the Development system, Central space is different from Dev Space, though both spaces are configured in HANA developer server, Central space is considered as HANA Dev system of XS classic (just for understanding). Which means, all the prototypes and Sandbox work will be done in Dev space in Web IDE with GitHub source control and approved version will be deployed into central space by Admin.

So, there after the same MTAR file will be deployed into QA and Production as well using XS command tool based on the test results and approvals process defined in the organization.

Option 2: You can also configure CTS (SAP transport) to deploy XS Advanced objects, the process is very similar what explained above, however a transport landscape has to be configured, then attach the MTAR file to the TR created in SAP system and that can be imported into the target system. the detailed process is explained in this document, CTS for XSA.

Option 3: if you are implementing Continuous Integration and deployment(Dev Ops) model in your organization, GitHub or Jenkins tools can be used for the automatic deployment purpose.

Summary: Again,  It is a very high level explanation of deployment process for HANA XSA objects with a simple scenario as example, in the complex scenarios where an extensive use of services, synonyms to access to cross containers and ERP schema etc, deployment MTAR file will have to be generated by making sure all the dependencies are taken care appropriately.

 

Thank you.

 

 

12 Comments
You must be Logged on to comment or reply to a post.
  • Hi Sreekanth,

    I have recently migrated my views from XSC to XSA in development space.   Later verifying in development i have export of MTAR and deploying into production space.  while deploying i am facing below issue –

    Error updating application “db”: Could not bind application “db” to service “hdi_db”: 400 Bad Request: Could not bind application “db” to service “hdi_db”: Asynchronous job ‘Creating service binding between app ‘db’ [Org ‘orgname’, Space ‘PROD’] and service instance ‘hdi_db’ [service: ‘hana’, plan:’hdi-shared’] of [Org ‘orgname’, Space ‘PROD’].’ failed: Received error from service broker: REST request PUT to url ‘https://hana-1.prod.com:30032/hdi-broker/v2/service_instances/29b486cd-6cd8-4e67-8761-ad7550b8269e/service_bindings/8e899094-b840-4246-9a74-8d8a3fd802fc’ had response code 404 (Resource was not found) with error message: ‘description: Service instance ’29b486cd-6cd8-4e67-8761-ad7550b8269e’ not found.’..

  • looks like the properties of the service “hdi_db” is not defined correctly in mta.yaml file. the property value of the resource will be as ${service-name}, so that it gets the service name in the target space. I am assuming you have just one DB module in your project, but in case if you have multiple DB modules, you can add Target Container property to assign the respective resource to it explicitly.

    • I am having a similar issue. Is there anything in the settings of yaml we have to change? I am getting container already exists messages as well if I try to delete the services and deploy the change.

       

      Regards,
      Krishna Tangudu

      • Hi Krishna, for DB module creation, tool automatically creates the resource and assign that resource to DB module in mta.yaml file. you do not have to do anything more. You should be able to build that using Web IDE,, also you can deploy the MTAR file using CL tools. Please provide the error message you are getting.,it may help to find the issue.

        • Hi Sreekanth

          Thanks for your response. I noticed that when I define a fixed schema name in the container is when am facing this issue. if it doesn’t have a fixed schema am able to deploy this successfully.

          This is the error am receiving:

          Error updating application “TESTSCHEMA1”: Could not bind application “TESTSCHEMA1” to service “hdi_TESTSCHEMA1”: 400 Bad Request: Could not bind application “TESTSCHEMA1” to service “hdi_TESTSCHEMA1”: Asynchronous job ‘Creating service binding between app ‘TESTSCHEMA1’

           

          Request your help

           

          Regards,

          Krishna Tangudu

  • Hi Sreekanth,

    I am also facing the similar issue with below error.

    Error creating services: Error updating service “<service_name>” from offering “hana” and plan “hdi-shared”: Controller operation failed: 404 Not Found: Could not update parameters of service “<service_name>” to “{makeUniqueName=false, schema=TEST_SCHEMA}”: Could not update parameters for service <service_name>, resource not found: Received error from service broker: REST request PATCH to url ‘https://uaa-server.<serverhost>.com.sa:<port>/hdi-broker/v2/service_instances/29ade191-2512-4a9a-b28e-431a771a5e1c?accepts_incomplete=false’ had response code 404 (Resource was not found) with error message: ‘description: Instance ’29ade191-2512-4a9a-b28e-4dahsdghas’ does not exist’..

    Job failed.

    Please suggest.

     

    Regards,

    Chandra

  • HI Sreekanth,

     

    Was this issue resolved. I am facing the same problem.  I have user provided service for synonyms.

    But still it gives below error.

    Error updating application “db”: Could not bind application “db” to service “CC_ACCESS”: 404 Could not bind application “db” to service “CC_ACCESS”: service CC_ACCESS not found#

    Thanks

    Sujit

    • Hi Sujit, the errors are different. In your case, “service CC_ACCESS not found”,  which means that your user provided service is not identified during deployment. You will have to check that service in MTA.yaml file, whether it has right parameters and SERVICE_REPLACEMENT configuration. You can find the detailed information in this blog MTA services

  • Hi Sreekanth,

    Here I am trying to have CONTAINER access to another CONTAINER in a different project within the same space.

    This is the config that I have done:

    1. Create a user provided service (CC_ACCESS){
      “schema”: “zcs_subscription_admin_1”,
      “password”: “*******”,
      “driver”: “com.sap.db.jdbc.Driver”,
      “port”: “30041”,
      “host”: “**************”,
      “user”: “*******”,
      “tags”: [
      “hana”
      ]
    2. This is my mta file config:

    – name: CrossSchemaSysBi
    group: SERVICE_REPLACEMENTS
    properties:
    key: hdi-sys-bi-service
    service: ‘~{sys-bi-service-name}’

    – name: CrossSchemaSysBi
       type: org.cloudfoundry.existing-service
       parameters:
       service-name: CC_ACCESS
       properties:
       sys-bi-service-name: ‘${service-name}’

     

    Functionality wise this is working fine and able to access the container tables. But only in deployment is fails with error.

    Is my approach fine ?

     

    Thanks

    Sujit

  • Also from the Link you provided I feel I should follow step 3. But that has no detailed explanation.

    How do we do the following step.

    hdi container service must have been created and built before in order to get the access on that.

     

    • that is correct, you will have to follow Step 3 from that blog, because you do need to have a user provided service(CUPS) in order to access on HDI container. So you just take the hdi service created for Source db module and use that while creating the resource for your second project module. I have given the parameters to be applied in the screen shot of that blog.

  • I have created project 1 and deployed that successfully. Now I am using the service that is created from it hdi_subsdb and using it in my project 2. Still I am facing the same error.

    1. This is my mta file config:

    – name: CrossSchemaSysBi
    group: SERVICE_REPLACEMENTS
    properties:
    key: hdi-sys-bi-service
    service: ‘~{sys-bi-service-name}’

    – name: CrossSchemaSysBi
    type: org.cloudfoundry.existing-service
    parameters:
    service-name: hdi_subsdb
    properties:
    sys-bi-service-name: ‘${service-name}’