Code Monkey home page Code Monkey logo

jmcnet-full-mongo-flex-driver's People

Contributors

jmcollin78 avatar

Watchers

 avatar  avatar  avatar

jmcnet-full-mongo-flex-driver's Issues

Which way can be subscribed forum ?

Sorry for posting here, but really didnt find another way, i subscribed forum 
for this porject but had no acceptance afetr one week, how can be done ? thank 
you

Original issue reported on code.google.com by [email protected] on 14 Nov 2014 at 10:40

CallBack Function not working

Hi,

i able to get the connection to MONGODB,i can able create the data in to 
database, 

issue is,i tried to retrieve the data from database,

after executing the query callback function not invoked 

please find the code below

var query:MongoDocumentQuery = new MongoDocumentQuery(); 
mongoDriver.queryDoc("reporting_serialization6",query, onMyResponseReceived);

//call back function 
public function onMyResponseReceived (responseDoc:MongoDocumentResponse)
{ 
  Alert.show(ObjectUtil.toString(ac));
}

it is very difficult to debug this issue,

i found source code 1.1 version at SVN, if it is possible can you upload 1.4 
version source to SVN

so i can debug the issue. where it is missing.


thanks
Santhosh

Original issue reported on code.google.com by [email protected] on 22 Aug 2012 at 2:19

Add a convenience "collection" property to the MongoDocuments returned from a response

As you can only query from one collection at a time, it would be handy, if the 
MongoDocuments returned in the MongoDocumentResponse object had a property 
"collection", filled with the collection used in the query.

This is useful if doing a subsequent update on the same object. Something like:

driver.queryDoc( "someCollection", new MongoDocumentQuery, new MongoResponder( 
this._onResponse ) );

private function _onResponse( response:MongoDocumentResponse ):void
{
    var doc:MongoDocument = response.documents[0];
    var query:MongoDocumentUpdate = new MongoDocumentUpdate;
    ...

    driver.updateDoc( doc.collection, query, new MongoResponder( this._onUpdate ), false, false );
}

Original issue reported on code.google.com by [email protected] on 18 Oct 2012 at 8:50

toObject on ArrayCollection does not work

Hi,

First off all, thank you so much for creating this brilliant product! It is 
really amazing and makes the software development much more easier and faster.

Though I have no issues in adding ArrayCollection into the MongoDocument, when 
it comes to retrieve, I'm unable to cast down the output to ArrayCollection 
using  toObject().

I'm not sure if I am missing anything? Or perhaps, because ArrayCollection is 
not part of core ActionScript, this is not supported. I'm clue-less basically.

It would be really nice, if you could throw some lights on the above.
Thank in advance...

Regards,
Tharma

Original issue reported on code.google.com by [email protected] on 18 Aug 2012 at 4:25

Decoding fail.

What steps will reproduce the problem?
1. Create object with AS3 code:
    var object:Object = { literalValue: "hello", objectWillBeHere: { }, integralValue: 123, anotherLiteral: "world" };
    object.objectWillBeHere = { justInt: 777, literal: "inner", arrayHere: [] };
    object.objectWillBeHere.arrayHere = [ { withJustInt: 666 }, { withJustString: "within array" }, { withObject: { first: "my address", second: 5 }, andString: "philadelphia" } ];

2. Encode it:
    var asBson:ByteArray = BSONEncoder.encodeObjectToBSON( object );

3. Try to decode with:
    var fromBson:Object = BSONDecoder.decodeBSONToMongoDocument( asBson );

Fails with exception "BSONDecoder : TypeElement : '116' not implemented".

Obtained the source from repository "right now".

Thank you.

Original issue reported on code.google.com by [email protected] on 24 Dec 2012 at 10:55

AsyncResponder with Token

Hi,
How are you?

I'm just wondering if we possibly can add a AsyncResponder to carry a "Token". 

Please refer this example below:
http://code.google.com/p/assql/wiki/Examples#Token_Responder_Example_1

Besides the basic requirement of making sure the response is correctly handled 
based on the request, we can also pass certain information into the responder 
through this token...

Please let me know what your thoughts on this?

Regards,
Tharma

Original issue reported on code.google.com by [email protected] on 23 Aug 2012 at 11:30

Date UTC is not correctly encoded

The driver does not handle UTC format. Little indian encoding is not respected 
for date. This can lead to incorrect date manipulation (ie with aggregation 
framework for example).

Original issue reported on code.google.com by [email protected] on 25 Aug 2012 at 10:11

Add the possibility to specify the socket in database operation

This aims to provided a simple way to sequentialize commands across MongoDB 
database.
This is very usefull when you are in non safe mode. In this mode, there is no 
callback called for common operation like update, create, delete for example. 
So you will never be sure that a command won't be executed before a second one 
- unless if you force the reuse of the same socket.

Priority should be strong as it provide a very simple way to many user's 
request.

The JMCNet Team

Original issue reported on code.google.com by the.jmcnet.team on 27 Aug 2012 at 8:14

Add a "showCollections" new command in the driver.

The nedd is to get all the collections of a database.
The solution is there (thank's to divillysausages) : 
https://groups.google.com/forum/?fromgroups=#!topic/jmcnet-full-mongo-flex-drive
r/lRUhwS7GkaU


Original issue reported on code.google.com by the.jmcnet.team on 16 Oct 2012 at 9:13

collection joins [querying docs across collections]

Hi,

I believe extending a query functionality to support fetching documents by 
joining two or more collections based on a certain key. This would be similar 
to what SQL offers.
As you know, the way we could accomplish that in monogo console would be like 
this -

var o = db.orders.findOne({_id:"q179"});
var name = db.customers.findOne({_id:o.custid})

Presently using our JMCNet Mongo Driver, we need to fire two sequential queries 
that of course, get executed in asynchronous way. So my suggestion here is to 
make that as a single query. Perhaps something like this:

//MongoDocumentQuery: defines the filter criteria within the collection
var docs1:* = queryDoc(<collection1>, new MongoDocumentQuery() ); 

var docs2:* = queryDoc(<collection2>, new MongoDocumentQuery() );

//new type of query: JoinQuery
var jq:MongoDocumentJoinQuery = new MongoDocumentJoinQuery(docs1);
jq.addJoinCriteria(left(docs2).on(docs1.Id,docs2.ID);     //left, inner can be 
supported with priority(outer, right )
mongoDriver.queryDoc( jq, onResponseReceived);

Please let me know what your thoughts are...

Thanks,
Tharma

Original issue reported on code.google.com by [email protected] on 26 Aug 2012 at 9:47

Remove the calls to toString()

Flash will call toString() automatically when an object is concatenated to a 
String. Removing the explicit calls means that you can pass null as the query 
to the queryDoc() function (if you're searching for all or a specific number of 
documents, but with no particular search criteria).

It also means you can remove code such as "((obj != 
null)?obj.toString():"null")" as if obj is null, it'll print "null" 
automatically

Original issue reported on code.google.com by [email protected] on 18 Oct 2012 at 8:36

Add DBRef support and automatic deferencement

http://www.mongodb.org/display/DOCS/Updating+Data+in+Mongo
I want the example about DBRef to work.

Thank's

Original issue reported on code.google.com by the.jmcnet.team on 26 Aug 2012 at 11:30

MongoDocumentUpdate and multiple modifier operations

When updating a mongo document and using modifiers, according to 
http://www.mongodb.org/display/DOCS/Updating#Updating-ModifierOperations, "most 
modifier operators will accept multiple field/value pairs when one wishes to 
modify multiple fields".

With the code:

var query:MongoDocumentUpdate = new MongoDocumentUpdate;
query.addUpdateCriteria( "$set", new MongoDocument("x", 1) );
query.addUpdateCriteria( "$set", new MongoDocument("y", 2) );

should result in a query like this:

{ $set : { x : 1 , y : 2 } }

whereas the actual result is:

{ $set : { y : 2 } }

as the set addUpdateCriteria() will overwrite the first. NOTE: using a 
different modifier will work, but again, only for one.

To get around this, you need to create your query like this:

var doc:MongoDocument = new MongoDocument;
doc.addKeyValuePair( "x", 1 );
doc.addKeyValuePair( "y", 2 );
var query:MongoDocumentUpdate = new MongoDocumentUpdate;
query.addUpdateCriteria( "$set", doc );

Maybe an additional method could be added: appendUpdateCriteria(), or 
addModifierCriteria(), with the signature ( String (modifier), key, value ). If 
the modifier doesn't exist already, a new MongoDocument is created internally. 
It if does exist, then key and value are added as normal through 
addKeyValuePair().

Original issue reported on code.google.com by [email protected] on 18 Oct 2012 at 9:01

Remove the automatic calls to toObject() when receiving a response

When you make a call, you get a MongoDocumentResponse object, with a list of 
MongoDocuments in the documents[] array.

To print your explanation of the toObject() function for clarification:

"Concerning your question about the MongoDocument.toObject() method, you’re 
right, you don’t need to call it on Response because the driver do it for you 
in the interpretedResponse field.

But suppose you had a Data Transfert Object (DTO) or ValueObject (VO) to 
interact with Java (for example). You need to transform a generic MongoDocument 
into an Object with fields. This method filled the fields of the DTO with the 
generic MongoDocument.

- The DocumentResponse contains 2 kinds of response : the documents[] array 
with contains an array of MongoDocument. You can use getKeys and getValue but 
if you want to transform those documents into object (generic object, DTO or 
VO) you need the “.toObject” method,

- The interpretedResponse which contains the documents[] treated by an 
Interpreter class. If you use this interpretedResponse you don’t need the 
toObject method."

InterpretedResponse will be filled even if you're not using it (as in you're 
only using the MongoDocuments documents[] array directly), meaning toObject() 
is always called, meaning Objects are created and populated in any case. Only 
filling interpretedResponse when it's needed (i.e. called) would help memory & 
speed if you're just using the stock MongoDocuments

Original issue reported on code.google.com by [email protected] on 18 Oct 2012 at 8:42

toBSON() on MongoDocumentQuery seems have some issues...

Hi,

I got the below error when i attempted to do something like this:

//creating a MangoDocument
var query:MongoDocumentQuery = new MongoDocumentQuery();

//defining criteria
query.addQueryCriteria("rank" , MongoDocument.lte(1000));

//I convert the Document into ByteArray because I need to get the count of docs 
first 
var queryDocByteArray:ByteArray = query.toBSON();

//invoke this count
mongoDriver.count("My_Collection",  
BSONDecoder.decodeBSONToMongoDocument(queryDocByteArray), onCountReceived);     
---------------------------------------

Error: Error #2030: End of file was encountered.
    at flash.utils::ByteArray/readUnsignedInt()
    at jmcnet.mongodb.bson::BSONDecoder$/bsonReadDocument()[E:\jmc\Projets\jmcnet\workspace\JMCNetMongoFlex\src\jmcnet\mongodb\bson\BSONDecoder.as:37]
    at jmcnet.mongodb.bson::BSONDecoder$/decodeBSONToMongoDocument()[E:\jmc\Projets\jmcnet\workspace\JMCNetMongoFlex\src\jmcnet\mongodb\bson\BSONDecoder.as:30]

---------------------------------------

You might have wondered why I did not create MongoDocument instead of creating 
query:MongoDocumentQuery and then converted that to MongoDocument... the reason 
why i prefer to do that way is that I wanted to use the criteria for both 
getting the count as well as getting the docs. So, I do not want to duplicate 
the criteria definition once for getting count and another time for actually 
fetching the docs.

The bottom-line is that "BSONDecoder" encounters some unexpected char in the 
ByteArray -that could be due to the malfunctioning of toBSON().

Please let me know what your thoughts are.

Thanks,
Tharma




Original issue reported on code.google.com by [email protected] on 24 Aug 2012 at 9:30

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.