コード例 #1
0
ファイル: service.py プロジェクト: imandhan/trove
    def show(self, req, tenant_id, id):
        """Return a single instance."""
        LOG.info(_LI("Showing database instance '%(instance_id)s' for tenant "
                     "'%(tenant_id)s'"),
                 {'instance_id': id, 'tenant_id': tenant_id})
        LOG.debug("req : '%s'\n\n", req)

        context = req.environ[wsgi.CONTEXT_KEY]
        server = models.load_instance_with_info(models.DetailInstance,
                                                context, id)
        return wsgi.Result(views.InstanceDetailView(server,
                                                    req=req).data(), 200)
コード例 #2
0
ファイル: service.py プロジェクト: Hopebaytech/trove
    def show(self, req, tenant_id, id):
        """Return a single instance."""
        LOG.info(_LI("Showing database instance '%(instance_id)s' for tenant "
                     "'%(tenant_id)s'"),
                 {'instance_id': id, 'tenant_id': tenant_id})
        LOG.debug("req : '%s'\n\n", req)

        context = req.environ[wsgi.CONTEXT_KEY]
        server = models.load_instance_with_info(models.DetailInstance,
                                                context, id)
        return wsgi.Result(views.InstanceDetailView(server,
                                                    req=req).data(), 200)
コード例 #3
0
 def load_instance(context, cluster_id, instance_id):
     return inst_models.load_instance_with_info(
         inst_models.DetailInstance, context, instance_id, cluster_id)
コード例 #4
0
ファイル: models.py プロジェクト: Tesora-Release/tesora-trove
 def load_instance(context, cluster_id, instance_id):
     return inst_models.load_instance_with_info(
         inst_models.DetailInstance, context, instance_id, cluster_id)