diff --git a/xos/admin.py b/xos/admin.py
index 829f7f1..d6745eb 100644
--- a/xos/admin.py
+++ b/xos/admin.py
@@ -57,7 +57,7 @@
         )
 
     def get_queryset(self, request):
-        return ExampleService.get_service_objects_by_user(request.user)
+        return ExampleService.select_by_user(request.user)
 
 admin.site.register(ExampleService, ExampleServiceAdmin)
 
@@ -75,7 +75,7 @@
         self.fields['kind'].widget.attrs['readonly'] = True
         self.fields['kind'].initial = SERVICE_NAME
 
-        self.fields['provider_service'].queryset = ExampleService.get_service_objects().all()
+        self.fields['provider_service'].queryset = ExampleService.objects.all()
 
         if self.instance:
             self.fields['creator'].initial = self.instance.creator
@@ -83,8 +83,8 @@
 
         if (not self.instance) or (not self.instance.pk):
             self.fields['creator'].initial = get_request().user
-            if ExampleService.get_service_objects().exists():
-                self.fields['provider_service'].initial = ExampleService.get_service_objects().all()[0]
+            if ExampleService.objects.exists():
+                self.fields['provider_service'].initial = ExampleService.objects.all()[0]
 
     def save(self, commit=True):
         self.instance.creator = self.cleaned_data.get('creator')
@@ -112,7 +112,7 @@
     suit_form_tabs = (('general', 'Details'),)
 
     def get_queryset(self, request):
-        return ExampleTenant.get_tenant_objects_by_user(request.user)
+        return ExampleTenant.select_by_user(request.user)
 
 admin.site.register(ExampleTenant, ExampleTenantAdmin)
 
diff --git a/xos/api/service/exampleservice.py b/xos/api/service/exampleservice.py
index d8fe23a..467a4bd 100644
--- a/xos/api/service/exampleservice.py
+++ b/xos/api/service/exampleservice.py
@@ -36,7 +36,7 @@
     base_name = "exampleservice"
     method_name = "exampleservice"
     method_kind = "viewset"
-    queryset = ExampleService.get_service_objects().all()
+    queryset = ExampleService.objects.all()
     serializer_class = ExampleServiceSerializer
 
     @classmethod
diff --git a/xos/api/tenant/exampletenant.py b/xos/api/tenant/exampletenant.py
index f4778cc..386a77e 100644
--- a/xos/api/tenant/exampletenant.py
+++ b/xos/api/tenant/exampletenant.py
@@ -12,14 +12,14 @@
 from services.exampleservice.models import ExampleTenant, ExampleService
 
 def get_default_example_service():
-    example_services = ExampleService.get_service_objects().all()
+    example_services = ExampleService.objects.all()
     if example_services:
         return example_services[0]
     return None
 
 class ExampleTenantSerializer(PlusModelSerializer):
         id = ReadOnlyField()
-        provider_service = serializers.PrimaryKeyRelatedField(queryset=ExampleService.get_service_objects().all(), default=get_default_example_service)
+        provider_service = serializers.PrimaryKeyRelatedField(queryset=ExampleService.objects.all(), default=get_default_example_service)
         tenant_message = serializers.CharField(required=False)
         backend_status = ReadOnlyField()
 
@@ -36,7 +36,7 @@
     base_name = "exampletenant"
     method_name = "exampletenant"
     method_kind = "viewset"
-    queryset = ExampleTenant.get_tenant_objects().all()
+    queryset = ExampleTenant.objects.all()
     serializer_class = ExampleTenantSerializer
 
     @classmethod
diff --git a/xos/attic/exampletenant_model.py b/xos/attic/exampletenant_model.py
index ad69d03..9eb1f86 100644
--- a/xos/attic/exampletenant_model.py
+++ b/xos/attic/exampletenant_model.py
@@ -1,5 +1,5 @@
 def __init__(self, *args, **kwargs):
-    exampleservice = ExampleService.get_service_objects().all()
+    exampleservice = ExampleService.objects.all()
     if exampleservice:
         self._meta.get_field('provider_service').default = exampleservice[0].id
     super(ExampleTenant, self).__init__(*args, **kwargs)
diff --git a/xos/tosca/resources/exampletenant.py b/xos/tosca/resources/exampletenant.py
index d4e4683..2675189 100644
--- a/xos/tosca/resources/exampletenant.py
+++ b/xos/tosca/resources/exampletenant.py
@@ -20,7 +20,7 @@
 
     def get_existing_objs(self):
         args = self.get_xos_args(throw_exception=False)
-        return ExampleTenant.get_tenant_objects().filter(provider_service=args["provider_service"], service_specific_id=args["service_specific_id"])
+        return ExampleTenant.objects.filter(provider_service=args["provider_service"], service_specific_id=args["service_specific_id"])
         return []
 
     def can_delete(self, obj):
