What is Data Modelling?
Why Data Modeling?
Data Modeling in Hybris
Type System in Hybris
- Atomic Types
- Item Types
- Relation Types
- Enumeration Types
- Collection Types
- Map Types
Deployment & How it Works?
References
3. More About RazorfishNeev
• Publicis Groupe announced Neev acquisition in April 2013.
• Executed 200+ projects over last 10 years.
• Full Product/Application Lifecycle capabilities.
• Strong skills around Web, Mobile and Cloud technologies primarily in Java and other
Open Source products/frameworks.
• Strong culture of innovation and problem solving.
• Ability to provide 24X7 services.
• Ability to execute deliver under tight timelines; most projects use Agile methodology.
5. ▪ Tables creation
▪ Relation between tables
System Id Employee Id Issue Date
INBLRNEEV248 60570 Jan 2014
System Id RAM
Hard Disk
Capacity
INBLRNEEV248 16 gb 320 gb
Employee Id Employee Name Designation
60570 Raghav Desu Hybris Dev
INBLRNEEV248 – Raghav – Jan 2014
Raghav – 60570 – jan 2014 – Hybris developer
Inblrneev248 – 16gb ram – 320 gb harddisk
Why Data Modeling?
Unstructured Data Structured Data
6. Data Modeling in Hybris
• Hybris Data Modeling is the answer to questions like, “How Hybris is going to
handle the database?” or “how can we create new tables or entire database in
Hybris?”
• Hybris data modeling helps you in developing your database.
• Hybris data modeling can take care of the database connections and database
queries.
• Hybris will take care of deploying a table in Database, altering it and updating it
with new records.
• Hybris service layer provides all services for database handling.
7. Items.xml: File used for data modelling.
Item types: Creating Tables
Relation types: Creating relation between the tables
Atomic types: Atomic Types
Enum types: Enums
Map types: Maps
Collection types: Collections
Type System in Hybris
Type System
Data Modeling in Hybris is designed with the help of Type System in Hybris
The Hybris Type system supports the following types.
Each type has its own significance in the type system .
Source: Hybris Wiki
8. <atomictypes>
<atomictype class="java.lang.Object" autocreate="true" generate="false"/>
<atomictype class="java.lang.Boolean" extends="java.lang.Object"
autocreate="true" generate="false"/>
<atomictype class="java.lang.Double" extends="java.lang.Number"
autocreate="true" generate="false"/>
<atomictype class="java.lang.String" extends="java.lang.Object"
autocreate="true" generate="false"/>
</atomictypes>
Core-items.xml
Atomic Types
Atomic Types are basic types in Hybris which will have Java number and string object types, such as
java.lang.Integer or java.lang.String
9. Item Types
• Item Types are foundation for the
Hybris Type System.
• Item Types are responsible for
creating new tables or updating the
existing tables.
• The table structure is configured over
this type with the help of attributes.
• Each attribute in Item type definition
will represent a column in the table.
<itemtype code="Customer“ extends="User"
jaloclass="de.hybris.platform.jalo.user.Customer"
autocreate="true“ generate="true">
<attributes>
<attribute autocreate="true"
qualifier="customerID"
type="java.lang.String">
<modifiers read="true" write="true"
search="true"
optional="true"/>
<persistence type="property"/>
</attribute>
</attributes>
</itemtype>
10. <relation code="Country2RegionRelation" generate="true" localized="false" autocreate="true">
<sourceElement type="Country" qualifier="country" cardinality="one">
<modifiers read="true" write="true" search="true" optional="false"
unique="true"/>
</sourceElement>
<targetElement type="Region" qualifier="regions" cardinality="many">
<modifiers read="true" write="true" search="true" partof="true"/>
</targetElement>
</relation>
Relation Types
Relation Types creates link between tables. For e.g.: Country and regions are linked together, where
the link is created with the help of relation types.
11. Enumeration Types
<enumtype code="CreditCardType" autocreate="true"
generate="true">
<value code="amex"/>
<value code="visa"/>
<value code="master"/>
<value code="diners"/>
</enumtype>
Enumeration Types represent the enumeration in Java. These are used for preparing particular set of
values. For e.g. : Days in a week or months in a year.
12. Collection Types
Collection Types are the types which represent group of element types like a group of products or a group
of customers.
<collectiontype code="ProductCollection" elementtype="Product" autocreate="true" generate="true"/>
<collectiontype code="LanguageList" elementtype="Language" autocreate="true" generate="true"
type="list"/>
<collectiontype code="LanguageSet" elementtype="Language" autocreate="true" generate="true"
type="set"/>
13. <maptype code="localized:java.lang.String“ argumenttype="Language“
returntype="java.lang.String“ autocreate="true“ generate="false"/>
Map Types
• Map Types used to store key value pairs in Hybris. Each key will represent its own
value.
• For e.g. : The localized fields require separate value for each language.
For Example:
<attribute autocreate="true" qualifier="name"
type="localized:java.lang.String">
<modifiers read="true" write="true" search="true"
optional="true"/>
</attribute>
14. <deployment table="Products" typecode="1" />
• Table creation
• Ancestors attributes
• Default extend for all tables, if no deployment
Deployment
• commons extension (132xx)
• print extension (234xx,239xx)
• processing extension (327xx)
• Legacy xprint extension (244xx,245xx)
• b2bcommerce extension (100xx)
Hybris Conventions for Deployment Codes
• In Hybris, the table deployment in database is defined by deployment tag.
• If we add a deployment tag to Item type definition, it will isolate that table from its parent table and
deploy separately.
• If we don’t add deployment to it, it will deploy Item type along with its parent table.
• Hybris supports updating the existing table (adding new columns, re-declaring the columns) and
creating own tables.
15. • Ant all
• Ant clean all
How it Works?
Source: Hybris Wiki
17. Tenants allow customizing:
• currency
• currency format
• date format
Kinds of Tenants
Creating New Tenants
installed.tenants=junit,foo,t1,t2
Local_tenant_junit.properties
db.tableprefix=myjunit_
Multi Tenant Support
Source: Hybris Wiki
Features
22. The Razorfish India Edge
– End-to-end consultative approach for software solutions through needs assessment, process consulting
and strategic advice.
– Internal QMS are ISO 9001-2008 certified and CMM level 3 compliant.
– Continuous process and service level improvements through deployment of best-of-breed processes and
technologies.
– International Standards and best practices on Project Management including PMI, ISO and Prince-2.
– Proven EDC Model of delivery to provide predictable results.
– Scrum based Agile development methodology.
23. Contact us
India - Bangalore
The Estate, # 121,
6th Floor,
Dickenson Road
Bangalore - 560042
Phone :+91-80-25594416
India - Gurgaon
90 D, Sector 18, Udyog
Vihar Phase 5,
Gurgaon -122015
Phone: 91-98 1101 5736
16th Floor, Urmi Estate,
Ganapatrao Kadam Marg,
Mumbai - 400013
Phone: +91-9811015736
India - Mumbai
For more info on our offerings, visit www.neevtech.com
Reach out | sales@neevtech.com