id
stringlengths
17
20
content
stringlengths
45
12.2k
max_stars_repo_path
stringlengths
55
167
logbench-o_data_101
@Override public WebSocketEntrypointConnector createConnector(final DeploymentContext deploymentContext, final Qos qos, final String configuration) { try { return new WebSocketEntrypointConnector(qos, pluginConfigurationHelper.readConfiguration(WebSocketEntrypointConnectorConfiguration.class, configuration)...
LogBench/LogBench-O_prefix_1point/gravitee-api-management_WebSocketEntrypointConnectorFactory_createConnector.java
logbench-o_data_102
@Bean @ConditionalOnToxiProxyEnabled(module = "mongodb") ToxiproxyContainer.ContainerProxy mongodbContainerProxy(ToxiproxyContainer toxiproxyContainer, @Qualifier(BEAN_NAME_EMBEDDED_MONGODB) GenericContainer<?> mongodb, MongodbProperties properties, ConfigurableEnvironment environment) { ToxiproxyContainer.Containe...
LogBench/LogBench-O_prefix_1point/testcontainers-spring-boot_EmbeddedMongodbBootstrapConfiguration_mongodbContainerProxy.java
logbench-o_data_103
@WriteOperation public WebEndpointResponse<TogglzFeature> setFeatureState(@Selector String name, @Nullable Boolean enabled, @Nullable String strategy, @Nullable String parameters) { Feature feature = findFeature(name); if (feature == null) { return new WebEndpointResponse<>(WebEndpointResponse.STATUS_NO...
LogBench/LogBench-O_prefix_1point/togglz_TogglzEndpointWebExtension_setFeatureState.java
logbench-o_data_104
public JsonWebResponse createLogoutToken(Client rpClient, String outsideSid, User user) { try { Preconditions.checkNotNull(rpClient); JsonWebResponse jwr = jwrService.createJwr(rpClient); fillClaims(jwr, rpClient, outsideSid, user); jwrService.encode(jwr, rpClient); return jw...
LogBench/LogBench-O_prefix_1point/oxauth_LogoutTokenFactory_createLogoutToken.java
logbench-o_data_105
@Override @SuppressWarnings("unchecked") public OperationResult<Map<TokenOperationResultKey, Object>> perform() { LOG.info(this.matchingProductAdapters.size() + " matching product adapters"); if (!this.matchingProductAdapters.isEmpty()) { return this.createTokenAuto(); } else { boolean advanced...
LogBench/LogBench-O_prefix_1point/nexu_CreateTokenOperation_perform.java
logbench-o_data_106
protected void stopBroker() { // we can no longer keep the lock so lets fail LOG.error("{}, no longer able to keep the exclusive lock so giving up being a master", brokerService.getBrokerName()); try { if (brokerService.isRestartAllowed()) { brokerService.requestRestart(); } ...
LogBench/LogBench-O_prefix_1point/activemq_LockableServiceSupport_stopBroker.java
logbench-o_data_107
@CheckForNull public static Repository getRepositoryForDir(Path projectDir) { try { var builder = new RepositoryBuilder().findGitDir(projectDir.toFile()).setMustExist(true); if (builder.getGitDir() == null) { LOG.error("Not inside a Git work tree: " + projectDir); return null; }...
LogBench/LogBench-O_prefix_1point/sonarlint-core_GitUtils_getRepositoryForDir.java
logbench-o_data_108
private void collectDataAndReport() { if (log.isDebugEnabled()) { log.trace("Starting new mediation statistics collection cycle"); } CompletedStructureStore completedStructureStore = synapseEnvironmentService.getSynapseEnvironment().getSynapseConfiguration().getCompletedStructureStore(); if (completedS...
LogBench/LogBench-O_prefix_1point/micro-integrator_MediationConfigReporterThread_collectDataAndReport.java
logbench-o_data_109
@Override public void onException(Message message, Exception exception) { log.error("send completed with error", exception); res.completeExceptionally(exception); }
LogBench/LogBench-O_prefix_1point/benchmark_JMSBenchmarkProducer_onException.java
logbench-o_data_110
public boolean handleLoggingResource(final HttpServerRequest request) { if (request.uri().equals(loggingUri) && HttpMethod.PUT == request.method()) { request.bodyHandler(loggingResourceBuffer -> { try { extractLoggingFilterValues(loggingResourceBuffer); } catch (Valid...
LogBench/LogBench-O_prefix_1point/gateleen_LoggingResourceManager_handleLoggingResource.java
logbench-o_data_111
@Override public void updateEntitlement(String name, Entitlement entitlement) { Query query = em.createQuery("select e from Entitlement e where e.name=:name"); query.setParameter("name", name); EntitlementEntity entitlementEntity = (EntitlementEntity) query.getSingleResult(); domain2entity(entitlement, ...
LogBench/LogBench-O_prefix_1point/cxf-fediz_EntitlementDAOJPAImpl_updateEntitlement.java
logbench-o_data_112
public boolean isInDTX() { TransactionManager txManager = getTransactionManager(); if (txManager == null) { return false; } try { return txManager.getStatus() != Status.STATUS_NO_TRANSACTION; } catch (Exception e) { log.error("Error at 'hasNoActiveTransaction'", e); return f...
LogBench/LogBench-O_prefix_1point/micro-integrator_DSSXATransactionManager_isInDTX.java
logbench-o_data_113
@Override public byte[] transform(ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer) throws IllegalClassFormatException { DriverManagerType driverManagerType = null; switch(className) { case "org/openqa/selenium/chrome/ChromeDri...
LogBench/LogBench-O_prefix_1point/webdrivermanager_WdmAgent_transform.java
logbench-o_data_114
public void doStop() throws Exception { try { stopConfiguration(); } catch (Exception e) { log.error("Exception while stopping configuration [" + artifact + "] on [" + nodeName + "].", e); throw e; } }
LogBench/LogBench-O_prefix_1point/geronimo_BasicClusterConfigurationController_doStop.java
logbench-o_data_115
@Override public boolean logout() throws LoginException { subject.getPrincipals().removeAll(principals); clear(); if (debug) { LOG.debug("logout"); } succeeded = false; commitSucceeded = false; return true; }
LogBench/LogBench-O_prefix_1point/activemq_PropertiesLoginModule_logout.java
logbench-o_data_116
public boolean processMTLS(HttpServletRequest httpRequest, HttpServletResponse httpResponse, FilterChain filterChain, Client client) throws Exception { log.debug("Trying to authenticate client {} via {} ...", client.getClientId(), client.getAuthenticationMethod()); final String clientCertAsPem = httpRequest.getHea...
LogBench/LogBench-O_prefix_1point/oxauth_MTLSService_processMTLS.java
logbench-o_data_117
public SessionId getConnectSession(HttpServletRequest httpRequest) { String cookieId = cookieService.getSessionIdFromCookie(httpRequest); log.trace("Cookie - session_id: " + cookieId); if (StringUtils.isNotBlank(cookieId)) { return sessionIdService.getSessionId(cookieId); } return null; }
LogBench/LogBench-O_prefix_1point/oxauth_UmaSessionService_getConnectSession.java
logbench-o_data_118
@Override public boolean commit() throws LoginException { if (!succeeded) { clear(); if (debug) { LOG.debug("commit, result: false"); } return false; } principals.add(new UserPrincipal(user)); Set<String> matchedGroups = groups.get(user); if (matchedGroups != null) {...
LogBench/LogBench-O_prefix_1point/activemq_PropertiesLoginModule_commit.java
logbench-o_data_119
@Override public void run() { try { while (totalConsumed.get() < NUM_MESSAGES) { Message message = workQueue.take(); message.acknowledge(); totalConsumed.incrementAndGet(); if ((totalConsumed.get() % 100) == 0) { LOG.info("Consumed " + totalConsumed.get() + "...
LogBench/LogBench-O_prefix_1point/activemq_AMQ3732Test_run.java
logbench-o_data_120
protected void reloadConfiguration() throws Exception { if (zk_client == null) { LOG.debug("Connecting to ZooKeeper"); try { zkConnect(); LOG.debug("Connected to ZooKeeper"); } catch (Exception e) { LOG.debug("Connection to ZooKeeper failed: " + e); z...
LogBench/LogBench-O_prefix_1point/activemq_ZooKeeperPartitionBroker_reloadConfiguration.java
logbench-o_data_121
@SuppressWarnings({ "rawtypes", "unchecked" }) public String getAsText() { Map map = (Map) getValue(); if (!(map instanceof Properties)) { Properties p = new Properties(); if (map != null) { if (!map.containsKey(null) && !map.containsValue(null)) { p.putAll(map); ...
LogBench/LogBench-O_prefix_1point/geronimo_MapEditor_getAsText.java
logbench-o_data_122
/** * {@inheritDoc} */ @Override public ITagReader getReader() throws IOException { MP4Reader reader = null; IoBuffer fileData = null; String fileName = file.getName(); if (file.exists()) { log.debug("File name: {} size: {}", fileName, file.length()); reader = new MP4Reader(file); // ...
LogBench/LogBench-O_prefix_1point/red5-server_MP4_getReader.java
logbench-o_data_123
/** * {@inheritDoc} * * @see jcifs.smb.DirFileEntryEnumIteratorBase#fetchMore() */ @SuppressWarnings("resource") @Override protected boolean fetchMore() throws CIFSException { FileEntry[] results = this.response.getResults(); SmbTreeHandleImpl th = getTreeHandle(); Smb2QueryDirectoryRequest query = new ...
LogBench/LogBench-O_prefix_1point/jcifs-ng_DirFileEntryEnumIterator2_fetchMore.java
logbench-o_data_124
private StreamingReadVisitor buildVisitor(FieldReferenceOffsetManager from) { return new StreamingReadVisitor() { StringBuilder temp = new StringBuilder(); @Override public boolean paused() { return false; } // TODO: B, for each field type need to confirm them ...
LogBench/LogBench-O_prefix_1point/pronghorn_FuzzValidationStage_buildVisitor.java
logbench-o_data_125
public synchronized void onMessage(Message message) { try { Destination dest = message.getJMSDestination(); List messages = null; if (!messagesMap.containsKey(dest)) { register((Topic) dest); } messages = (List) messagesMap.get(dest); if (!messages.contain...
LogBench/LogBench-O_prefix_1point/geronimo_ViewMessagesRenderer_onMessage.java
logbench-o_data_126
Session getSession() { if (sessionType == SessionType.client) { return XMPPServer.getInstance().getRoutingTable().getClientRoute(address); } else if (sessionType == SessionType.component) { return SessionManager.getInstance().getComponentSession(address.getDomain()); } else if (sessionType =...
LogBench/LogBench-O_prefix_1point/openfire_ProcessPacketTask_getSession.java
logbench-o_data_127
public void testVerifySessionCloseRedeliveryWithFailoverTransport() throws Throwable { Session session = connection.createSession(true, Session.SESSION_TRANSACTED); MessageConsumer consumer = session.createConsumer(destination); Message message = consumer.receive(1000); String id = message.getJMSMessage...
LogBench/LogBench-O_prefix_1point/activemq_CloseRollbackRedeliveryQueueTest_testVerifySessionCloseRedeliveryWithFailoverTransport.java
logbench-o_data_128
@Override @Logging(clearState = true) public Object handleRequest(Object input, Context context) { if (COUNT == 1) { LoggingUtils.appendKey("TestKey", "TestValue"); } LOG.info("Test event"); COUNT++; return null; }
LogBench/LogBench-O_prefix_1point/aws-lambda-powertools-java_PowerLogToolEnabledWithClearState_handleRequest.java
logbench-o_data_129
protected ObjectName assertRegisteredObjectName(String name) throws MalformedObjectNameException, NullPointerException { ObjectName objectName = new ObjectName(name); if (mbeanServer.isRegistered(objectName)) { LOG.info("Bean Registered: " + objectName); } else { fail("Could not find MBean!: " + ob...
LogBench/LogBench-O_prefix_1point/activemq_Log4JConfigTest_assertRegisteredObjectName.java
logbench-o_data_130
@Override protected void setUp() throws Exception { sendFactory = createSenderConnectionFactory(); receiveFactory = createReceiverConnectionFactory(); // Give server enough time to setup, // so we don't lose messages when connection fails LOG.info("Waiting for brokers Initialize."); Thread.sleep(50...
LogBench/LogBench-O_prefix_1point/activemq_TwoBrokerTopicSendReceiveTest_setUp.java
logbench-o_data_131
@Override public <T> List<T> getServices(Class<T> serviceType) { if (LOG.isLoggable(Level.FINEST)) { LOG.finest("Loading services: " + serviceType.getName()); } List<ServiceReference<T>> refs = new ArrayList<>(); List<T> services = new ArrayList<>(refs.size()); try { refs.addAll(this.bundle...
LogBench/LogBench-O_prefix_1point/jsr354-ri_OSGIServiceProvider_getServices.java
logbench-o_data_132
/** * {@inheritDoc} * * @see jcifs.internal.smb2.ServerMessageBlock2#writeBytesWireFormat(byte[], int) */ @Override protected int writeBytesWireFormat(byte[] dst, int dstIndex) { int start = dstIndex; SMBUtil.writeInt2(24, dst, dstIndex); SMBUtil.writeInt2(this.closeFlags, dst, dstIndex + 2); dstInd...
LogBench/LogBench-O_prefix_1point/jcifs-ng_Smb2CloseRequest_writeBytesWireFormat.java
logbench-o_data_133
@Override public KafkaEndpointConnector createConnector(final DeploymentContext deploymentContext, final String configuration) { try { return new KafkaEndpointConnector(pluginConfigurationHelper.readConfiguration(KafkaEndpointConnectorConfiguration.class, configuration), qosStrategyFactory); } catch (Pl...
LogBench/LogBench-O_prefix_1point/gravitee-api-management_KafkaEndpointConnectorFactory_createConnector.java
logbench-o_data_134
public static void main(String[] args) throws Exception { String[] xmls = null; if (Configure.RUN_MODE == 1) { xmls = new String[] { "classpath:/applicationContext-mainnet.xml", "classpath:/applicationContext.xml" }; } else if (Configure.RUN_MODE == 2) { xmls = new String[] { "classpath:/app...
LogBench/LogBench-O_prefix_1point/inchain_RegisterAccount_main.java
logbench-o_data_135
public void ioException(IOException e) { if (LOG.isDebugEnabled()) LOG.debug("NullCallback exception", e); }
LogBench/LogBench-O_prefix_1point/ma-core-public_InputStreamEPoll_ioException.java
logbench-o_data_136
/** * Return hostname for URL. * * @param url * URL * @return Hostname from that URL */ @Override protected String getHostname(String url) { log.debug("url: {}", url); String[] parts = url.split("/"); if (parts.length == 2) { return ""; } else { String host = parts[2]; ...
LogBench/LogBench-O_prefix_1point/red5-server_RTMPTHandler_getHostname.java
logbench-o_data_137
public void onMessage(Message message) { if (message instanceof ActiveMQMessage) { ActiveMQMessage activeMessage = (ActiveMQMessage) message; Object command = activeMessage.getDataStructure(); if (command instanceof DestinationInfo) { DestinationInfo destinationInfo = (Destinatio...
LogBench/LogBench-O_prefix_1point/activemq_DestinationSource_onMessage.java
logbench-o_data_138
protected void assertMessagesArrived(final ConsumerBean messageList1, final ConsumerBean messageList2) { try { assertTrue("expected", Wait.waitFor(new Wait.Condition() { @Override public boolean isSatisified() throws Exception { LOG.info("One: " + messageList1.getMessages().size() ...
LogBench/LogBench-O_prefix_1point/activemq_VirtualTopicWildcardTest_assertMessagesArrived.java
logbench-o_data_139
private void ping() throws IOException { if (session != null && session.isOpen()) { session.sendMessage(new TextMessage("{\"type\":\"ping\"}")); } else { log.debug("Cannot ping, websocket session not yet open"); } }
LogBench/LogBench-O_prefix_1point/gateleen_EventBusCollector_ping.java
logbench-o_data_140
@Override public void injectDataFromJson(String p_json) { if (StringUtils.isNotBlank(entity)) { try { JSONObject jsonObj = new JSONObject(entity); if (jsonObj.has(AUTH_REQ_ID)) { setAuthReqId(jsonObj.getString(AUTH_REQ_ID)); } if (jsonObj.has(E...
LogBench/LogBench-O_prefix_1point/oxauth_BackchannelAuthenticationResponse_injectDataFromJson.java
logbench-o_data_141
/** * Test the case where the broker is blocked due to a memory limit * and a producer timeout is set on the connection. * @throws Exception */ public void testBlockedProducerConnectionTimeout() throws Exception { final ActiveMQConnection cx = (ActiveMQConnection) createConnection(); final ActiveMQDestinati...
LogBench/LogBench-O_prefix_1point/activemq_JmsTimeoutTest_testBlockedProducerConnectionTimeout.java
logbench-o_data_142
public void testLoadBalancing() throws Exception { bridgeBrokers("BrokerA", "BrokerB"); bridgeBrokers("BrokerB", "BrokerA"); startAllBrokers(); waitForBridgeFormation(); // Setup destination Destination dest = createDestination("TEST.FOO", false); // Setup consumers MessageConsumer clien...
LogBench/LogBench-O_prefix_1point/activemq_TwoBrokerNetworkLoadBalanceTest_testLoadBalancing.java
logbench-o_data_143
Optional<URL> buildUrl(String driverVersion, Config config) { Optional<URL> optionalUrl = empty(); if (!config.isUseMirror()) { String downloadUrlPattern = config.getChromeDownloadUrlPattern(); OperatingSystem os = config.getOperatingSystem(); Architecture arch = config.getArchitecture()...
LogBench/LogBench-O_prefix_1point/webdrivermanager_ChromeDriverManager_buildUrl.java
logbench-o_data_144
@Override public void delete(final String uri, final Handler<Integer> doneHandler) { client.request(HttpMethod.DELETE, uri).onComplete(asyncResult -> { if (asyncResult.failed()) { log.warn("Failed request to {}: {}", uri, asyncResult.cause()); return; } HttpClientRequest request...
LogBench/LogBench-O_prefix_1point/gateleen_HttpResourceStorage_delete.java
logbench-o_data_145
@Reference(name = "org.wso2.carbon.dataservices.sql.driver", service = org.wso2.micro.integrator.core.services.Axis2ConfigurationContextService.class, cardinality = ReferenceCardinality.MANDATORY, policy = ReferencePolicy.DYNAMIC, unbind = "unsetAxis2ConfigurationContextService") protected void setAxis2ConfigurationCon...
LogBench/LogBench-O_prefix_1point/micro-integrator_SQLDriverDSComponent_setAxis2ConfigurationContextService.java
logbench-o_data_146
@Override public void deliver(Packet packet) throws UnauthorizedException, PacketException { if (packet instanceof Message) { messageStrategy.storeOffline((Message) packet); } else if (packet instanceof Presence) { // presence packets are dropped silently } else if (packet instanceof IQ) { ...
LogBench/LogBench-O_prefix_1point/openfire_OfflinePacketDeliverer_deliver.java
logbench-o_data_147
@Test public void testTempMessageConsumedAdvisoryConnectionClose() throws Exception { Connection connection = cf.createConnection(); connection.start(); Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE); final TemporaryQueue queue = session.createTemporaryQueue(); MessageCo...
LogBench/LogBench-O_prefix_1point/activemq_AMQ3324Test_testTempMessageConsumedAdvisoryConnectionClose.java
logbench-o_data_148
private void doLockMoney(AccountKit accountKit, Coin lockAmount, long unlockTime) { try { Result result = accountKit.lockMoney(lockAmount, unlockTime, null, null, "用户锁仓"); if (result.isSuccess()) { DailogUtil.showTipDailogCenter(result.getMessage(), getThisStage()); resetAndc...
LogBench/LogBench-O_prefix_1point/inchain_LockMoneyController_doLockMoney.java
logbench-o_data_149
protected Message sendAndReceiveMessage(Session session, ActiveMQMessageConsumer consumer, MessageProducer producer, final String messageBody, Map<String, String> propertiesMap) throws Exception { TextMessage messageToSend = session.createTextMessage(messageBody); if (propertiesMap != null) { for (Strin...
LogBench/LogBench-O_prefix_1point/activemq_AbstractVirtualDestTest_sendAndReceiveMessage.java
logbench-o_data_150
private void copyTable(Connection sourceConn, Connection targetConn, Table<?> table) throws SQLException { String tableName = table.getName(); LOG.warn("Converting table " + tableName + "..."); // Get the source data Statement sourceStmt = sourceConn.createStatement(); // only copy fields explicitly li...
LogBench/LogBench-O_prefix_1point/ma-core-public_DBConvert_copyTable.java
logbench-o_data_151
@Override public void addEntitlementToRole(Role role, Entitlement entitlement) { final RoleEntity roleEntity; if (role.getId() != 0) { roleEntity = em.find(RoleEntity.class, role.getId()); } else { roleEntity = getRoleEntity(role.getName(), em); } final EntitlementEntity entitlementE...
LogBench/LogBench-O_prefix_1point/cxf-fediz_RoleDAOJPAImpl_addEntitlementToRole.java
logbench-o_data_152
@Test(groups = { "wso2.esb" }, description = "Creating SOAP1.2 fault messages as Response property false") public void testSOAP12FaultAttributeResponseFalseWithAddressing() throws AxisFault { try { String proxyServiceName = "Soap12FaultWithPropertyResponseFalseWithAddressingTestCaseProxy"; axis2Clie...
LogBench/LogBench-O_prefix_1point/micro-integrator_Soap12FaultWithPropertyResponseFalseWithAddressingTestCase_testSOAP12FaultAttributeResponseFalseWithAddressing.java
logbench-o_data_153
@Override protected Void processItem(List<DataPointWithEventDetectors> subgroup, int itemId) { long startTs = 0L; if (log.isInfoEnabled()) { startTs = Common.timer.currentTimeMillis(); log.info("Initializing group {} of {} data points", itemId, subgroup.size()); } // Bulk request the latest val...
LogBench/LogBench-O_prefix_1point/ma-core-public_DataPointGroupInitializer_processItem.java
logbench-o_data_154
protected Transport createConsumer() throws Exception { LOG.info("Consumer on port: " + consumerPort); OpenWireFormat wireFormat = createWireFormat(); UdpTransport transport = new UdpTransport(wireFormat, consumerPort); transport.setSequenceGenerator(new IntSequenceGenerator()); return new CommandJoine...
LogBench/LogBench-O_prefix_1point/activemq_UdpTransportTest_createConsumer.java
logbench-o_data_155
@Override public void handleException(Throwable throwable) { log.error("{}", new Object[] { throwable.getCause() }); }
LogBench/LogBench-O_prefix_1point/red5-server_SharedObjectClient_handleException.java
logbench-o_data_156
public List<HistoricalQuote> getResult() throws IOException { List<HistoricalQuote> result = new ArrayList<HistoricalQuote>(); if (this.from.after(this.to)) { log.warn("Unable to retrieve historical quotes. " + "From-date should not be after to-date. From: " + this.from.getTime() + ", to: " + this.to.getTime()...
LogBench/LogBench-O_prefix_1point/yahoofinance-api_HistQuotes2Request_getResult.java
logbench-o_data_157
/** * Processes the authorization request using file based user store. * * @return true if successfully authorized */ private boolean processAuthorizationWithFileBasedUserStore(String userName) { boolean isAdmin = FileBasedUserStoreManager.getUserStoreManager().isAdmin(userName); if (!isAdmin) { LOG.error(...
LogBench/LogBench-O_prefix_1point/micro-integrator_AuthorizationHandler_processAuthorizationWithFileBasedUserStore.java
logbench-o_data_158
protected void assertDeniedTemp(String userPass) { try { assertAllowedTemp(userPass); fail("Expected not allowed exception"); } catch (Exception expected) { LOG.debug("got:" + expected, expected); } }
LogBench/LogBench-O_prefix_1point/activemq_AbstractAuthorizationTest_assertDeniedTemp.java
logbench-o_data_159
public void handle(Callback[] callbacks) throws IOException, UnsupportedCallbackException { for (int i = 0; i < callbacks.length; i++) { if (callbacks[i] instanceof HomeRealmCallback) { HomeRealmCallback callback = (HomeRealmCallback) callbacks[i]; HttpServletRequest request = callba...
LogBench/LogBench-O_prefix_1point/cxf-fediz_ClientIdHomeRealmDiscovery_handle.java
logbench-o_data_160
public void testLongNumberRanges() throws Exception { long[] numberValues = { // bytes 0, 1, 0x7e, 0x7f, 0x80, 0x81, 0xf0, 0xff, // shorts 0x7eff, 0x7fffL, 0x8001L, 0x8000L, 0xe000L, 0xe0001L, 0xff00L, 0xffffL, // ints 0x10000L, 0x700000L, 0x12345678L, 0x72345678L, 0x7fffffffL, 0x80000000L, 0x80000001L,...
LogBench/LogBench-O_prefix_1point/activemq_NumberRangesWhileMarshallingTest_testLongNumberRanges.java
logbench-o_data_161
private void getCustomerOrders() throws AxisFault, XPathExpressionException { OMElement payload = fac.createOMElement("customerOrders", omNs); OMElement result = new AxisServiceClient().sendReceive(payload, getServiceUrlHttp(serviceName), "customerOrders"); Assert.assertNotNull(result, "Response message nul...
LogBench/LogBench-O_prefix_1point/micro-integrator_NestedQueryTestCase_getCustomerOrders.java
logbench-o_data_162
@Override public boolean invoke(MessageContext synCtx) { buildMessage(synCtx); synCtx.setProperty("Success", true); String query = ((Axis2MessageContext) synCtx).getAxis2MessageContext().getOptions().getTo().getAddress(); OMElement textRootElem = OMAbstractFactory.getOMFactory().createOMElement(BaseCons...
LogBench/LogBench-O_prefix_1point/micro-integrator_MetricResource_invoke.java
logbench-o_data_163
@Override public void afterExecute(ForestRequest request, ForestResponse response) { log.info("invoke Simple2 afterExecute"); }
LogBench/LogBench-O_prefix_1point/forest_Simple2Interceptor_afterExecute.java
logbench-o_data_164
public void testBrokerConfiguredCorrectly() throws Exception { // Validate the system properties are being evaluated in xbean. assertEquals("testbroker", brokerService.getBrokerName()); Topic topic = (Topic) broker.addDestination(context, new ActiveMQTopic("FOO.BAR"), true); DispatchPolicy dispatchPolic...
LogBench/LogBench-O_prefix_1point/activemq_XBeanConfigTest_testBrokerConfiguredCorrectly.java
logbench-o_data_165
@PreDestroy private void destroy() { if (log.isInfoEnabled()) { log.info("Shutting down shared executor and scheduled executor"); } scheduledExecutor.shutdown(); executor.shutdown(); // interrupt the FutureConverter thread Thread futureConverterThread = this.futureConverterThread; if (futur...
LogBench/LogBench-O_prefix_1point/ma-core-public_MangoExecutors_destroy.java
logbench-o_data_166
/** * Try to end the response if not already ended and completes normally in case of error. * * @param response the response to end. * @return a completed {@link Completable} even in case of error trying to end the response. */ private Completable tryEndResponse(HttpServerResponse response) { try { if ...
LogBench/LogBench-O_prefix_1point/gravitee-api-management_DebugHttpProtocolVerticle_tryEndResponse.java
logbench-o_data_167
@Override public boolean isSatisified() throws Exception { LOG.info("file size:" + journalLog + ", chan.size " + channel.size() + ", jfileSize.length: " + journalLog.length()); return Journal.DEFAULT_MAX_FILE_LENGTH == channel.size(); }
LogBench/LogBench-O_prefix_1point/activemq_PreallocationJournalTest_isSatisified.java
logbench-o_data_168
@Override public boolean isSatisified() throws Exception { try { Subscription sub = brokerService.getRegionBroker().getDestinationMap().get(ActiveMQDestination.transform(dest)).getConsumers().get(0); LOG.info("sub prefetch: " + sub.getConsumerInfo().getPrefetchSize()); return val == sub.getConsumer...
LogBench/LogBench-O_prefix_1point/activemq_StompPrefetchTest_isSatisified.java
logbench-o_data_169
/** * 根据ID获取中间内容页面* * @param id * @return */ private Node getPage(String id) { String fxml = null; switch(id) { case "antifakeId": // 点击账户信息按钮 fxml = "/resources/template/antifake.fxml"; break; case "flowInfoId": // 点击转账按钮 fxml = "/...
LogBench/LogBench-O_prefix_1point/inchain_AntiCounterfeitingController_getPage.java
logbench-o_data_170
public void testTransaction() throws Exception { ActiveMQConnectionFactory factory = new ActiveMQConnectionFactory("vm://localhost?broker.persistent=false"); connection = factory.createConnection(); queue = new ActiveMQQueue(getClass().getName() + "." + getName()); producerSession = connection.createSes...
LogBench/LogBench-O_prefix_1point/activemq_TransactionRollbackOrderTest_testTransaction.java
logbench-o_data_171
private void processIoTasks() { Runnable task; while ((task = ioTasks.poll()) != null) { try { task.run(); } catch (Throwable e) { LOG.debug(e.getMessage(), e); } } }
LogBench/LogBench-O_prefix_1point/activemq_SelectorWorker_processIoTasks.java
logbench-o_data_172
/** * Determine the message builder to use, set the message payload to the message context and * inject the message. * * @param properties the AMQP basic properties * @param body the message body * @param inboundName Inbound Name * @return delivery status of the message */ public AcknowledgementMode onM...
LogBench/LogBench-O_prefix_1point/micro-integrator_RabbitMQInjectHandler_onMessage.java
logbench-o_data_173
@Override public void putDruidCluster(DruidCluster cluster) throws IOException { log.info("Putting Druid cluster [{}]", cluster.getClusterId()); try (RedisConnection<String> conn = connect()) { if (cluster.getClusterId() == null) { cluster.setClusterId(newId()); } Map<String, St...
LogBench/LogBench-O_prefix_1point/sherlock_LettuceDruidClusterAccessor_putDruidCluster.java
logbench-o_data_174
@Override synchronized public void updated(String pid, Dictionary<String, ?> properties) throws ConfigurationException { // First stop currently running broker (if any) deleted(pid); String config = (String) properties.get("config"); if (config == null) { throw new ConfigurationException("config...
LogBench/LogBench-O_prefix_1point/activemq_ActiveMQServiceFactory_updated.java
logbench-o_data_175
public void testFDSLeak() throws Exception { ActiveMQConnectionFactory factory = new ActiveMQConnectionFactory(connectionURI); ActiveMQConnection connection = (ActiveMQConnection) factory.createConnection(); connection.start(); int connections = 100; final long original = openFileDescriptorCount(); ...
LogBench/LogBench-O_prefix_1point/activemq_AMQ4531Test_testFDSLeak.java
logbench-o_data_176
public void scheduleReport(ReportConfigurationBean configuration) throws Exception { try { reportingAdminServiceStub.scheduleReport(configuration); } catch (Exception e) { String msg = "Unable to schedule the report"; log.error(msg); throw new Exception(msg, e); } }
LogBench/LogBench-O_prefix_1point/micro-integrator_ReportAdminServiceClient_scheduleReport.java
logbench-o_data_177
@Test public void testRC4() { try { String encrypted = RC4.encryptAndEncode(testValue, rc4Key); String decrypted = RC4.decodeAndDecrypt(encrypted, rc4Key); assertEquals("RC4 encryption/decryption failed; decrypted result did not match initial value to encrypt", decrypted, testValue); } c...
LogBench/LogBench-O_prefix_1point/starter-kit-spring-maven_TestCrypto_testRC4.java
logbench-o_data_178
public static void main(String[] args) throws JMSException, InterruptedException { String url = "peer://localhost1/groupA?persistent=false"; if (args.length > 0) { url = args[0]; } ConnectionFactory connectionFactory = new ActiveMQConnectionFactory(url); Destination destination = new ActiveM...
LogBench/LogBench-O_prefix_1point/activemq_Producer_main.java
logbench-o_data_179
public SonarLintInputFile create(ClientInputFile inputFile) { var defaultInputFile = new SonarLintInputFile(inputFile, f -> { LOG.debug("Initializing metadata of file {}", f.uri()); var charset = f.charset(); InputStream stream; try { stream = f.inputStream(); } catch (I...
LogBench/LogBench-O_prefix_1point/sonarlint-core_ModuleInputFileBuilder_create.java
logbench-o_data_180
public void log(Object msg) { log.debug(msg.toString()); }
LogBench/LogBench-O_prefix_1point/reader_Helper_log.java
logbench-o_data_181
public boolean validateParams(BackchannelTokenDeliveryMode backchannelTokenDeliveryMode, String backchannelClientNotificationEndpoint, AsymmetricSignatureAlgorithm backchannelAuthenticationRequestSigningAlg, Boolean backchannelUserCodeParameter, List<GrantType> grantTypes, SubjectType subjectType, String sectorIdentifi...
LogBench/LogBench-O_prefix_1point/oxauth_CIBARegisterParamsValidatorService_validateParams.java
logbench-o_data_182
@Override public boolean attachHandler(ProducedEvent producedEvent) { if (Objects.equals(topic, producedEvent.getAggregateId())) { IHandledEvent existingEvent = listeningServices.get(producedEvent.getSender()); if (existingEvent instanceof NoneHandled) { log.debug("Attaching Event into: " + this + ...
LogBench/LogBench-O_prefix_1point/splitet_ProducedEvent_attachHandler.java
logbench-o_data_183
public void end(Xid arg0, int arg1) throws XAException { LOG.debug("{} end {} with {}", new Object[] { this, arg0, arg1 }); try { transactionContext.end(arg0, arg1); } finally { try { setInManagedTx(false); } catch (JMSException e) { throw (XAException) new XAExc...
LogBench/LogBench-O_prefix_1point/activemq_LocalAndXATransaction_end.java
logbench-o_data_184
@Override public void resourceChanged(String resourceUri, Buffer resource) { if (configResourceUri() != null && configResourceUri().equals(resourceUri)) { log.info("Content-Type constraint configuration resource {} was updated. Going to initialize with new configuration", resourceUri); initializeConstraint...
LogBench/LogBench-O_prefix_1point/gateleen_ContentTypeConstraintHandler_resourceChanged.java
logbench-o_data_185
public void doStart() throws Exception { log.debug("Started Sender service gbean."); }
LogBench/LogBench-O_prefix_1point/geronimo_SenderGBean_doStart.java
logbench-o_data_186
/** * {@inheritdoc } */ public OMElement processDocument(InputStream inputStream, String contentType, MessageContext msgCtx) throws AxisFault { try { HL7ProcessingContext processingCtx = new HL7ProcessingContext(msgCtx.getAxisService()); String charset = getCharsetEncoding(contentType); ms...
LogBench/LogBench-O_prefix_1point/micro-integrator_HL7MessageBuilder_processDocument.java
logbench-o_data_187
/** * Parse the Number from the given text, using the specified NumberFormat. */ @Override public void setAsText(String text) throws IllegalArgumentException { if (NumberUtils.isNumber(text) || !StringUtils.hasText(text)) { super.setAsText(text); } else { log.error("Attempting to set a number field u...
LogBench/LogBench-O_prefix_1point/starter-kit-spring-maven_MyCustomNumberEditor_setAsText.java
logbench-o_data_188
private void updateConfigurationResource() { storage.get(circuitBreakerConfigUri, buffer -> { if (buffer != null) { try { extractConfigurationValues(buffer); log.info("Applying circuit breaker configuration values : {}", getConfigurationResource().toString()); } catc...
LogBench/LogBench-O_prefix_1point/gateleen_QueueCircuitBreakerConfigurationResourceManager_updateConfigurationResource.java
logbench-o_data_189
private void collectMetrics(Buffer buffer) { Map<String, String> map = new HashMap<>(); Splitter.on(System.lineSeparator()).omitEmptyStrings().trimResults().splitToList(buffer.toString()).stream().filter(input -> input != null && input.contains(DELIMITER) && !input.contains("executable") && !input.contains("con...
LogBench/LogBench-O_prefix_1point/gateleen_RedisMonitor_collectMetrics.java
logbench-o_data_190
public void run() { try { Session session = createSession(brokerConnection); Destination dest = session.createQueue(subject); MessageProducer producer = session.createProducer(dest); producer.setDeliveryMode(DeliveryMode.NON_PERSISTENT); for (int i = 0; i < 20; i++) { ...
LogBench/LogBench-O_prefix_1point/activemq_QueueDuplicatesTest_run.java
logbench-o_data_191
protected boolean isReady() { String commandName = getContainerType(); String containerId = waitStrategyTarget.getContainerId(); String[] checkCommand = getCheckCommand(); log.debug("{} execution of command {} for container id: {} ", commandName, Arrays.toString(checkCommand), containerId); Container.E...
LogBench/LogBench-O_prefix_1point/testcontainers-spring-boot_AbstractCommandWaitStrategy_isReady.java
logbench-o_data_192
/** * Returns a capabilities response with the extent and year range built by inspecting the zoom 0 tiles of the * EPSG:4326 projection. */ @RequestMapping(method = RequestMethod.GET, value = "/tile.json", produces = MediaType.APPLICATION_JSON_VALUE) @Timed public V1TileJson tileJson(@RequestParam("type") String typ...
LogBench/LogBench-O_prefix_1point/maps_BackwardCompatibility_tileJson.java
logbench-o_data_193
public List<TaskDescription> getAllTaskDescriptions() { final Lock lock = getLock(); try { lock.lock(); List<TaskDescription> taskDescriptions = new ArrayList<TaskDescription>(); Iterator<TaskDescription> iterator = StartupUtils.getAllTaskDescriptions(getSynapseEnvironment()); wh...
LogBench/LogBench-O_prefix_1point/micro-integrator_StartupAdminService_getAllTaskDescriptions.java
logbench-o_data_194
public void testInitialContextHasXA() throws Exception { InitialContext context = new InitialContext(); assertTrue("Created context", context != null); ActiveMQXAConnectionFactory connectionFactory = (ActiveMQXAConnectionFactory) context.lookup("XAConnectionFactory"); assertTrue("Should have created an ...
LogBench/LogBench-O_prefix_1point/activemq_InitialContextTest_testInitialContextHasXA.java
logbench-o_data_195
public CarbonServerConfigurationService getServerConfigurationService() { if (this.serverConfigurationService == null) { String msg = "Before activating Carbon Core bundle, an instance of " + "ServerConfigurationService should be in existance"; log.error(msg); } return this.serverConfigurationServi...
LogBench/LogBench-O_prefix_1point/micro-integrator_CarbonCoreDataHolder_getServerConfigurationService.java
logbench-o_data_196
/** * Method to return SSL configs as {@link Properties}. * @return ssl properties */ public Properties asProperties() { Field[] configFields = Utils.findFields(SSslConfigs.class, SSLProperty.class); Properties properties = new Properties(); for (Field configField : configFields) { configField.se...
LogBench/LogBench-O_prefix_1point/sherlock_SSslConfigs_asProperties.java
logbench-o_data_197
@FXML public void finish() { if (keychain.isSupported()) { try { keychain.deletePassphrase(vault.getId()); LOG.debug("Forgot password for vault {}.", vault.getDisplayName()); confirmedResult.setValue(true); } catch (KeychainAccessException e) { LOG.error("Failed ...
LogBench/LogBench-O_prefix_1point/cryptomator_ForgetPasswordController_finish.java
logbench-o_data_198
@Test public void testMultipleDots2() { mockLogLevelRestricted(LogLevel.ERROR); new LogAdapter("logger.name..here", mockConfigCompact()).error("Message 3"); verifyStatic(Log.class); Log.e(createTag(0), "l.n.here: Message 3"); }
LogBench/LogBench-O_prefix_1point/slf4j-android_CompactNamesTest_testMultipleDots2.java
logbench-o_data_199
private JSONObject sendRequest(String addUrl, String query, String action) throws IOException, JSONException { String charset = "UTF-8"; URLConnection connection = new URL(addUrl).openConnection(); connection.setDoOutput(true); connection.setRequestProperty("Accept-Charset", charset); connection.set...
LogBench/LogBench-O_prefix_1point/micro-integrator_JSONClient_sendRequest.java
logbench-o_data_200
public void testParseXPath() throws Exception { BooleanExpression filter = parse("XPATH '//title[@lang=''eng'']'"); assertTrue("Created XPath expression", filter instanceof XPathExpression); LOG.info("Expression: " + filter); }
LogBench/LogBench-O_prefix_1point/activemq_SelectorParserTest_testParseXPath.java