This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Docker Compose for headless rTorrent + File Browser + ruTorrent | |
# | |
# Instructions: | |
# 1. Create required directories in the same folder as this file: | |
# mkdir -p downloads session filebrowser config/rtorrent | |
# 2. (Optional) Place your custom rtorrent.rc at: | |
# config/rtorrent/rtorrent.rc | |
# to include any additional settings; daemon mode is enabled via the command below, | |
# but you can also add `system.daemon.set = true` in that file. | |
# 3. Bring up the stack (after shutting down any existing one): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.apache.helix.examples; | |
/* | |
* Licensed to the Apache Software Foundation (ASF) under one | |
* or more contributor license agreements. See the NOTICE file | |
* distributed with this work for additional information | |
* regarding copyright ownership. The ASF licenses this file | |
* to you under the Apache License, Version 2.0 (the | |
* "License"); you may not use this file except in compliance | |
* with the License. You may obtain a copy of the License at |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.apache.helix.examples; | |
import com.fasterxml.jackson.core.JsonProcessingException; | |
import com.fasterxml.jackson.databind.ObjectMapper; | |
import com.google.common.collect.ImmutableMap; | |
import org.apache.helix.ConfigAccessor; | |
import org.apache.helix.HelixAdmin; | |
import org.apache.helix.HelixDefinedState; | |
import org.apache.helix.HelixManager; | |
import org.apache.helix.HelixManagerFactory; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ClusterSetup { | |
InitializingBean init() { | |
return () -> { | |
// Create admin. | |
LOG.info("Creating cluster admin..."); | |
HelixAdmin admin = new ZKHelixAdmin.Builder() | |
.setZkAddress(appConfig.getZkClientUrl()).build(); | |
ConfigAccessor configAccessor = new ConfigAccessor.Builder() | |
.setZkAddress(appConfig.getZkClientUrl()).build(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ballerina/io; | |
type Author record {| | |
readonly int id; | |
string name; | |
|}; | |
type Category record {| | |
readonly int id; | |
string name; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ballerina/io; | |
type Person record {| | |
string firstName; | |
string lastName; | |
string deptAccess; | |
|}; | |
type Department record {| | |
string name; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ballerina/io; | |
// -------- Types --------- | |
public type _Iterator abstract object { | |
public function next() returns record {|(any|error) value;|}|error?; | |
}; | |
public type _StreamFunction abstract object { | |
public _StreamFunction? prevFunc; | |
public function process() returns _Frame|error?; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Copyright (c) 2019 WSO2 Inc. (http://www.wso2.org) All Rights Reserved. | |
// | |
// WSO2 Inc. licenses this file to you under the Apache License, | |
// Version 2.0 (the "License"); you may not use this file except | |
// in compliance with the License. | |
// You may obtain a copy of the License at | |
// | |
// http://www.apache.org/licenses/LICENSE-2.0 | |
// | |
// Unless required by applicable law or agreed to in writing, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
forever { | |
from inputStream window length(2) | |
select inputStream.name, inputStream.age, inputStream.status, count() as count | |
group by inputStream.school | |
=> (Teacher [] emp) { | |
foreach var e in emp { | |
outputStream.publish(e); | |
} | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public type Aggregator abstract object { | |
public function copy() returns Aggregator; | |
public function process(anydata value, EventType eventType) returns anydata; | |
}; |
NewerOlder