Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

more examples of attaching scalive to JVM process #16

Open
zinking opened this issue Aug 9, 2016 · 1 comment
Open

more examples of attaching scalive to JVM process #16

zinking opened this issue Aug 9, 2016 · 1 comment

Comments

@zinking
Copy link

zinking commented Aug 9, 2016

I felt this offers great help when we could hook into a running JVM. but I don't know the details.

what are the could be done ?

  1. modify class/method definition?
  2. fetch and update beans like in a spring jam?
  3. more.
@ngocdaothanh
Copy link
Member

ngocdaothanh commented Aug 24, 2016

modify class/method definition?

No Scalive can't do that, because in order to do that you need to create classloaders. Currently Scalive simply uses the classloader in the target process.

You can still do that if your program is designed up front for that purpose. For example:

object O {
  var myFunction: MyInterface = defaultImplementation
}

Then later, in Scalive REPL console you set O.myFunction to point to another implementation.

fetch and update beans like in a spring jam?

I guess this is possible. But I'm not very familiar with Spring.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants