Sei sulla pagina 1di 5

SssssssssssssSAP Hana Web work bench

- Provides tools to develop, build, deploy


application

HANA XS – Hana extended application


server

SAP HANA XS Classic model *It provides the HANA web based
workbench to develop the entire
Run time environment which runs the applications without using/installing
application development tools
Maintain the hierarchy package structure while creating the applications

1. Create the root package(Use company’s DNS as root application development folder)
2. Create application descriptors(the root point in the package from which content can be
served to client requests & check the whether the application is permitted to expose the
data to client requests)
3. Secure the application

Application Descriptors:

- Describes the framework in which the SAP HANA XS application runs


- It contains the root point in the package hierarchy where content is to be served for the client
requests & who has access to the content.
- Application descriptor file (.xsapp)
- Application access file(.xsaccess)
- Application privilege file(.xspriveleges)
- We must create .xsapp and .xsaccess

Application root package:

- The package which contains the .xsapp file becomes the root path of the resources exposed by
the application we develop.
- Make sure that the folder containing the .xsapp application descriptor file also contains
an .xsaccess file, which controls access to the application.
- The application-descriptor file has no name and no content; it only has the file
extension “xsapp”, for example, .xsapp.
- The application root is determined by the package containing the .xsapp file. For example, if the
package sap.test contains the file .xsapp, the application will be available under the
URL http://<host>:<port>/sap.test/. Application content is available to requests from users.

.xsaccess file:

“Exposed”:true => to enable access to the content

“exposed”:false => to disable the access to content

}
{

“authentication”: { “method” : “form” } => basic or form based authentication

“authorization”:[“<package.path>::Execute”,

“<package.path>::Admin”]

The authorization keyword requires a corresponding entry in the .xsprivileges file, for
example, execute for basic privileges or admin for administrative privileges on the specified
package:

"exposed" : true, // Expose data via http

"authentication" :

"method": "Form"

},

"authorization": // Privileges for application access

"sap.xse.test::Execute",

"sap.xse.test::Admin"

],

"rewrite_rules" : // URL rewriting rules

[{

"source": "/entries/(\\d+)/(\\d+)/(\\d+)/",

"target": "/logic/entries.xsjs?year=$1&month=$2&day=$3"

} ],

"mime_mapping" : // Map file-suffix to MIME type

[{

"extension":"jpg", "mimetype":"image/jpeg"
} ],

"force_ssl" : true, // Accept only HTTPS requests

"enable_etags" : true, // Allow generation of etags

"prevent_xsrf" : true, // Prevent cross-site request forgery

"anonymous_connection" : "sap.hana.sqlcon::AnonConn", //.xssqlcc object

"default_connection" : "sap.hana.sqlcon::sqlcc", //.xssqlcc object

"cors" : // Permit cross-origin browser requests

"enabled" : false

},

"default_file" : "homepage.html", // Override default access setting

"cache_control" : "no-cache, no-store", // Manage static Web-content cache

"headers": // Enable X-Frame-Options HTTP header field

"enabled": true,

"customHeaders":

[{

"name":"X-Frame-Options","value":"SAMEORIGIN"

}]

}
Persistent model
Consumption model(exposed to
(defines schema, table, sequences, client application and users for
view that specifies what data make analyzing the data & displaying the
accessible for the consumption data in appropriate form)
model by XS application and how)

. The way you design and develop the database objects required for your data model depends on
whether you are developing applications that run in the SAP HANA XS classic or XS advanced run-
time environment.

SAP HANA XS Classic Model:

Enables to create database schema,


tables, views, sequences as design-
time files in SAP HANA Repository

Repository files can be read by


applications that we develop

While implementing the


persistence model in classic XS, we
can use either CDS syntax or HDB
syntax