Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8374665
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T14:58:17+00:00 2026-06-09T14:58:17+00:00

Our application has very large data and we want to perform our business logic

  • 0

Our application has very large data and we want to perform our business logic (aggregations)
in the Database Layer (Stored Procedures).

Liferay prefers to have business logic in Business Layer (having mutli-layered Architecture).

What is the impact if we want to use Stored Procedures for Business Logic?

As Liferay also uses Hibernate, Is there a way to by-pass hibernate in this case if it doesn’t add much value in this case?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T14:58:18+00:00Added an answer on June 9, 2026 at 2:58 pm

    There are reasons why Liferay does its business logic at application code level (high level):

    1. This way the portal becomes database agnostic, and hence can be deployed without considering much about the underlying database.
    2. Not all databases support Stored Procedures. So to support multiple databases the code can’t be in Stored Procedure.
    3. Portals are mostly content driven and not so much data intensive.

    There may be other reasons or there might be some other philosophy they may be following, but this is what I can think of right now.

    So now the question whether you can use it or not?

    As frant.hartm says, it is completely up to you. It depends upon your requirement and how you plan to design, maintain and enhance your architecture.

    Also as a word of caution: It is recommended not to use Liferay’s database tables directly from Stored procedures as Liferay may change the Database architecture for newer versions. So it might complicate your upgrade procedure.

    I feel this question is not so liferay related, hence here are some links that might help you decide:

    1. Arguments for/against Business Logic in stored procedures. The first few answers are good pointers in this direction.
    2. Whether to put the business logic in Stored Procedure or Not?
    3. Code generators vs. ORMs vs. Stored Procedures.

    Is there a way to by pass hibernate in this case if it doesn’t add much value in this case.

    If it does not add value then yes you can use JDBC for your own custom portlet by-passing hibernate. There is nothing special to configure for using JDBC, it is the same good old thing 🙂.

    Hope this leads you in a positive direction.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Our application has a very large, wide table of transactional data. We have a
Our application has a service layer and a DAO layer, written as Spring beans.
Our large application (VB.Net, Framework 3.5) has been developed more or less from the
A module I'm adding to our large Java application has to converse with another
Our application has many controls that are created dynamically. For example, a navigation pane
Our application has a couple of shell scripts that are called from web-based Oracle
Our Java application has a number of modules which implement a common interface. By
I'm currently going through the process of running FxCop through our application that has
I have a Windows application. The windows application has our XML Library on it.
In our application through the process of developing a lot of JAR files has

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.