Releases: ballerina-platform/ballerina-lang
Ballerina 0.975.0 Released!
Overview to Ballerina 0.975.0
Ballerina 0.975.0 is an iteration for Ballerina 0.970.0, which was released previously. This release has significant improvements to the standard library and IDE support. Apart from that, there are also some improvements made to the language syntax. Introduction of new BALO format has improvements on compilation time as well.
Compatibility and Support
New int range expression
Previously [x .. y]
syntax was used to represents an integer range in a foreach
statement. This syntax is now x ... y
in Ballerina 0.975.0.
Old syntax (0.970.1)
foreach val in [1 .. 5] {
io:println(val);
}
New syntax
foreach val in 1 ... 5 {
io:println(val);
}
Syntax change in record type definitions
The record type definition syntax now requires a record
keyword. The syntax used previously also works on Ballerina 0.975.0, but this will not be supported in future releases.
Old syntax (0.970.1)
type Person {
string name,
int age,
};
New syntax
type Person record {
string name,
int age,
};
Syntax change for the next statement
The next
statement is renamed to continue
.
Old syntax (0.970.1)
while (i < 5) {
i = i + 1;
if (i == 2) {
next;
}
}
New syntax
while (i < 5) {
i = i + 1;
if (i == 2) {
continue;
}
}
New blob literal support
base16
and base64
based literal values are the two types of literal values supported for blob. The base16
type has a base 16 based character sequence and the base64
type has a base 64 based character sequence or padded character sequence.
New syntax
blob a = base16 `aaabcfccad afcd34 1a4bdf abcd8912df`;
blob b = base64 `aaabcfccad afcd3 4bdf abcd ferf =`;
Variable shadowing removed
Now variables cannot be shadowed and are required to have unique names. The only exception is in XML namespaces that already have variable shadowing support.
Old syntax (0.970.1)
string name;
type User object {
private {
string name;
}
function setName(string name) {
self.name = name;
}
};
function print(string name) {
}
New syntax
string name;
type User object {
private {
string userName;
}
function setName(string n) {
self.userName = n;
}
};
function print(string n) {
}
Improvements
Standard Library
- Add capability to read/write fixed signed integer, float, boolean and string values via data IO APIs
- Error handling support for WebSocket service
@http:WebSocketServiceConfig {
path: "/error/ws"
}
service<http:WebSocketService> errorService bind { port: 9090 } {
onError(endpoint ep, error err) {
io:println(string `error occurred: {{err.message}}`);
}
}
- Allow different types of payloads to be used directly with HTTP client actions and response calls. E.g.,
response = clientEP->post("/test", xml `<color>Red</color>`);
response = clientEP->post("/test", { name: "apple", color: "red" });
_ = caller -> respond("Hello World!");
- Improve redirect functionality so that it supports both HTTP and HTTP2
- Support event notification payloads of different content types with WebSub
- HTTP name based virtual hosting support
@http:ServiceConfig {
basePath:"/page",
host:"abc.com"
}
- Improve the HTTP error handler to recover from source connection failure
- Enhance the API to control the circuit breaker status as per user requirements
http:CircuitBreakerClient cbClient = check <http:CircuitBreakerClient>clientEP.getCallerActions();
if (counter == 2) {
cbClient.forceOpen();
}
Build & Package Management
- Support to build reproducible builds using the lock file.
IDEs & Language Server
Composer
- HTTP Trace Log Improvements in Composer.
Language Server
- Add initial indexing support for Language Server.
- Improve Language Server error reporting.
- Add renaming support for variable symbols.
- Signature help support for action invocations.
- Match expression completion support with snippets.
- Completion support for function invocation scope.
- Code action improvements with generate function for undefined functions.
IntelliJ IDEA
- User repository support.
- Package auto-import support.
- New live templates.
- New code inspections.
- Performance improvements.
VSCode
- Syntax highlighting improvements.
Bug Fixes
Bug fixing was conducted as part of multiple release iterations based on the previous Ballerina 0.970.1 release. Please refer to the following GitHub milestones for bug fixes.
Getting Started
You can download the Ballerina distributions, try samples, and read the documentation at https://ballerina.io. You can also visit the Quick Tour to get started. We encourage you to report issues, improvements, and suggestions at the Ballerina Github Repository.
Ballerina 0.970.1 Released!
Overview to Ballerina 0.970.1
This is a patch release that mainly focused on fixing bugs in the previous release (0.970.0) and includes improvements in the language server and packaging.
Improvements
Packaging
- HTTP proxy support for pulling and pushing packages from Ballerina Central
IDEs & Language Server
- Improvements for Language Server Startup Time
- Add Documentation Support for Endpoints, Records and Objects
Bug Fixes
Please refer Github milestone to view bug fixes
Ballerina 0.970.0 Released!
Overview to Ballerina 0.970.0
We proudly announce General Availability of Ballerina 0.970.0. Download now! Ballerina 0.970.0 is an exciting new release of the programming language.
The 0.970.0 release represents significant changes from the 0.964.0 release and is not backwards compatible. This release represents the changes after a series of design reviews that had material impact on the language design, syntax, and toolchain. The changes are so significant that to those with previous exposure, Ballerina will appear as an entirely new language.
With these changes, the release notes cover the features of the language from a design point of view, and we are forgoing the traditional approach of release notes covering the incremental changes from release to release. We hope to hit 1.0 milestone before the end of 2018 and will guarantee backwards compatibility at that stage.
Key highlights of Ballerina capabilities included into this release are:
Concurrent: Worker support for defining parallel execution units with fork/join semantics, and asynchronous function invocations, which contains improved BVM scheduler functionality.
Transactional: First class support for transaction semantics, including distributed transactions.
Textual and graphical syntaxes: Sequence diagrams focused on showing worker and endpoint interactions. Endpoints represent network services. Each worker is sequential code, that can zoom in graphically yet represents really textual code. The design is meant to make it easier to understand complex distributed interactions
Integration specialization: Brings fundamental concepts, ideas, and tools of distributed system integration into the programming language and offers a type safe, concurrent environment to implement such applications. These include distributed transactions, reliable messaging, stream processing, workflows, and container management platforms.
Learn more about the Ballerina philosophy.
Language
Values and Types
Ballerina programs operate on a universe of values, and each value belongs to only one basic type such as int
, boolean
, map
, record
, function
, etc. There are three kinds of values corresponding to three kinds of basic types. They are simple values (e.g., int
, string
, boolean
), structured values (e.g., record
, map
, array
), and behavioral values (e.g., function
, object
).
Simple Basic Types
The types int
, float
, string
, boolean
, blob
, and nil
are called simple basic types because they are basic types with only simple values. Simple values are always immutable.
- nil - The
nil
type has only one value that is denoted by()
. - boolean - The
boolean
type has only two values namedtrue
andfalse
. The implicit initial value of a variable of typeboolean
isfalse
. - int - The
int
type denotes the set of 64-bit signed integers. The implicit initial value of a variable of typeint
is0
. - float - The
float
type denotes double precision IEEE 754 floating point numbers. The implicit initial value of a variable of typefloat
is+0.0
. - string - The
string
type denotes the set of sequences of unicode code points. The implicit initial value of a variable of typestring
is the empty sequence. - blob - The
blob
type denotes the set of sequences of 8-bit bytes . The implicit initial value of a variable of typeblob
is the empty sequence.
Structured Basic Types
Structured basic values create structures from other values. A structured value belongs to exactly one of the following basic types:
- Tuple - A
tuple
is an immutable list of two or more values of fixed length. - Array - Arrays are mutable lists of values with dynamic length where each member of the list is specified with the same type. The implicit initial value of an array is the array with a length of
0
. - Map - The
map
type defines a mutable mapping from keys that are strings to values of the same type. - Record - A mutable mapping from keys, which are strings, to values; specifies maps in terms of names of fields (required keys) and value for each field.
- Table - The
table
type is a data structure that organizes information in rows and columns. Can be used to create an in-memory table using a type constraint, insert data to it and then access/delete the data. - XML - The
xml
type represents a sequence of zero or more XML items. Each item can be an element, a text, a comment, or a processing instruction.
Behavioural Basic Types
The following are Ballerina's basic behavioural values.
- Function - A
function
with zero or more specified input parameter types and a single return type. - Future - A
future
value represents a value to be returned by an asynchronous function invocation. - Object - An
object
is a collection of public/private typed fields along with attached functions that allows you to create new, user-defined data types with behavior. The implicit initial value would be anobject
where each field has the implicit initial value for its type. - Stream - The
stream
type represents a stream of events, which allows publishing events to the stream and subscribing to receive events from the stream.
Other Types.
- Union Type - The
union
types are types whose set of values is the union of the value spaces of its component types. For example, you can use a variable of a union type to store astring
or anint
, but there is only one value at any given time. Syntactically, you can define a union type with component types separated by "|" (vertical bar). - Optional - One of the design principles of the type system of Ballerina is to eliminate null reference errors. Over the years, null reference errors have caused numerous system crashes, security vulnerabilities, etc. Optional types in Ballerina allows developers to identify where the value or the function is of type
T
optionally, for any T. You can syntactically represent this asT?
orT|()
. - Any - The
any
data type is the root of the Ballerina data types. It can represent a variable of any data type. When you do not have prior knowledge of the data type of your variable, you can assignany
as the type. Values of these variables can come from dynamic content such as the request and response messages and the user input. Theany
type allows you to skip compile-time data type checks. - JSON - JSON is a textual format for representing a collection of values: a simple value (
string
,number
,true
,false
,null
), an array of values, or an object. Ballerina has a single type namedjson
that can represent any JSON value. Thus,json
is a built-in union type in Ballerina, which can contain values of typestring
,float
,boolean
, anarray of any
, or amap of any
.
Expressions
Field access
Field access is the syntax of accessing child elements inside structural typed values, such as objects, records, JSON, XML, etc. Fields can be accessed using two operators:
- Dot operator - Name of the field precedes by a dot, e.g., foo.bar
- Index operator - Name of the field comes within two brackets. Name can be any
string
value expression, e.g., foo[bar]
Both of these operators perform the nil-lifting by default. That is, it allows to walk down the child fields, without worrying whether there will be null along the way. In an event of null, it will stop the navigation and the value of the entire expression will be null.
Array Access
Array elements can be accessed by the index using the index operator. The index always has to be an integer valued expression. Similar to accessing fields, accessing arrays also performs the nil-lifting default, e.g., foo[index], foo[2].
Match Expression
Match expression is a way of checking the type of an expression and executing some other expression based on the type of the first expression. It is a form of a type switch. Match expression contains patterns inside, with a type associated to it. Type of each pattern should be matched to at-least one of the types of the expression that is being tested.
Elvis Operator
Elvis operator is a conditional operator that can be used to handle null
values. It evaluates an expression and if the value is null
, executes the second expression. The elvis operator takes two operands and uses the '?:' symbol to form it.
Control Flow Statements
If/Else Statement
An if/else
statement provides a way to perform conditional execution. It contains three sections: an if
block, followed by multiple else if
blocks, and finally a single else
block. All the else if
blocks and the else
blocks are optional. Any number of statements can be defined inside each of these blocks.
Match Statement
A match
statement is a type switching construct that allows selective code execution based on the type of the expression that is being tested. The match
statement can have one or more patterns with a type associated to it. Each pattern have statements that will get executed if that type is matched.
While
The while
looping construct will iterate and execute the code block within the while block continuously, until the condition for while loop is true
.
Foreach
The foreach
looping construct will traverse through the items of a collection of data such as arrays, maps, JSON, and XML and execute the given code block.
With the above two looping constructs, statements such as break
and next
can also be used, where the break
statement would end the loop and next
statement would go to the next iteration in the loop.
Iterable Operations
Iterable operations can be used with types such as array
, map
, json
, table
, and xml
. Currently available iterable operations are map
, filter
, ...
Ballerina 0.970.0-beta7 Released!
Overview to Ballerina 0.970.0-beta7
This release includes improvements to the standard library APIs. The full list of APIs has been reviewed and enhancements incorporated with the intention of making the API usage simpler to the developer.
For example, the Request
parameter has been made optional in the signatures of the HTTP client functions for standard HTTP methods. This makes the usage much simpler for developers.
http:Request req = new;
var clientResponse = clientEP->get("/echo"); // Passing a request is optional
var clientResponse = clientEP->get("/echo", request = req);
Another example of the API refactoring from HTTP package is the merge of both Client
and SimpleClient into a single endpoint called Client
.
The simplified use of a sample of FailoverClient
configuration now looks like:
endpoint http:FailoverClient ClientEP {
timeoutMillis:5000,
failoverCodes:[501, 502, 503],
intervalMillis:5000,
targets:[
{
url:"http://localhost:3000/mock1"
},
{
url:"http://localhost:8080/echo",
secureSocket:{
trustStore:{
filePath:"${ballerina.home}/bre/security/ballerinaTruststore.p12",
password:"ballerina"
},
verifyHostname:false,
shareSession:true
}
},
{
url:"http://localhost:8080/mock2"
}
]
};
A sample of Client
configuration:
endpoint http:Client clientEP {
url:"http://localhost:8080/mock",
timeoutMillis:5000
};
Numerous similar refactoring have been done across the standard library API and you can find further details by referring latest API documentation.
Compiled version of a Ballerina package support, in short form referred to as “balo” in developer community, has been added to this release.
When packages are built into a .balo, they will be installed into the project repository.
ballerina build -c <package> [-o <output-file>.balo]
This release ships many stabilization enhancements to the type system elements that were introduced in 0.970.0-beta0. All other parts of the language implementation have been stabilized with many fixes.
Compatibility and Support
You will have to update the API usage in sync with the API enhancements. Please use the latest API documentation to explore the latest API.
Improvements
Language & Runtime
- Standard library API enhancements and refactoring
- Compiled version of a Ballerina package (balo) support
Getting Started
You can download the Ballerina distributions, try samples, and read the documentation at https://ballerina.io. You can also visit Quick Tour to get started. We encourage you to report issues, improvements, and suggestions at Ballerina Github Repository.
Ballerina 0.970.0-beta1 Released!
Overview to Ballerina 0.970.0-beta1
This release has improvements to the main
function argument passing model where the user will not have to wrestle with string
array to access command line parameters.
function main (string... args) {
io:println("Hello, World!");
}
Auto completion support is added in language server / IDE for match statements to help unions to be matched and tuples have to be destructured.
This release also introduces the message broker. Ballerina Message Broker is a lightweight, easy-to-use, message-brokering server. It uses AMQP 0-9-1 as the messaging protocol. This release embeds the message broker into the Ballerina platform distribution.
Enhancements to manage configurations and anonymous endpoints for Kubernetes and Docker has been introduced in this release.
The new configuration management model enables you to define what to be copied into the container from within your program.
@kubernetes:Deployment {
copyFiles:[
{
target:"/home/ballerina/data/data.txt",
source:"./data/data.txt"
}
]
}
The command line syntax for passing runtime configuration using toml file looks like the following
% ballerina run --config something.toml foo.bal[x] [program args]
You can now do this using code from within your program itself.
@kubernetes:ConfigMap {
ballerinaConf:"./conf/ballerina.conf"
}
You can also pass any configurations in addition to runtime configurations using the following syntax in this release.
@kubernetes:ConfigMap {
configMaps:[
{
mountPath:"/home/ballerina/data",
data:["./conf/data.txt"]
}
]
}
The container can be configured with anonymous endpoints using the following syntax
@docker:Config {}
service<http:Service> helloWorld bind {} {
sayHello(endpoint outboundEP, http:Request request) {
// your service code here
}
}
The above code will automatically bind post 9090 inside the container for helloWorld
service.
Apart from these enhancements, this release ships many stabilization enhancements on top of the previous release, which was 0.970.0-beta0.
Compatibility and Support
There are no compatibility and support changes from 0.970.0-beta0 other than the syntax change of main (string... args)
Improvements
Language & Runtime
- Main method argument parameters has been changed as main (string... args)
IDEs & Language Server
- “match” expression completion support in Language server
Ballerina Message Broker
- Include message broker inside Ballerina platform distribution and should be able to start the broker from the bin
Ballerina Extensions
- Added copy file support to Kubernetes and Docker images
- Added first class support for BallerinaConf and remove name, mount path request from the user
- Add anonymous endpoint support for Kubernetes and Docker
Getting Started
You can download the Ballerina distributions, try samples, and read the documentation at https://ballerina.io. You can also visit Quick Tour to get started. We encourage you to report issues, improvements, and suggestions at Ballerina Github Repository.
Ballerina 0.970.0-beta0 Released!
Overview to Ballerina 0.970.0-beta0
This release packages significant enhancements to Ballerina language syntax and type system.
The enhancements include the introduction of object type where you can either define the methods of the object within the definition itself or you can bind them from outside the object.
public type Response object {
public {
@readonly int statusCode;
string reasonPhrase;
string server;
ResponseCacheControl cacheControl;
}
private {
int receivedTime;
int requestTime;
}
public function setStatusCode(int statusCode);
}
//when binding to the object
public function Response::setStatusCode(int statusCode) {
self.statusCode = statusCode;
}
We have introduced union type in this release. Union types are types whose set of values is the union of the value spaces of its participant types. Note that with the introduction of union and type switching, we no longer need type casting
type json (string | float | int | boolean | null | map<json> | json[]);
The match statement is introduced to help manage union constructs. Unions have to be matched and tuples have to be destructured using the match statements.
function getPersonFromDB(string name) returns (string,int,float)|error {
// Do a DB lookup and load the person from the table
// If an error occurs while doing the DB lookup, return error
}
var r = getPersonFromDB(“sam”);
match r {
(string name, int age, float salary) => {
io:println(name);
io:println(age);
io:println(salary);
}
error err => {
io:println(“Error occurred while loading person:” + err.message);
}
}
A but
expression is also introduced facilitate expression evaluation. If the value of the evaluated expression matches to some given type, then we can update the result for a prefered value.
int x = p but {
string => 1,
float f => <int> f
}
The safe navigation operator has been enhanced to allow safe navigation in the event of null or an error. This will be useful with maps that now have error as common response status.
Nil-lifting navigation has been introduced to help eliminate null pointer exceptions.
Error-lifting navigation has been introduced where you can lift errors when navigating through fields, using the “!” operator.
type Person {
Info|() info;
};
type Info {
Address|() address;
};
type Address {
string street;
string city;
string country = "Paradise";
};
// nil lifting
// in the following code even if p is nil,
// it will not throw a runtime NPE, but instead y’s value will be nil.
function foo () {
Person|() p;
string|() y = p.info.address.city;
}
// error lifting
// in the following code, if the value of p.info or p.info!address is 'error',
// then the value for the whole rhs expression will be error.
function foo () {
Person p = something;
string|() y = p.info!address!city;
}
This release has replaced const with @Final for defining constants.
@final string TXN_STATE_ACTIVE = "active";
This release has also replaced enums with types, where you can define a new type with a pipe (‘|’) separated list of values.
type TransactionState "active" | "prepared" | "committed" | "aborted";
@final TransactionState TXN_STATE_ACTIVE = "active";
@final TransactionState TXN_STATE_COMMITTED = "committed";
An error elimination operator has been introduced. You can use the operator if there are errors returned from a function, they will be thrown. You need to use this with caution when you are absolutely sure that an error won’t be returned or the error will be handled by upstream code.
int x =? foo();
A new concept of nil has been introduced. Note that nil is not the same as null. null should be avoided in general and we have to use nil, which is denoted with , (). null is now only used with JSON type, because, possible set of values for JSON is a union of several types including null.
Person? p = getPerson(“john”); // NOTE: Person? Is a syntactic shortcut for Person|()
match p {
Person p1 => {
string name = p1.name;
io:println(name);
}
() => {
io:println(“Person does not exist”);
}
}
This release also introduced first class support for streaming event processing. It allows you to build streaming queries with user friendly syntax. The queries include projection, filtering, windows, stream joins ,and patterns.
//Create a stream that is constrained by the StatusCount struct type.
stream<StatusCount> filteredStatusCountStream;
//Create a stream that is constrained by the Teacher struct type.
stream<Teacher> teacherStream;
// Create a forever statement block with the respective streaming query.
// Write a query to filter out the teachers who are older than 18 years, wait until three teacher
// object are collected by the stream, group the 3 teachers based on their marital status,
// and calculate the unique marital status count of the teachers.
// Once the query is executed, publish the result to the `filteredStatusCountStream` stream.
forever{
from teacherStream where age > 18 window lengthBatch(3)
select status, count(status) as totalCount
group by status
having totalCount > 1
=> (StatusCount [] status) {
filteredStatusCountStream.publish(status);
}
}
Improvements
Language & Runtime
const
keyword has been replaced with@final
enum
concept is replaced with ‘type` creation- Introduction of
object
type, union types and nil type - Introduction of
@readonly
annotation - Safe navigation support, introduction of error elimination operator, match
and
but` statements - Multiple value return type function concept is removed and replaced with the ability to return tuples
- Inline tuple destructuring capability
- Introduction of streaming capabilities, table literal support, transaction commit/failure callbacks
- Introduction of fail statement
- Removal of transformer syntax
Standard Library
Config API
- Improved API with support for retrieving configs of different data types
- Support for securing sensitive data
HTTP
- Support for HTTP caching, HTTP access logs, connection throttling and HTTP version 2 (HTTP/2)
- Support for publishing HTTP trace logs to sockets and files
- Support for service versioning and per service chunking configuration
- Improved APIs for HTTP header related operations and OCSP stapling for checking the revocation status of certificates
- Introduce a new method called
setPayload()
to http request and response to take any (string, xml, json, blob, io:ByteChannel or mime:Entity[]) type of payload
MIME
- Introduce a new method to get the base type from a given content type and a new method to set any(string, xml, json, blob,io:ByteChannel or mime:Entity[]) type of body to entity
- Improve entity body operations to rely on content type and APIs for MIME specific base64 encoding / decoding
WebSocket
- The WebSocket upgrade resource has been moved to the Http Service
- A new function called acceptWebSocketUpgrade has been introduced to the http:Listener
- The WebSocket resource signatures have endpoints and not WebSocketConnector as the first argument.
- The WebSocket resource signatures now have basic data types instead of the frames in previous implementations.
WebSub
- Support for WebSub subscriber, hub and publisher to facilitate communication between publishers and subscribers of Web content based on HTTP web hooks
Observe
- Support for observability through metrics and tracing APIs
SQL
- Support MySQL and H2 packages to interactions with respective DBs.
- Add mirror table support to read write directly via tables
Util
- Improved APIs for base64 encoding and decoding
IDEs & Language Server
Language Server
- Support find all references, go to definition and hover provider support for match expression, tuple support, union type support, final and readonly variables, endpoint, new service syntax, and object and record statements.
- Support documentation syntax, annotation syntax and completion support for records, objects and endpoints syntaxes
Composer
- Introduction of trace log analyzer tool
- Support match statement visualization in diagram and source generation support for match statement, transaction statement
- Removal of transformer UI
Ballerina API Gateway
- Annotation support for securing Services
- API Endpoint which is secured by default
- HTTP request interceptor support
- Simple file based userstore
- Basic and JWT based authentication
Ballerina Observability
- Add out of the box observability through Logging, Metrics and Distributed Tracing
Ballerina Extensions
- Add ballerina config file support for docker annotations
- Add ballerina config file support for kubernetes annotations
Getting Started
You can download the Ballerina distributions, try samples, and read the documentation at https://ballerina.io. You can also visit Quick Tour to get started. We encourage you to report issues, improvements, and suggestions at Ballerina Github Repository.
Ballerina 0.964.0 Released!
Overview to Ballerina 0.964.0
This release introduces Struct initializer for the Ballerina language and Transaction Coordinator. Apart from that there are improvements in HTTP connectors of Standard Library and Code Action, Find All reference support of Language Server.
Improvements
- Language & Runtime
- Introduce struct initializers. Struct initializer is a block of code wrapped in a function that’s called when a new struct instance is created.
- Standard Library
- Introduce forwarded extension config as HTTP client connector option
- Ability to set/retrieve byte channel as HTTP request/response payload
- Allow multiparts to be sent/retrieved through HTTP response
- Ability to encode nested parts in a multipart entity
- Maximum wait time configuration capability in HTTP client connector for connection throttling
- Introduce Ballerina to Ballerina distributed transactions.
- Improve keep-alive config in HTTP server connector
- Failover implementation for the HTTP client connector
- Circuit breaking support over HTTP status codes
- Build & Package Management
- Support flat packaging structure with dots in name.
- IDEs & Language Server
- Composer Improvements
- New flow diagram based design for fork-join statement
- Context menu in source editor supporting go to definition and find all references
- Language Server
- Introduce Code Action support
- Introduce Workspace Command Execution Support
- Package Auto Import Support
- Add find all references support for default package
- Add find all references support for definitions of transformer, connector, action, service, resource, function, struct.
- Add Auto Completion Support in Endpoint Definition
- Ballerina Transaction Coordinator
- Support for distributed transactions with 2-phase commit coordination
Bug Fixes
Getting Started
You can download the Ballerina distributions, try samples, and read the documentation at http://ballerinalang.org. You can also visit Quick Tour to get started. We encourage you to report issues, improvements, and suggestions at Ballerina Github Repository.
Ballerina 0.963.0 Released!
What’s new in Ballerina 0.963.0
Ballerina Language improvements
- Improved table syntax with in memory table type support
Ballerina Composer improvements
- Transformer iterable operation source generation support
Ballerina Standard Library improvements
- Support a variety of multipart media types (multipart/form-data, multipart/mixed, multipart/alternative etc..) with inbound and outbound requests
- Add support for decoding nested parts within a multipart entity upto any level
- A new method (called setFileAsPayload) has been introduced to outbound request and outbound response to set a file as payload
- Certificate revocation verification with CRL and OCSP.
- Hostname verification.
- HTTP data binding support.
- Load Balancer implementation for the HTTP client connector.
- HttpOnly and Secure flags for HTTP session cookie.
- Add configurations to enable or disable compression
- Move File and Channel open functions to IO package level.
- Introducing DelimitedRecordChannel as a replacement for TextRecordChannel
Ballerina Language Server improvements
- Find all references language feature support
- Go to definition support for transformer statement
- Completions and suggestion for parameter context
- Variable prioritization for context aware completion item ordering
- Completion and Suggestion inside endpoint definition context
- Bug Fixes
Getting started
You can download the Ballerina distributions, try samples, and read the documentation at http://ballerinalang.org.
Ballerina 0.962.0 Released!
What’s new in Ballerina 0.962.0
Ballerina Language improvements
- Functional iteration support for tables.
Ballerina Composer improvements
- Service view now shows paths and verbs.
- Transformer support for iterable operation rendering.
Ballerina Standard Library improvements
- Support for honoring Accept-Encoding and Content-Encoding headers in HTTP Client/Server connector.
- Redirect function for HTTP InRequest.
- Fix memory leak in WebSocket.
Ballerina Language Server improvements
- Introduce filtering and sorting mechanism for completion.
- Introduce go to definition support between packages.
- Add completion support for lock statement.
- Add trigger characters for completion to invoke completion on input.
- Fix type name resolving issue for service and connector.
Getting started
You can download the Ballerina distributions, try samples, and read the documentation at http://ballerinalang.org.
Ballerina 0.961.0 Released!
What’s new in Ballerina 0.961.0
Ballerina Language improvements
- Concurrency management / Isolation support
- Functional iteration support
- Foreach statement for tables and constrained table type support
- Subtype polymorphism for structs
Ballerina Runtime improvements
- URL length validation with HTTP 413 response
- HTTP request entity body size validation with HTTP 414 response
- Support for HTTP 1.0 request/response on server/client connector
- Make server/client connectors more resilient to remote host misbehaviours (i.e. abruptly ending the inbound request/response)
Ballerina Standard Library improvements
- New Vector collection type with support for list operations
- Matrix parameter support for HTTP
- Introduce the URL encode/decode functionalities
- Add Query Param Support for WebSockets
- Introduce support function to extract value and parameters of HTTP headers
Ballerina Composer improvements
- Transaction block layout changed to match flow diagram
- Zoom In / Out option to the diagram
- Fit to page width option for diagram
- More compact layout for services
- In split view source editor will be displayed to left
Ballerina Language Server improvements
- Improvements for signature help
- Hover support for Fork Join, Worker Receiver and Sender and string template literals
- Completion support for forEach construct
- Completion Support improvements for Top Level constructs
- Go to definition support for Connector, Action, Enum and Variables.
- Bug Fixes
Getting started
You can download the Ballerina distributions, try samples, and read the documentation at http://ballerinalang.org.