Examples of AccessResult


Examples of org.apache.helix.manager.zk.ZkBaseDataAccessor.AccessResult

    String path = String.format("/%s/%s/%s", testName, "msg_0", "submsg_0");
    ZNRecord record = new ZNRecord("submsg_0");
    ZkBaseDataAccessor<ZNRecord> accessor = new ZkBaseDataAccessor<ZNRecord>(_gZkClient);

    AccessResult result = accessor.doSet(path, record, -1, AccessOption.PERSISTENT);
    Assert.assertEquals(result._retCode, RetCode.OK);
    Assert.assertEquals(result._pathCreated.size(), 3);
    Assert.assertTrue(result._pathCreated.contains(String.format("/%s", testName)));
    Assert.assertTrue(result._pathCreated.contains(String.format("/%s/%s", testName, "msg_0")));
    Assert.assertTrue(result._pathCreated.contains(path));
View Full Code Here

Examples of org.apache.helix.manager.zk.ZkBaseDataAccessor.AccessResult

    String path = String.format("/%s/%s/%s", testName, "msg_0", "submsg_0");
    ZNRecord record = new ZNRecord("submsg_0");
    ZkBaseDataAccessor<ZNRecord> accessor = new ZkBaseDataAccessor<ZNRecord>(_zkclient);

    AccessResult result = accessor.doSet(path, record, -1, AccessOption.PERSISTENT);
    Assert.assertEquals(result._retCode, RetCode.OK);
    Assert.assertEquals(result._pathCreated.size(), 3);
    Assert.assertTrue(result._pathCreated.contains(String.format("/%s", testName)));
    Assert.assertTrue(result._pathCreated.contains(String.format("/%s/%s", testName, "msg_0")));
    Assert.assertTrue(result._pathCreated.contains(path));
View Full Code Here

Examples of org.apache.helix.manager.zk.ZkBaseDataAccessor.AccessResult

    String path = String.format("/%s/%s/%s", testName, "msg_0", "submsg_0");
    ZNRecord record = new ZNRecord("submsg_0");
    ZkBaseDataAccessor<ZNRecord> accessor = new ZkBaseDataAccessor<ZNRecord>(_gZkClient);

    AccessResult result = accessor.doSet(path, record, -1, AccessOption.PERSISTENT);
    Assert.assertEquals(result._retCode, RetCode.OK);
    Assert.assertEquals(result._pathCreated.size(), 3);
    Assert.assertTrue(result._pathCreated.contains(String.format("/%s", testName)));
    Assert.assertTrue(result._pathCreated.contains(String.format("/%s/%s", testName, "msg_0")));
    Assert.assertTrue(result._pathCreated.contains(path));
View Full Code Here

Examples of org.apache.qpid.server.security.access.AccessResult

        }
        else
        {
            session.setVirtualHost(virtualHost);

            AccessResult result = virtualHost.getAccessManager().isAuthorized(virtualHost, session.getAuthorizedID(), AccessRights.Rights.ANY);

            switch (result.getStatus())
            {
                default:
                case REFUSED:
                    String error = "Any access denied to vHost '" + virtualHostName + "' by "
                                   + result.getAuthorizer();
                   
                    _logger.warn(error);

                    throw body.getConnectionException(AMQConstant.ACCESS_REFUSED, error);
                case GRANTED:
                    _logger.info("Granted any access to vHost '" + virtualHostName + "' for " + session.getAuthorizedID()
                                 + " by '" + result.getAuthorizer() + "'");
            }

            // See Spec (0.8.2). Section  3.1.2 Virtual Hosts
            if (session.getContextKey() == null)
            {
View Full Code Here

Examples of org.apache.qpid.server.security.access.AccessResult

            {
                for (String host : hosts)
                {
                    if (accessObject.getAccessableName().equals(host))
                    {
                        return new AccessResult(this, AccessResult.AccessStatus.GRANTED);
                    }
                }
            }
        }

        return new AccessResult(this, AccessResult.AccessStatus.REFUSED);
    }
View Full Code Here

Examples of org.apache.qpid.server.security.access.AccessResult

            ACLManager.getLogger().debug("Allowing user:" + session.getAuthorizedID() + " for :" + permission.toString()
                                        + " on " + body.getClass().getSimpleName()
                                        + (parameters == null || parameters.length == 0 ? "" : "-" + accessablesToString(parameters)));
        }

        return new AccessResult(this, AccessResult.AccessStatus.GRANTED);
    }
View Full Code Here

Examples of org.codelibs.robot.entity.AccessResult

        final String sessionId = urlQueue.getSessionId();
        if (super.exists(sessionId, url)) {
            return true;
        }

        final AccessResult accessResult = dataService.getAccessResult(
                sessionId, url);
        if (accessResult != null) {
            return true;
        }
View Full Code Here

Examples of org.codelibs.robot.entity.AccessResult

                .setQuery(QueryBuilders.matchAllQuery()).setSize(scrollSize)
                .execute().actionGet();
        while (true) {
            final SearchHits searchHits = response.getHits();
            for (final SearchHit searchHit : searchHits) {
                final AccessResult accessResult = Beans
                        .createAndCopy(EsAccessResult.class,
                                searchHit.getSource())
                        .converter(new EsTimestampConverter(), timestampFields)
                        .excludesWhitespace().execute();
                callback.iterate(accessResult);
View Full Code Here

Examples of org.hxzon.asn1.mms.choice.AccessResult

            }
        }
    }

    private BerNode getAccessResult_Success_RealNode(BerSequenceOf seqOf, int i) {
        AccessResult accessResult = (AccessResult) seqOf.getChildren()[i];
        BerNode result = accessResult.getChildren()[0];
        if (result instanceof Data) {
            return ((Data) result).getChildren()[0];
        }
        return null;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.