blob: 0cb83ef8d4f353e6be1536b1653fbbd5e15c08cd [file] [log] [blame]
Ray Milkey28d77f32018-07-27 09:21:49 -07001COMPILE_DEPS = CORE_DEPS + KRYO + ATOMIX + [
Ray Milkey324af932018-06-20 19:50:31 -07002 "//core/common:onos-core-common",
3 "//core/store/serializers:onos-core-serializers",
Ray Milkey324af932018-06-20 19:50:31 -07004]
5
6TEST_DEPS = TEST + [
7 "@commons_math3//jar",
Carmelo Cascone72893b72018-08-09 00:59:06 -07008 "@io_netty_netty_handler//jar",
9 "@io_netty_netty_buffer//jar",
10 "@io_netty_netty_codec//jar",
11 "@io_netty_netty_resolver//jar",
Ray Milkey324af932018-06-20 19:50:31 -070012 "//core/api:onos-api-tests",
13]
14
Ray Milkey644fdbf2018-07-27 15:24:31 -070015_primitive_package_names = [
Jian Lid486a732018-08-03 00:32:11 +090016 "barrier",
17 "collection",
18 "counter",
19 "election",
20 "idgenerator",
21 "iterator",
22 "list",
23 "lock",
24 "map",
25 "multimap",
26 "multiset",
27 "queue",
28 "semaphore",
29 "set",
30 "transaction",
31 "tree",
32 "value",
33 "workqueue",
Ray Milkey644fdbf2018-07-27 15:24:31 -070034]
35
36# A list of all core primitive packages for dynamic class loading
Jian Lid486a732018-08-03 00:32:11 +090037PRIMITIVE_PACKAGES = ",".join(["io.atomix.primitive.session.impl"] + ["io.atomix.core.{primitive},io.atomix.core.{primitive}.impl".format(primitive = primitive) for primitive in _primitive_package_names])
Ray Milkey644fdbf2018-07-27 15:24:31 -070038
39# Base package names for core Atomix protocols
40_protocol_package_names = [
Jian Lid486a732018-08-03 00:32:11 +090041 "raft",
42 "backup",
Ray Milkey644fdbf2018-07-27 15:24:31 -070043]
44
Jordan Halterman28b21d12018-11-12 11:03:35 -080045# A list of all cluster protocol packages for dynamic class loading
46CLUSTER_PACKAGES = ",".join([
47 "io.atomix.cluster.discovery",
48 "io.atomix.cluster.protocol",
49])
50
Ray Milkey644fdbf2018-07-27 15:24:31 -070051# A list of all core protocol packages for dynamic class loading
Jian Lid486a732018-08-03 00:32:11 +090052PROTOCOL_PACKAGES = ",".join(["io.atomix.primitive.partition.impl"] + ["io.atomix.protocols.{protocol},io.atomix.protocols.{protocol}.partition".format(protocol = protocol) for protocol in _protocol_package_names] + ["io.atomix.protocols.gossip"])
Ray Milkey644fdbf2018-07-27 15:24:31 -070053
54# A list of all additional core packages used in dynamic class loading
Jian Lid486a732018-08-03 00:32:11 +090055CORE_PACKAGES = ",".join([
56 "io.atomix.core.profile",
57 "io.atomix.core.profile.impl",
58])
Ray Milkey644fdbf2018-07-27 15:24:31 -070059
60# A list of all dynamically loadable Atomix packages
Jian Lid486a732018-08-03 00:32:11 +090061INCLUDE_PACKAGES = ",".join([
Jordan Halterman28b21d12018-11-12 11:03:35 -080062 CLUSTER_PACKAGES,
Jian Lid486a732018-08-03 00:32:11 +090063 PRIMITIVE_PACKAGES,
64 PROTOCOL_PACKAGES,
65 CORE_PACKAGES,
66])
Ray Milkey644fdbf2018-07-27 15:24:31 -070067
Jian Lid486a732018-08-03 00:32:11 +090068ALL_PACKAGES = "*"
Ray Milkey644fdbf2018-07-27 15:24:31 -070069
Ray Milkey324af932018-06-20 19:50:31 -070070osgi_jar_with_tests(
71 name = "onos-core-primitives",
Jian Lid486a732018-08-03 00:32:11 +090072 import_packages = INCLUDE_PACKAGES + "," + ALL_PACKAGES,
Ray Milkey324af932018-06-20 19:50:31 -070073 test_deps = TEST_DEPS,
74 visibility = ["//visibility:public"],
75 deps = COMPILE_DEPS,
Ray Milkey324af932018-06-20 19:50:31 -070076)