This is an automated email from the ASF dual-hosted git repository.
git-site-role pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/plc4x-website.git
The following commit(s) were added to refs/heads/asf-site by this push:
new 8ce7db4 Site checkin for project PLC4X: Jenkins Tools
8ce7db4 is described below
commit 8ce7db4c5c8d829204e6e07e9c83a995a58a9dbc
Author: jenkins <[email protected]>
AuthorDate: Tue Feb 18 15:47:09 2020 +0000
Site checkin for project PLC4X: Jenkins Tools
---
developers/release/release.html | 26 ++++++++++++--------------
plc4j/index.html | 28 ++++++++++++++++------------
2 files changed, 28 insertions(+), 26 deletions(-)
diff --git a/developers/release/release.html b/developers/release/release.html
index c2c8347..f381e52 100644
--- a/developers/release/release.html
+++ b/developers/release/release.html
@@ -809,15 +809,15 @@ You can achieve the above by following [4].
</div>
<div class="listingblock">
<div class="content">
-<pre> E-Mail Topic:
- [DISCUSS] Apache PLC4X 0.7.0 RC1
+<pre>E-Mail Topic:
+[DISCUSS] Apache PLC4X 0.7.0 RC1
- Message:
- This is the discussion thread for the corresponding VOTE thread.
+Message:
+This is the discussion thread for the corresponding VOTE thread.
- Please keep discussions in this thread to simplify the counting of votes.
+Please keep discussions in this thread to simplify the counting of votes.
- If you have to vote -1 please mention a brief description on why and then
take the details to this thread.</pre>
+If you have to vote -1 please mention a brief description on why and then take
the details to this thread.</pre>
</div>
</div>
<div class="paragraph">
@@ -838,9 +838,7 @@ You can achieve the above by following [4].
[RESULT] [VOTE] Apache PLC4X 0.7.0 RC1
Message:
-So, the vote passes with 3 +1 votes by PMC members and one +1 vote by a non
PMC member.
-
-{Release Manager Name}</pre>
+So, the vote passes with {number of +1 votes} +1 votes by PMC members {number
of +1 votes from non-pmc members} +1 vote by a non PMC member.</pre>
</div>
</div>
</div>
@@ -991,18 +989,18 @@ This is done by changing the <code>download.adoc</code>
under <code>src/site/use
</div>
<div class="listingblock">
<div class="content">
-<pre> From:
+<pre>From:
your apache email address
- To:
+To:
[email protected]
- CC:
+CC:
[email protected]
- E-Mail Topic:
+E-Mail Topic:
[ANNOUNCE] Apache PLC4X 0.7.0 released
- Message:
+Message:
The Apache PLC4X team is pleased to announce the release of Apache PLC4X 0.7.0
PLC4X is a set of libraries for communicating with industrial programmable
diff --git a/plc4j/index.html b/plc4j/index.html
index b39f905..4c7cb49 100644
--- a/plc4j/index.html
+++ b/plc4j/index.html
@@ -181,8 +181,6 @@ import org.apache.plc4x.java.PlcDriverManager;
import org.apache.plc4x.java.api.PlcConnection;
import org.apache.plc4x.java.api.messages.PlcReadRequest;
import org.apache.plc4x.java.api.messages.PlcReadResponse;
-import org.apache.plc4x.java.api.messages.PlcWriteRequest;
-import org.apache.plc4x.java.api.messages.PlcWriteResponse;
import org.apache.plc4x.java.api.types.PlcResponseCode;
import org.apache.plc4x.java.api.value.PlcValue;
import org.slf4j.Logger;
@@ -219,9 +217,9 @@ public class HelloPlc4x {
// Create a new read request:
// - Give the single item requested the alias name "value"
- /*PlcReadRequest.Builder builder =
plcConnection.readRequestBuilder();
+ PlcReadRequest.Builder builder =
plcConnection.readRequestBuilder();
for (int i = 0; i < options.getFieldAddress().length; i++) {
- builder.addItem("r-" + i, options.getFieldAddress()[i]);
+ builder.addItem("value-" + i, options.getFieldAddress()[i]);
}
PlcReadRequest readRequest = builder.build();
@@ -233,16 +231,22 @@ public class HelloPlc4x {
PlcReadResponse syncResponse = readRequest.execute().get();
// Simply iterating over the field names returned in the response.
printResponse(syncResponse);
- PlcValue asPlcValue = syncResponse.getAsPlcValue();
- System.out.println(asPlcValue);*/
- final PlcWriteRequest.Builder writeRequestBuilder =
plcConnection.writeRequestBuilder();
- writeRequestBuilder.addItem("w-1", options.getFieldAddress()[0],
23, 42, 7);
- PlcWriteRequest writeRequest = writeRequestBuilder.build();
- System.out.println(writeRequest);
+ PlcValue asPlcValue = syncResponse.getAsPlcValue();
+ System.out.println(asPlcValue);
- logger.info("Synchronous write ...");
- final PlcWriteResponse plcWriteResponse =
writeRequest.execute().get();
+ //////////////////////////////////////////////////////////
+ // Read asynchronously ...
+ // Register a callback executed as soon as a response arrives.
+ logger.info("Asynchronous request ...");
+ CompletionStage<? extends PlcReadResponse> asyncResponse =
readRequest.execute();
+ asyncResponse.whenComplete((readResponse, throwable) -> {
+ if (readResponse != null) {
+ printResponse(readResponse);
+ } else {
+ logger.error("An error occurred: " +
throwable.getMessage(), throwable);
+ }
+ });
// Give the async request a little time...
TimeUnit.MILLISECONDS.sleep(1000);