KO
|
EN
gitlite — search
Search
#python
#java
#python3
#arduino
#golang
#machine-learning
#rust
#html
#flask
#javascript
#seismology
#nodejs
goe
★ 15
Open GitHub ↗
enterprise tooling
Download README (.md)
Explore Similar Repositories
rust-lazy-foo
:
Following the Lazy Foo SDL2 examples using Rust
RBStatefulTableViewController
:
No description available.
abcd
:
Access to Biological Collection Data (ABCD)
IpCamera
:
MJPEG Network Camera Server for Windows/Windows Phone 8.1 Store apps
Economic-Forecasting
:
Contains Python code for downloading socio-economic data from Quandl and using it to forecast real-GDP growth rates in countries.
// repository documentation
Was this content helpful?
★ 0
(0 ratings)
Select Rating:
★
★
★
★
★
Submit Feedback
Recent Feedback
×
Download README
Do you want to download the
README.md
file for
goe
?
Download (.md)
# Go Enterprise Common enterprise features for the Go programming language. This is free and unencumbered software released into the [public domain](http://creativecommons.org/publicdomain/zero/1.0). [](https://github.com/pascaldekloe/goe/actions/workflows/go.yml) ## Expression Language [](https://pkg.go.dev/github.com/pascaldekloe/goe/el) GoEL expressions provide error free access to Go types. It serves as a lightweigth alternative to [unified EL](https://docs.oracle.com/javaee/5/tutorial/doc/bnahq.html), [SpEL](http://docs.spring.io/spring/docs/current/spring-framework-reference/html/expressions.html) or even [XPath](http://www.w3.org/TR/xpath), [CSS selectors](http://www.w3.org/TR/css3-selectors) and friends. ``` Go func FancyOneLiners() { // Single field selection: upper, applicable := el.Bool(`/CharSet[0x1F]/isUpperCase`, x) // Escape path separator slash: warnings := el.Strings(`/Report/Stats["I\x2fO"]/warn[*]`, x) // Data modification: el.Assign(x, `/Nodes[7]/Cache/TTL`, 3600) ``` #### Performance The implementation is optimized for performance. No need to precompile expressions. ``` goos: darwin goarch: arm64 pkg: github.com/pascaldekloe/goe/el BenchmarkLookups-8 4037929 268.3 ns/op BenchmarkAssigns-8 2855529 419.9 ns/op ``` ## Metrics [](https://pkg.go.dev/github.com/pascaldekloe/goe/metrics) Yet another StatsD implementation. ``` Go var Metrics = metrics.NewDummy() func GetSomething(w http.ResponseWriter, r *http.Request) { Metrics.Seen("http.something.gets", 1) defer Metrics.Took("http.something.get", time.Now()) ``` ## Verification [](https://pkg.go.dev/github.com/pascaldekloe/goe/verify) Test assertions on big objects can be cumbersome with ```reflect.DeepEqual``` and ```"Got %#v, want %#v"```. Package `verify` offers convenience with reporting. For example `verify.Values(t, "character", got, want)` might print: ``` --- FAIL: TestValuesDemo (0.00s) demo_test.go:72: verification for character: /Novel[6]/Title: Got "Gold Finger", want "Goldfinger" ^ /Film[20]/Year: Got 1953 (0x7a1), want 2006 (0x7d6) ```