[Yahoo-eng-team] [Bug 1433765] Re: FileField need clean up temp file and and get file size without loading file

2015-12-01 Thread zhaoyim
Din NOT get any response, so mark to invalid. Anyone think it is not
right, please change the status and give some comments. Thanks!

** Changed in: horizon
   Status: New => Invalid

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1433765

Title:
  FileField need clean up temp file and and get file size without
  loading file

Status in OpenStack Dashboard (Horizon):
  Invalid

Bug description:
  
  We are using forms.FileField to upload a client local file. 

  We noticed that if the file size is big, for example 7 gb,  Horizon
  dumps a temp file in /tmp dir where horizon server runs. If the file
  loaded is different each time, the temp files are left in the /tmp.
  Over the long run, it could overflow the disk spaces.

  We would like to have a way to clean up the tmp file once file loading
  is done.

  The way that we use to get the file handle  in the form's clean or
  handle method is :

  f = self.request.FILES['file"]

  If we use this to get the file size in the clean method to validate,
  the whole file gets loaded either into memory or to temp dir,  it
  would be nice to get the file size without loading the whole file.

To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1433765/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1456871] Re: objects.InstanceList.get_all(context, ['metadata', 'system_metadata']) return error can't locate strategy for %s %s % (cls, key)

2015-06-11 Thread zhaoyim
@Sylvain Bauza Sorry! please ignore the trace. I updated the issue
description and the problem should belong to nova component. Please have
a look. Thanks a lot!

** Changed in: nova
   Status: Invalid = New

** Description changed:

- In our code we invoke the code as following:
+ When invoke
  
  objects.InstanceList.get_all(context, ['metadata','system_metadata'])
  
- It throw the error said:
- 2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager 
strat = self._get_strategy(loader.strategy)
- 2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager   File 
/usr/lib64/python2.7/site-packages/sqlalchemy/orm/interfaces.py, line 452, in 
_get_strategy
- 2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager 
cls = self._strategy_lookup(*key)
- 2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager   File 
/usr/lib64/python2.7/site-packages/sqlalchemy/orm/interfaces.py, line 507, in 
_strategy_lookup
- 2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager 
raise Exception(can't locate strategy for %s %s % (cls, key))
- 2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager 
Exception: can't locate strategy for class 
'sqlalchemy.orm.properties.ColumnProperty' (('lazy', 'joined'),)
- 2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager
  
- The original used: db.instance_get_all(context,
- ['metadata','system_metadata'])  can worked well.
- 
- Did some investigation and found the nova/objects/instance.py  function
- _expected_cols(expected_attrs):
+ Then found the nova/objects/instance.py  function  
_expected_cols(expected_attrs):
  
  will return list ['metadata','system_metadata', 'extra',
  'extra.flavor'], then in the db query it throw the error: can't locate
  strategy for class 'sqlalchemy.orm.properties.ColumnProperty'
  (('lazy', 'joined'),)
  
  Could anyone can help have a look? Thanks!

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1456871

Title:
  objects.InstanceList.get_all(context, ['metadata','system_metadata'])
  return error can't locate strategy for %s %s % (cls, key)

Status in OpenStack Compute (Nova):
  New

Bug description:
  When invoke

  objects.InstanceList.get_all(context, ['metadata','system_metadata'])

  
  Then found the nova/objects/instance.py  function  
_expected_cols(expected_attrs):

  will return list ['metadata','system_metadata', 'extra',
  'extra.flavor'], then in the db query it throw the error: can't locate
  strategy for class 'sqlalchemy.orm.properties.ColumnProperty'
  (('lazy', 'joined'),)

  Could anyone can help have a look? Thanks!

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1456871/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1456871] Re: objects.InstanceList.get_all(context, ['metadata', 'system_metadata']) return error can't locate strategy for %s %s % (cls, key)

2015-05-19 Thread zhaoyim
** Project changed: nova-solver-scheduler = nova

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1456871

Title:
  objects.InstanceList.get_all(context, ['metadata','system_metadata'])
  return error can't locate strategy for %s %s % (cls, key)

Status in OpenStack Compute (Nova):
  New

Bug description:
  In our code we invoke the code as following:

  objects.InstanceList.get_all(context, ['metadata','system_metadata'])

  It throw the error said:
  2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager 
strat = self._get_strategy(loader.strategy)
  2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager   File 
/usr/lib64/python2.7/site-packages/sqlalchemy/orm/interfaces.py, line 452, in 
_get_strategy
  2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager 
cls = self._strategy_lookup(*key)
  2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager   File 
/usr/lib64/python2.7/site-packages/sqlalchemy/orm/interfaces.py, line 507, in 
_strategy_lookup
  2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager 
raise Exception(can't locate strategy for %s %s % (cls, key))
  2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager 
Exception: can't locate strategy for class 
'sqlalchemy.orm.properties.ColumnProperty' (('lazy', 'joined'),)
  2015-05-19 21:52:31.222 22676 TRACE nova.scheduler.ibm.ego.ego_manager

  The original used: db.instance_get_all(context,
  ['metadata','system_metadata'])  can worked well.

  Did some investigation and found the nova/objects/instance.py
  function  _expected_cols(expected_attrs):

  will return list ['metadata','system_metadata', 'extra',
  'extra.flavor'], then in the db query it throw the error: can't locate
  strategy for class 'sqlalchemy.orm.properties.ColumnProperty'
  (('lazy', 'joined'),)

  Could anyone can help have a look? Thanks!

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1456871/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp