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

  • Home
  • SEARCH
  • 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 3614748
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T22:17:18+00:00 2026-05-18T22:17:18+00:00

I like to write a little server application being controlled by a little console

  • 0

I like to write a little server application being controlled by a little console app (start, pause, stop, etc). For the server spring should be used (part of it already exist). So what I do to start the server is something like this:

  1. start a server thread and exit main method

and then, in the thread:

  1. load application context from xml
  2. start some worker threads connecting to beans doing stuff

Now I want the server to be stopped by another command. How can I connect to the already running context and shut it down?

Thanks for your help,
Alexander

  • 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-05-18T22:17:19+00:00Added an answer on May 18, 2026 at 10:17 pm

    The classical way to manage running Java code is through JMX.
    Spring lets you export beans as MBeans.

    And for accessing JMX via the command line, look at the answers to this recent question:

    Calling JMX MBean method from a shell script

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

Sidebar

Related Questions

I write a little Chat Application. To save some infos like Username and Password
I'd like to write an app that monitors incoming SMS and notify me on
I have to write an application that is essentially a proxy server to handle
I'm trying to make a little client-server script like many others that I've done
I want to write an application using processing-JS , and I'd like to be
I would like to write a little code that copy on a local pc
A little context: I would like to separate the Java application I'm writing into
If I write like this: ShellExecute(NULL, open, www.google.com, NULL, NULL, SW_SHOWNORMAL); Everything's okay and
I like to write a process in Worker role, to download (sync) batch of
I would like to write an abstract base class class func_double_double_t : public unary_function<double,

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.