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 9149943
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T11:32:46+00:00 2026-06-17T11:32:46+00:00

Consider some AppModule in Tapestry project. I want to order sequence of actions, which

  • 0

Consider some AppModule in Tapestry project.

I want to order sequence of actions, which must invoke on system startup.

Consider, I have two simple actions:

1) Action, which must go first:

@Startup
public static void initMyApplication(Logger logger, LiquibaseService liquibaseService) {
    logger.info("Updating database by liquibase service...");
    liquibaseService.update();
    logger.info("update-db done.");
}

2) and the second one:

@Startup
@Order("after:LiquibaseService")
public static void doSomeChecks(HibernateSessionManager hsm) {
   ... 
}

I can not understand (even after reading documentation): how can I specify order of such actions using @Order annotation?

More specifically: what do I need to point into @Order("after:<HERE>)?

It seems, that constructions like:

@Order("after:LiquibaseService")

or

@Order("after:initMyApplication")

don’t work. Actually my startup actions are invoked in arbitrary order.

  • 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-17T11:32:47+00:00Added an answer on June 17, 2026 at 11:32 am

    I don’t think @Order can be used with @Startup but what you can do is use contributeRegistryStartup. As it expects an OrderedConfiguration you can order your contributions.

    public class MyModule1
    {
      public static void contributeRegistryStartup(OrderedConfiguration<Runnable> configuration)
      {
        configuration.add("MyFirstContribution", new Runnable() { ... });
      }
    }
    
    public class MyModule2
    {
      public static void contributeRegistryStartup(OrderedConfiguration<Runnable> configuration)
      {
        configuration.add("MySecondContribution", new Runnable() { ... }, "after:MyFirstContribution");
      }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Consider I have lamba foo which just does some stuff and doesn't need to
Consider that in some library somewhere (which we have no access to change), we
Consider I have some abstract Vehicle class and car, truck, motorcycle abstract classes which
We're designing a database in which I need to consider some FK(foreign key) constraints.
Consider following string Some string with quotes and \pre-slashed\ quotes Using regex, I want
Consider the following common situation: You have some MainView in your Cocoa application, loaded
Consider this simplified view of some code with which I'm working: @Stateless(...) @Remote(...) @TransactionAttribute(TransactionAttributeType.MANDATORY)
Consider following assumptions: I have Java 5.0 Web Application for which I'm considering to
Consider a std::priority_queue where N elements have the same priority. Now consider some pop()
Consider you have some expression like i = j = 0 supposing this is

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.