Skip to content

Commit

Permalink
v0.24.0 (#1421)
Browse files Browse the repository at this point in the history
Release v0.24.0
  • Loading branch information
patrickod authored Nov 30, 2021
1 parent 99158a8 commit 6bd797e
Show file tree
Hide file tree
Showing 26 changed files with 109 additions and 78 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/publish-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ on:
description: "docs s3 path (docs.oso.dev or docs-preview.oso.dev)"
oso_version:
description: "oso release to build docs for"
default: "0.23.0" # oso_version
default: "0.24.0" # oso_version
flask_oso_version:
description: "flask oso release to build docs for"
default: "0.23.0" # flask_oso_version
default: "0.24.0" # flask_oso_version
django_oso_version:
description: "django oso release to build docs for"
default: "0.23.0" # django_oso_version
default: "0.24.0" # django_oso_version
sqlalchemy_oso_version:
description: "sqlalchemy oso release to build docs for"
default: "0.23.0" # sqlalchemy_oso_version
default: "0.24.0" # sqlalchemy_oso_version
jobs:
publish:
name: Publish docs
Expand Down
12 changes: 6 additions & 6 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.23.0
0.24.0
70 changes: 70 additions & 0 deletions docs/content/any/project/changelogs/2021-12-01.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
---
title: Release 2021-12-01
menuTitle: "2021-12-01"
any: true
description: >-
Changelog for Release 2021-12-01 (oso 0.24.0, django-oso 0.24.0, flask-oso 0.24.0, sqlalchemy-oso 0.24.0, VSCode extension 0.24.0) containing new features,
bug fixes, and more.
---

## VSCode Extension 0.24.0

- Our VSCode Extension now displays inline diagnostics (errors & warnings) in the editor as well as in VSCode's **Problems** pane.
- The extension immediately highlights errors and warnings encountered while parsing and validating your policy, such as if a rule is missing a trailing semi-colon, a resource block declares `"owner"` as both a role and a relation, or your policy contains no `allow()` rule. You would normally see this feedback when running your application, but the extension surfaces it while you edit your policy.
- The extension collects **non-identifiable** telemetry data that we use to improve Oso. We collect data into un-timestamped batches instead of sending it on every policy load since we care about aggregate statistics; not tracking your personal development behavior. **We will never sell this data**. For more info on exactly what is tracked and why, see [this page][https://docs.osohq.com/reference/tooling/ide/telemetry.html] in our docs.

## Oso 0.24.0

### Core

#### Other bugs & improvements

- Oso now allows multiple resource blocks to be declared for the same resource type. The declarations from all resource blocks for a given type are merged together before policy evaluation. This permits rules in one block to reference declarations in another and for resource blocks to be composed over multiple files.
- Fixed a data race in our error handling functionality which resulted in truncated error messages.
- Fixed a regression in the logic for rule matching when using `in` with data filtering.
- Fixed a regression in rule type checking which prevented using roles with `actor` blocks.

### Rust

#### Other bugs & improvements

- Implemented `ExternalIsSubclass` query event. Prevents `x matches Foo and x matches Bar`
from panicking. Instead, this will now correctly fail when `Foo != Bar`.
Thanks to [`@davepacheco`](https://github.com/davepacheco) for the contribution!


### Go

#### Other bugs & improvements
- Added a `SetAcceptExpression` method to the `Query` struct which makes
it possible to get partially-evaluated terms back from the core.
This is a step towards data filtering in Go.
Thanks to [`@joshrotenberg`](https://github.com/joshrotenberg) for the PR!

#### Platform Support

We now support building Oso on ARM-based MacOS systems using Go 1.16 or later.

### Ruby

#### New Features

##### New Data Filtering API

A new data filtering backend is now available in the Ruby library, which should provide
better performance in most cases. An example ActiveRecord adapter is also included. For
details on how to configure and use the new data filtering code, please see [our docs][new_data_filtering_docs].

[new_data_filtering_docs]: https://docs.osohq.com/ruby/guides/data_filtering_next.html

## `django-oso` 0.24.0

Bumped the minimum required version of the `oso` dependency.

## `flask-oso` 0.24.0

Bumped the minimum required version of the `oso` dependency.

## `sqlalchemy-oso` 0.24.0

Bumped the minimum required version of the `oso` dependency.
40 changes: 0 additions & 40 deletions docs/content/any/project/changelogs/NEXT.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,48 +8,8 @@ description: >-
draft: true
---

## Oso 0.23.1

### Core

#### Other bugs & improvements

- Oso now allows multiple resource blocks to be declared for the same resource type. The declarations from all resource blocks for a given type are merged together before policy evaluation. This permits rules in one block to reference declarations in another and for resource blocks to be composed over multiple files.
- Fixed a data race in our error handling functionality which resulted in truncated error messages.
- Fixed a regression in the logic for rule matching when using `in` with data filtering.

### Rust

#### Other bugs & improvements

- Implemented `ExternalIsSubclass` query event. Prevents `x matches Foo and x matches Bar`
from panicking. Instead, this will now correctly fail when `Foo != Bar`.
Thanks to [`@davepacheco`](https://github.com/davepacheco) for the contribution!


## `RELEASED_PACKAGE_1` NEW_VERSION


### Go

#### Other bugs & improvements
- Added a `SetAcceptExpression` method to the `Query` struct which makes
it possible to get partially-evaluated terms back from the core.
This is a step towards data filtering in Go.
Thanks to [`@joshrotenberg`](https://github.com/joshrotenberg) for the PR!

### Ruby

#### New Features

##### New Data Filtering API

A new data filtering backend is now available in the Ruby library, which should provide
better performance in most cases. An example ActiveRecord adapter is also included. For
details on how to configure and use the new data filtering code, please see [our docs][new_data_filtering_docs].

[new_data_filtering_docs]: https://docs.osohq.com/ruby/guides/data_filtering_next.html

### LANGUAGE (e.g., 'Core' or 'Python' or 'Node.js')

#### Breaking changes
Expand Down
2 changes: 1 addition & 1 deletion docs/examples/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ JS_DIR := $(OSO_ROOT)/languages/js
RUBY_DIR := $(OSO_ROOT)/languages/ruby

# Needed for tests
JAVA_PACKAGE_JAR_PATH := $(JAVA_DIR)/oso/target/oso-0.23.0.jar
JAVA_PACKAGE_JAR_PATH := $(JAVA_DIR)/oso/target/oso-0.24.0.jar

# Note: if you are using bundler in a sub-makefile (in a docs test for example),
# you need to add `unexport BUNDLE_GEMFILE` to that makefile. Otherwise this
Expand Down
1 change: 1 addition & 0 deletions docs/spelling/allowed_words.txt
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ UUID
UUIDs
VM
VPN
VSCode
VSCode's
WASM
Wayfair
Expand Down
2 changes: 1 addition & 1 deletion languages/java/oso/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

<groupId>com.osohq</groupId>
<artifactId>oso</artifactId>
<!-- oso_version --><version>0.23.0</version>
<!-- oso_version --><version>0.24.0</version>

<distributionManagement>
<snapshotRepository>
Expand Down
2 changes: 1 addition & 1 deletion languages/js/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "oso",
"version": "0.23.0",
"version": "0.24.0",
"description": "oso authorization library.",
"bin": "bin/repl.js",
"main": "dist/src/index.js",
Expand Down
2 changes: 1 addition & 1 deletion languages/python/django-oso/django_oso/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

from .oso import Oso

__version__ = "0.23.0"
__version__ = "0.24.0"

default_app_config = "django_oso.apps.DjangoOsoConfig"
2 changes: 1 addition & 1 deletion languages/python/django-oso/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
oso~=0.23.0
oso~=0.24.0
django>=2.2
4 changes: 2 additions & 2 deletions languages/python/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@
project = "oso"
copyright = "2020-2021 Oso Security, Inc"
author = "oso"
version = "0.23.0"
release = "0.23.0"
version = "0.24.0"
release = "0.24.0"


# -- General configuration ---------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion languages/python/flask-oso/flask_oso/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
__version__ = "0.23.0"
__version__ = "0.24.0"

from .flask_oso import FlaskOso
from .decorators import authorize, skip_authorization
Expand Down
2 changes: 1 addition & 1 deletion languages/python/flask-oso/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
oso~=0.23.0
oso~=0.24.0
flask>=0.12.0
2 changes: 1 addition & 1 deletion languages/python/oso/oso/oso.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"""Core oso functionality"""

__version__ = "0.23.0"
__version__ = "0.24.0"

import os
from typing import List, Any, Set
Expand Down
2 changes: 1 addition & 1 deletion languages/python/sqlalchemy-oso/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
oso~=0.23.0
oso~=0.24.0
SQLAlchemy>=1.3.17,<1.5
packaging~=20.9
2 changes: 1 addition & 1 deletion languages/python/sqlalchemy-oso/sqlalchemy_oso/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
__version__ = "0.23.0"
__version__ = "0.24.0"


from .auth import register_models
Expand Down
2 changes: 1 addition & 1 deletion languages/ruby/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
oso-oso (0.23.0)
oso-oso (0.24.0)
ffi (~> 1.0)

GEM
Expand Down
2 changes: 1 addition & 1 deletion languages/ruby/lib/oso/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Oso
VERSION = '0.23.0'
VERSION = '0.24.0'
end
2 changes: 1 addition & 1 deletion languages/rust/oso-derive/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ license = "Apache-2.0"
homepage = "https://github.com/osohq/oso"
readme = "README.md"

version = "0.23.0"
version = "0.24.0"

edition = "2021"

Expand Down
8 changes: 4 additions & 4 deletions languages/rust/oso/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ license = "Apache-2.0"
name = "oso"
readme = "README.md"

version = "0.23.0"
version = "0.24.0"

edition = "2021"

Expand All @@ -30,8 +30,8 @@ required-features = ["anyhow"]
[dependencies]
impl-trait-for-tuples = "0.2.1"
maplit = "1.0.2"
oso-derive = { path = "../oso-derive", version = "=0.23.0", optional = true }
polar-core = { path = "../../../polar-core", version = "=0.23.0" }
oso-derive = { path = "../oso-derive", version = "=0.24.0", optional = true }
polar-core = { path = "../../../polar-core", version = "=0.24.0" }
thiserror = "1.0.30"
tracing = { version = "0.1.29", features = ["log"] }
tracing-subscriber = { version = "0.3.1", default-features = false, features = [
Expand All @@ -50,7 +50,7 @@ uuid-07 = { package = "uuid", version = ">=0.7.0, <0.9.0", optional = true }
[dev-dependencies]
anyhow = "1.0.44"
criterion = "0.3.5"
oso-derive = { path = "../oso-derive", version = "=0.23.0" }
oso-derive = { path = "../oso-derive", version = "=0.24.0" }
static_assertions = "1.1.0"
tempfile = "3.2.0"

Expand Down
4 changes: 2 additions & 2 deletions polar-c-api/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "polar-c-api"
version = "0.23.0"
version = "0.24.0"
authors = ["Oso Security, Inc. <[email protected]>"]
edition = "2021"

Expand All @@ -10,7 +10,7 @@ crate-type = ["lib", "staticlib", "cdylib"]
bench = false

[dependencies]
polar-core = { path = "../polar-core", version = "=0.23.0" }
polar-core = { path = "../polar-core", version = "=0.24.0" }
serde = "1.0"
serde_json = "1.0.61"

Expand Down
2 changes: 1 addition & 1 deletion polar-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ license = "Apache-2.0"
homepage = "https://github.com/osohq/oso"
readme = "README.md"

version = "0.23.0"
version = "0.24.0"

edition = "2021"

Expand Down
4 changes: 2 additions & 2 deletions polar-language-server/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "polar-language-server"
version = "0.23.0"
version = "0.24.0"
authors = ["Oso Security, Inc. <[email protected]>"]
edition = "2021"

Expand All @@ -12,7 +12,7 @@ bench = false
console_error_panic_hook = "0.1.6"
js-sys = "0.3.53"
lsp-types = "0.90.0"
polar-core = { path = "../polar-core", version = "=0.23.0" }
polar-core = { path = "../polar-core", version = "=0.24.0" }
serde = { version = "1.0", features = ["derive"] }
serde-wasm-bindgen = "0.3.1"
wasm-bindgen = "0.2.76"
Expand Down
4 changes: 2 additions & 2 deletions polar-wasm-api/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "polar-wasm-api"
version = "0.23.0"
version = "0.24.0"
authors = ["Oso Security, Inc. <[email protected]>"]
edition = "2021"

Expand All @@ -11,7 +11,7 @@ bench = false
[dependencies]
console_error_panic_hook = "0.1.6"
js-sys = "0.3.53"
polar-core = { path = "../polar-core", version = "=0.23.0" }
polar-core = { path = "../polar-core", version = "=0.24.0" }
serde = { version = "1.0.119", features = ["rc"] }
serde-wasm-bindgen = "0.3.1"
wasm-bindgen = "0.2.76"
Expand Down
Loading

2 comments on commit 6bd797e

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark 'Rust Benchmark'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 1.50.

Benchmark suite Current: 6bd797e Previous: 99158a8 Ratio
indexed/10000 29400 ns/iter (± 187714) 15050 ns/iter (± 2189) 1.95
partial_rule_depth/80 67846549 ns/iter (± 4393548) 42927959 ns/iter (± 560330) 1.58

This comment was automatically generated by workflow using github-action-benchmark.

CC: @osohq/eng

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rust Benchmark

Benchmark suite Current: 6bd797e Previous: 99158a8 Ratio
rust_get_attribute 80437 ns/iter (± 11428) 60436 ns/iter (± 16425) 1.33
n_plus_one/100 3657532 ns/iter (± 198068) 2871500 ns/iter (± 4911) 1.27
n_plus_one/500 17975566 ns/iter (± 1061565) 13873609 ns/iter (± 21553) 1.30
n_plus_one/1000 35031560 ns/iter (± 1648396) 27547411 ns/iter (± 67484) 1.27
unify_once 1047 ns/iter (± 108) 871 ns/iter (± 52) 1.20
unify_twice 2777 ns/iter (± 537) 2316 ns/iter (± 53) 1.20
many_rules 68660 ns/iter (± 4089) 55387 ns/iter (± 1367) 1.24
fib/5 635475 ns/iter (± 33618) 511173 ns/iter (± 11623) 1.24
prime/3 29251 ns/iter (± 3790) 23777 ns/iter (± 1059) 1.23
prime/23 28869 ns/iter (± 3724) 23808 ns/iter (± 997) 1.21
prime/43 29472 ns/iter (± 1910) 23798 ns/iter (± 1020) 1.24
prime/83 31016 ns/iter (± 2743) 23764 ns/iter (± 1024) 1.31
prime/255 27806 ns/iter (± 1678) 22229 ns/iter (± 947) 1.25
indexed/100 6947 ns/iter (± 1418) 5263 ns/iter (± 580) 1.32
indexed/500 8143 ns/iter (± 2924) 6366 ns/iter (± 1851) 1.28
indexed/1000 10700 ns/iter (± 9685) 8257 ns/iter (± 253) 1.30
indexed/10000 29400 ns/iter (± 187714) 15050 ns/iter (± 2189) 1.95
not 7475 ns/iter (± 766) 5850 ns/iter (± 134) 1.28
double_not 16346 ns/iter (± 1091) 12417 ns/iter (± 273) 1.32
De_Morgan_not 10494 ns/iter (± 1750) 7929 ns/iter (± 769) 1.32
load_policy 1337469 ns/iter (± 86805) 1071898 ns/iter (± 1605) 1.25
partial_and/1 65083 ns/iter (± 15655) 52172 ns/iter (± 2003) 1.25
partial_and/5 240367 ns/iter (± 21686) 194220 ns/iter (± 5811) 1.24
partial_and/10 454818 ns/iter (± 30577) 370992 ns/iter (± 7329) 1.23
partial_and/20 934172 ns/iter (± 43251) 754906 ns/iter (± 7575) 1.24
partial_and/40 1989971 ns/iter (± 82718) 1574333 ns/iter (± 26590) 1.26
partial_and/80 4303979 ns/iter (± 185200) 3378582 ns/iter (± 5489) 1.27
partial_and/100 5644073 ns/iter (± 245319) 4371093 ns/iter (± 6093) 1.29
partial_rule_depth/1 195102 ns/iter (± 14005) 154973 ns/iter (± 5284) 1.26
partial_rule_depth/5 601658 ns/iter (± 31954) 475241 ns/iter (± 8089) 1.27
partial_rule_depth/10 1223982 ns/iter (± 66878) 977620 ns/iter (± 13885) 1.25
partial_rule_depth/20 3307266 ns/iter (± 173174) 2500711 ns/iter (± 9364) 1.32
partial_rule_depth/40 11547672 ns/iter (± 568337) 8161550 ns/iter (± 170594) 1.41
partial_rule_depth/80 67846549 ns/iter (± 4393548) 42927959 ns/iter (± 560330) 1.58
partial_rule_depth/100 118729410 ns/iter (± 4902186) 79240603 ns/iter (± 436137) 1.50

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.