SimpleScheduler & SqlAlchemy changes not being applied

Asked by Alejandro Comisario

Hey guys, we are making some changes on the "nova\db\sqlalchemy\api.py" and added a function to make a query to sort hosts by free ram.

After that, we modified '"nova\scheduler\simple.py" to call out brand new function, instead of the old one "service_get_all_compute_sorted" changed for "service_get_all_compute_sorted_MB"

We also added some LOGS to the nova.scheduler.manager to log the new calls, but when we restart :

CONTROLLER:
  nova-network , nova-scheduler, nova-api
COMPUTES:
  libvirt-bin , nova-compute

I dont see, not only the logs, but any attempt to call out new functions, we also tried to delete all the *.pyc from the libs directory.

So, what are we missing ???

Question information

Language:
English Edit question
Status:
Solved
For:
OpenStack Compute (nova) Edit question
Assignee:
No assignee Edit question
Solved by:
Everett Toews
Solved:
Last query:
Last reply:
Revision history for this message
Best Everett Toews (everett-toews) said :
#1

Don't forget to add your new functions to nova/db/api.py as well.

Everett

On Tue, Dec 13, 2011 at 1:25 PM, Alejandro Comisario <
<email address hidden>> wrote:

> New question #181803 on OpenStack Compute (nova):
> https://answers.launchpad.net/nova/+question/181803
>
> Hey guys, we are making some changes on the "nova\db\sqlalchemy\api.py"
> and added a function to make a query to sort hosts by free ram.
>
> After that, we modified '"nova\scheduler\simple.py" to call out brand new
> function, instead of the old one "service_get_all_compute_sorted" changed
> for "service_get_all_compute_sorted_MB"
>
> We also added some LOGS to the nova.scheduler.manager to log the new
> calls, but when we restart :
>
> CONTROLLER:
> nova-network , nova-scheduler, nova-api
> COMPUTES:
> libvirt-bin , nova-compute
>
> I dont see, not only the logs, but any attempt to call out new functions,
> we also tried to delete all the *.pyc from the libs directory.
>
> So, what are we missing ???
>
> --
> You received this question notification because you are an answer
> contact for OpenStack Compute (nova).
>

Revision history for this message
Alejandro Comisario (alejandro-comisario) said :
#2

Hmmmm, i think you are right.
We'll try that and see if it works !

I'll let you know.

Revision history for this message
Alejandro Comisario (alejandro-comisario) said :
#3

Thanks Everett Toews, that solved my question.