0

I am running into some scoping issue and wanted some advice. So i have a controller which has the singleton bean. This bean has a request scoped bean (using aop proxy) which contains information about logged in user and other user information. During the processing of a request, we create a new java process (executing jar file that takes in some files and processing the information). Is it possible to send the user information to the singleton beans injected in the new java process?

1 Answers1

0

The new java process is completely outside of the spring cointainer and that jvm. if you want to send informations from one jvm instance to another it is possible with

  • JVM Arguments (like commandline arguments)
  • Streams (Send informations over Socket, files, etc)
  • Database
  • ...

Than the singleton bean has to read the user informations on start. If your user informations are very simple, I would prefer jvm arguments and for complex objects streams.

Shared Memory between two JVMs

Community
  • 1
  • 1
Matthias
  • 1,378
  • 10
  • 23