SOS: New query feature: Native Query

Added by achristian about 7 years ago

Beside the standard query mechanism, where developers can implement their own query condition, there's now a new mechanism called native query.

With the normal query, each stored object of class XYZ is compared against the condition-implementation. For only a few objects this is maybe acceptable. But if you have several hundrets or thousand objects of one type, the query will be too CPU intensive and time consuming.

The new native query enables you to specify your query with a native API.

An example:

Mission: Get all stored objects of type MySpecialClass which have integer field "myIntValue" in range 50..100

Old Query:

Query query = storage.query(MySpecialClass.class);
query.setCondition("myIntValue", new Condition<Integer>() {

      public boolean condition(Integer variable) {
          if (variable>=50 && variable<=100) {
              return true;
          return false;
List resultList = query.execute();

Internally, all stored objects of type MySpecialClass are feed into the condition-implementation. So all objects have to be watched. The more objects you have stored, the longer the query takes ---> O(n).

New native Query:

NativeQuery query = storage.nativeQuery(MySpecialClass.class);
query.setCondition(Logic.and("myIntValue", 50), Comparison.le("myIntValue", 100)));
List resultList = query.execute();

With the new API you can of course create a condition with many different field...
No matter how many objects you have stored. SOS translates your native query into a query that is natively understandable by the used backend. So runtime is considerably less than O(n).

SOS: Backend changed ...

Added by achristian over 7 years ago

Last weekend I found some time to work on SOS. The file-based backend was fault-prone and not running stable enough. Instead of inventing the wheel (file as database structure) again, I switched the backend to a sql-based backend. This a) improves performance (as the file-backend of the SQL database is well tested)
b) saves development-time
c) opens us some cool features in future, like store on network, store in cluster, ... but this is still future music ...

USB-KeyLock: Ask for already attached devices

Added by achristian over 7 years ago

For linux users there's now a device cache:

As soon as a device is attached to the system, the udev-scripts will cache them. The UsbKeyLock API is then able to ask for those cached devices.
This is useful if a device has been attached before the application has been started.

Of course, the listener-functionality is still working.

SIMON: IANA teil SIMON Port zu ...

Added by achristian over 7 years ago

Heute morgen erreichte mich folgende Email:

Dear Alexander Christian:

Your request has been processed. We have assigned the following
registered port number to SIMON with you as the point of contact:

simon4753tcpSimple Invocation of Methods Over Network (SIMON)

simon-disc4753udpSimple Invocation of Methods Over Network (SIMON) Discovery

The expert review for this request was completed by: Eliot Lear


Konkret heisst das:

SIMON darf den TCP Port 4753 nun offiziell für die RPC Kommunikation nutzen. UDP Port 4753 wird für die Servererkennung genutzt.
Die Änderungen werden in den kommenden Tagen in den SVN trunk eingepflegt.

SIMON: Bewerbung für IANA Port Zuteilung

Added by achristian over 7 years ago

Getreu dem Motto "Unser SIMON soll besser werden", hat sich SIMON nun bei der IANA( um einen offiziellen Port beworben. In rund 14 Tagen soll ein erster Bewerbungsstatus-Bericht vorliegen.
Wenn das klappt, dann hat die Sucherei für den idealen Port für SIMON ein Ende ...

Ich werde wieder berichten wenn es Neuigkeiten gibt....

jPMdbc: Moved from to

Added by achristian about 8 years ago

I finally got it managed to move the "old" project from to this new location. Although the project is not actively maintained, the current status runs very well. Please dop me a message in the forums if you face problems or so ...

1 2 3 4 5 (11-20/42)

Also available in: Atom