cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
677
Views
0
Helpful
11
Replies

No Effect on Packages Reload after Java-Code-Adjustment

Hi,

 

if I make a change to the java-source of a package (in this case of the sample vlan-package), then reload packages with "packages reload" in the NCS-cli, the change is not available.

 

In the following the steps I fulfilled:
- Set up eclipse-environment correspondingly
- Created vlan-package
- Adjusted yang-model
- Run "make" successfully
- Edited the java-source with an output (simple print a line)
- Run "make" successfully
- Started the Java-VM out of eclipse (NcsJVMLauncher -> main -> Run as Java Application)
- Tested the vlan-package via cli -> correct output (java-source printline is seen in the eclipse-console)
==> Now, after I made a second change to the same java-source, make, do "packages reload" via cli and test, the old output is still seen, until restart of java-vm.

 

My question is: Do I have to restart Java-VM every time I make a change to the sourcecode?
My assumption was that "make" and "packages reload" is sufficient to make the change available, which, it seems, is not the case (thus the former state of the java-source is kept "somehow").

 

Thanks & best regards,
Mesut

11 Replies 11

vleijon
Cisco Employee
Cisco Employee
Hi Mesut

You do not have to restart the java-vm. Building and running packages reload is enough (in fact if all you change is java, then a packages package X reload is enough).

Common problems for me is either failing to build or building in a different directory than the one where the packages are loaded.

Hi vleijon

the build is not failing (make returns no error).

Is the default directory not correct? I created the vlan-directory with default skeleton command.
I assumed this directory is the one, where the package is loaded - if it woul