Modify gvnfm vnfres code according to PEP8 61/12061/1
authorying.yunlong <ying.yunlong@zte.com.cn>
Wed, 13 Sep 2017 01:12:44 +0000 (09:12 +0800)
committerying.yunlong <ying.yunlong@zte.com.cn>
Wed, 13 Sep 2017 01:12:44 +0000 (09:12 +0800)
Change-Id: Ifb0779e25aa27cca634324603e8e5a6d130adacc
Issue-ID: VFC-344
Signed-off-by: ying.yunlong <ying.yunlong@zte.com.cn>
19 files changed:
res/README.md
res/assembly.xml
res/assembly/bin/initDB.sh
res/assembly/dbscripts/mysql/onap-gvnfm-vnfres-createdb.sql
res/assembly/dbscripts/mysql/onap-gvnfm-vnfres-createobj.sql
res/docker/LICENSE
res/docker/instance_run.sh
res/initialize.sh
res/manage.py
res/pom.xml
res/res/pub/config/config.py
res/res/pub/database/models.py
res/res/resources/tests.py
res/res/resources/urls.py
res/res/resources/views.py
res/res/settings.py
res/res/urls.py
res/run.sh
res/stop.sh

index 28f16fe..ec4a35a 100644 (file)
@@ -12,4 +12,5 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 See the License for the specific language governing permissions and
 limitations under the License.
 
+
 Micro service of vnf resource management.
index b85e1d5..1e87a78 100644 (file)
@@ -13,6 +13,8 @@
     See the License for the specific language governing permissions and
     limitations under the License.
 -->
+
+
 <assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0" 
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
   xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
index 1ed4863..5ad52f5 100755 (executable)
@@ -13,7 +13,7 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
-#
+
 
 DIRNAME=`dirname $0`
 HOME=`cd $DIRNAME/; pwd`
@@ -47,4 +47,3 @@ do
 done
 echo "init resource management database success!"
 exit 0
-
index 32d2450..941ad16 100644 (file)
@@ -12,7 +12,6 @@
 -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 -- See the License for the specific language governing permissions and
 -- limitations under the License.
---
 
 
 /******************drop old database and user***************************/
@@ -29,4 +28,4 @@ GRANT ALL PRIVILEGES ON mysql.* TO 'gvnfm'@'%' IDENTIFIED BY 'gvnfm' WITH GRANT
 
 GRANT ALL PRIVILEGES ON gvnfm.* TO 'gvnfm'@'localhost' IDENTIFIED BY 'gvnfm' WITH GRANT OPTION;
 GRANT ALL PRIVILEGES ON mysql.* TO 'gvnfm'@'localhost' IDENTIFIED BY 'gvnfm' WITH GRANT OPTION;
-FLUSH PRIVILEGES; 
\ No newline at end of file
+FLUSH PRIVILEGES;
index 86a2010..1facf38 100644 (file)
@@ -12,7 +12,7 @@
 -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 -- See the License for the specific language governing permissions and
 -- limitations under the License.
---
+
 
 use gvnfm;
 
index 5c767c3..dd08487 100644 (file)
@@ -470,4 +470,4 @@ understandings, or agreements concerning use of licensed material. For
 the avoidance of doubt, this paragraph does not form part of the
 public licenses.
 
-Creative Commons may be contacted at creativecommons.org.
\ No newline at end of file
+Creative Commons may be contacted at creativecommons.org.
index 196edfd..8aac538 100755 (executable)
@@ -7,4 +7,4 @@ chmod +x run.sh
 while [ ! -f logs/runtime_res.log ]; do
     sleep 1
 done
-tail -F logs/runtime_res.log
\ No newline at end of file
+tail -F logs/runtime_res.log
index 7ace382..1bde84f 100755 (executable)
@@ -12,4 +12,6 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+
+
 pip install -r requirements.txt
index 790d22b..a9dc4bf 100644 (file)
@@ -12,6 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+
 import os
 import sys
 
index 5ce8ae5..03b99d4 100644 (file)
@@ -14,6 +14,8 @@
     See the License for the specific language governing permissions and
     limitations under the License.11
 -->
+
+
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
     <parent>
         <groupId>org.onap.vfc.gvnfm.vnfres</groupId>
index 86701be..6c06553 100644 (file)
@@ -11,6 +11,8 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+
+
 import os
 
 # [MSB]
index c701e20..af794b7 100644 (file)
@@ -11,6 +11,8 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+
+
 from django.db import models
 
 
@@ -311,8 +313,3 @@ class FlavourInstModel(models.Model):
 
     def __unicode__(self):
         return '%s' % self.name
-
-
-
-
-
index 4bddc71..7211b81 100644 (file)
@@ -11,6 +11,8 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+
+
 from django.test import TestCase, Client
 from rest_framework import status
 
@@ -212,4 +214,4 @@ class ResourceTest(TestCase):
 
     def test_swagger_ok(self):
         resp = self.client.get("/api/vnfres/v1/swagger.json", format='json')
-        self.assertEqual(resp.status_code, status.HTTP_200_OK, resp.content)
\ No newline at end of file
+        self.assertEqual(resp.status_code, status.HTTP_200_OK, resp.content)
index b855a60..5920115 100644 (file)
@@ -12,6 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+
 from django.conf.urls import url
 from rest_framework.urlpatterns import format_suffix_patterns
 
index 38de8e1..8171c5c 100644 (file)
@@ -11,6 +11,8 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+
+
 import json
 import logging
 import os
@@ -340,6 +342,7 @@ def fill_cps_data(cp):
     }
     return cps_data
 
+
 @api_view(http_method_names=['GET'])
 def get_volumes(request, *args, **kwargs):
     logger.debug("Query all the volumes by vnfInstanceId[%s]", fun_name())
@@ -376,4 +379,4 @@ class SwaggerJsonView(APIView):
         f = open(json_file)
         json_data = json.JSONDecoder().decode(f.read())
         f.close()
-        return Response(json_data)
\ No newline at end of file
+        return Response(json_data)
index 6b19ab5..e7de314 100644 (file)
@@ -12,6 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+
 import os
 import sys
 
index 9db7895..29cdac7 100644 (file)
@@ -12,6 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
+
 from django.conf.urls import include, url
 from res.pub.config.config import REG_TO_MSB_WHEN_START, REG_TO_MSB_REG_URL, REG_TO_MSB_REG_PARAM
 
index d2ebe3c..14c51d3 100755 (executable)
@@ -12,4 +12,6 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+
+
 nohup python manage.py runserver 127.0.0.1:8802 > /dev/null &
index af83565..2b65ea8 100755 (executable)
@@ -12,4 +12,6 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
+
+
 ps auxww | grep 'manage.py runserver 127.0.0.1:8802' | awk '{print $2}' | xargs kill -9